This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 129954 - webstart execution does not properly handle run.jmvargs
Summary: webstart execution does not properly handle run.jmvargs
Status: RESOLVED WONTFIX
Alias: None
Product: projects
Classification: Unclassified
Component: Java Webstart (show other bugs)
Version: 6.x
Hardware: All All
: P3 blocker (vote)
Assignee: Tomas Zezula
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-03-12 19:31 UTC by mclaassen
Modified: 2016-07-07 08:38 UTC (History)
0 users

See Also:
Issue Type: ENHANCEMENT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description mclaassen 2008-03-12 19:31:08 UTC
webstart only handles certain jvm args in the "java-vm-args" attribute
see the jdk6 docs under technotes/guides/javaws/developersguide/syntax.html#resources

I have been dealing with webstart and netbeans for years and made our application run in both scenarios.  To send config
information to our app in webstart, we set some system properties.  Now, in netbeans 6, we set those same properties in
the runtime configs.  We don't use a lot of webstart's features, so not having the webstart libraries available during
runtime (when in development) is not a big deal so are app works fine in each mode.

I have recently tried to leverage the new webstart possibilities in NB 6.  However, in doing so, I found an issue.  Just
copying the vm args in the java-vm-args attribute is insufficient.  Non-standard properties stripped.  They do exist in
the temporary jnlp file that is placed in the dist directory, but they are not given to the runtime.

Non-standard vm options need to be given as <property> elements inside the <resources> element. 

I realize that having to split the vmargs up is probably not a very appealing prospect, but it would make it work in a
transparent way.

A way to work around this issue would be for me to override the master.jnlp and launch.jnlp properties in the runtime
configs and then make a custom master.jnlp for each runtime configuration we want to use.  In this custom jnlp file, I
could specify the properties I need to, and just let the vm args the standard ones (like initial heap size).  However, I
don't like this approach too much since it involves me copying the master.jnlp template, which might cause upgrade
complications in the future.
Comment 1 Milan Kubec 2008-03-18 10:37:39 UTC
I'm afraid that currently this is the only way to do what you want and editing master.jnlp was from the beginning the
way to handle such advanced scenarios. Changing this issue to RFE. There will be probably major update of JNLP module
because of new way of launching applets in next release and this usecase will be considered.
Comment 2 mclaassen 2008-03-18 15:42:38 UTC
That's fair.  

I am not sure how many others use webstart in the way we do.  I have thought about redesigning things in my code to use
arguments instead of properties, but this would not really solve the problem.  Maybe I could just read the arguments and
set them as system properties, but I am not sure that would work for things like file.encoding.  Also, I would hope
there would be a way to pass "-ea" (to turn on assertions) when launching through webstart.

Either way, I am glad you will take this into account in the next refactoring of the JNLP module
Comment 3 Antonin Nebuzelsky 2010-01-11 04:29:03 UTC
Changing the default component owner to tzezula.
Comment 4 Martin Balin 2016-07-07 08:38:34 UTC
This old bug may not be relevant anymore. If you can still reproduce it in 8.2 development builds please reopen this issue.

Thanks for your cooperation,
NetBeans IDE 8.2 Release Boss