RFC: Netx - Support VM arguments specified in the JNLP file

Deepak Bhole dbhole at redhat.com
Tue Jun 2 11:43:29 PDT 2009


* Omair Majid <omajid at redhat.com> [2009-06-01 17:03]:
> Hi,
>
> The attached patch allows Netx to use the JVM arguments specified in the  
> JNLP file. Currently only 'initial-heap-size', 'max-heap-size' and  
> 'java-vm-args' are used.
>
> The first instance of the JVM parses the JNLP file and creates a new JVM  
> with the required arguments if the JNLP file requires it. The option  
> '-Xnofork' is passed to Netx to indicate it shouldnt fork any more JVMs.  
> This also makes it possible to revert to the old behaviour by passing  
> -Xnofork to the first instance of Netx.
>

Xnofork is fine, but it doesn't look like the other args (that javaws
accepts) will get passed to the new vm instance... those should be
inherited as well.

Deepak

> ChangeLog:
> 2009-06-01  Omair Majid  <omajid at redhat.com>
>
>     * rt/net/sourceforge/jnlp/JNLPFile.java
>     (needsNewJVM): New function. Returns true if the JNLP file requires
>     creating a new JVM.
>     (getNewVMArgs): New function. Returns arguments to pass to the new
>     JVM.
>     * rt/net/sourceforge/jnlp/Launcher.java
>     (launchExternal): Modify to take in arguments to pass to the JVM and
>     arguments to pass to the Java program.
>     (launchExternal): Likewise. Launch Netx with the with the
>     appropriate arguments.
>     (launchApplication): If needed, launch a new JVM.
>     * rt/net/sourceforge/jnlp/resources/Messages.properties:
>     Add BXnofork.
>     * rt/net/sourceforge/jnlp/runtime/Boot/java:
>     Add -Xnofork to helpMessage
>     (main): Check for '-Xnofork'.
>     * rt/net/sourceforge/jnlp/runtime/JNLPRuntime.java:
>     Add forksAllowed to store whether creating a new JVM is allowed.
>     (getForksAllowed): New function. Check if creating a new JVM is
>     allowed.
>     (setForksAllowed): New function. Set whether creating a JVM is
>     allowed.
>     * rt/net/sourceforge/jnlp/services/XBasicService.java
>     (showDocument): Fix call to launchExternal to match the new
>     semantics.
>
> Any comments?
>
> Cheers,
> Omair





More information about the distro-pkg-dev mailing list