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 52638 - Support for JavaWebStart (JNLP)
Summary: Support for JavaWebStart (JNLP)
Status: RESOLVED DUPLICATE of bug 89465
Alias: None
Product: projects
Classification: Unclassified
Component: Java Webstart (show other bugs)
Version: 5.x
Hardware: All All
: P2 blocker (vote)
Assignee: Milan Kubec
URL:
Keywords:
: 33473 47512 (view as bug list)
Depends on:
Blocks:
 
Reported: 2004-12-18 18:09 UTC by _ gtzabari
Modified: 2006-11-16 14:09 UTC (History)
7 users (show)

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 _ gtzabari 2004-12-18 18:09:11 UTC
Hi,

There is serious lack of support for Java Webstart
development. It is difficult/impossible to debug
such applications and there is nonexistant support
in any other IDE that I know of for doing this. We
*really* need JWS support in Netbeans.

Expectations:

- Ability to debug JWS application using JPDA
(this exists in an unofficial API, we just need to
hook into it)
- Integration of JWS "services"
- JNLP file editor support

Justification: The community needs this because
there is no alternative that does this yet. There
is a need for IDE integration because it is
currently very difficult to do it manually.

Please consider commiting this for 4.1 or 4.2.

Thank you,
Gili
Comment 1 _ gtzabari 2005-01-03 00:38:23 UTC
Hey guys,

This issue has nine votes and if I recall correctly that's pretty high
for Netbeans issues (do you have a top-20 most voted-for enhancements
list somewhere?).

Anyway, can we have an official response from the Netbeans team as for
the difficulty of implementing this enhancement and when it could
possibly be scheduled for?

Please see
http://www.javadesktop.org/forums/thread.jspa?messageID=47362&#47362
for documentation on how to bind a JPDA debugging session to Webstart.

Until we get an official response from Sun, I've found this other link
discussing it:
http://forum.java.sun.com/thread.jspa?forumID=38&threadID=450875

I am hoping implementing this enhancement won't be too difficult. I've
been thinking about possible designs for this. Initially, this is what
I expect:

- Add support for JNLP files. This means adding a Webstart icon
associated with such files and the ability to "compile" and "debug"
them. This is top priority.

- Once that's done, I expect the editor to recognize JNLP files and
offer code-complete on them.

- Finally, some sort of intergration of JWS services. I don't really
know what I expect in this domain because I've never tried using them
before.

It would be great if we could have a prototype Webstart debug support
within the coming month and all other enhancements can wait much
longer. It is just so difficult getting debugging to work that I would
really appreciate an IDE that had it built-in.

The ball is now in your court :)

Thank you,
Gili
Comment 3 Jan Chalupa 2005-01-03 17:38:20 UTC
Re "do you have a top-20 most voted-for enhancements list somewhere?":

Yes, see
http://qa.netbeans.org/bugzilla/dashboards/top-voted.html

Comment 4 _ gtzabari 2005-01-03 22:44:32 UTC
Jan,

Very cool, but how do you reach this URL from the main webpage? I
tried looking for a link to it in the community section but found nothing.
Comment 5 _ gtzabari 2005-01-04 09:32:04 UTC
Ah ha! After weeks of trying, I finally got Webstart debugging to work!!

Here is a simple batch file that will launch an application in
Webstart and attach a JPDA session to it:

@echo on
setlocal

rem *** The following parameters must come from the JNLP file ***
set VM_ARGS=-ea -Xincgc -Xmx20m
set URL=http://hostname.com/myApplication.jnlp

rem *** This path must be absolute because javaws uses a simple
string-compare against the expected path ***
set JAVAW_PATH=C:\Program Files\Java\jre1.5.0_01\bin\javaw.exe

set DEBUG=-Xdebug -Xnoagent -Djava.compiler=NONE
-Xrunjdwp:transport=dt_socket,address=8888,server=y,suspend=y
set
WS_OPTS="-Xbootclasspath/a:%JAVA_HOME%\jre\lib\javaws.jar;%JAVA_HOME%\jre\lib\deploy.jar"
"-Djnlpx.vmargs=%VM_ARGS%" "-Djnlpx.jvm=%JAVAW_PATH%"
"-Djnlpx.splashport=-1" "-Djnlpx.home=%JAVA_HOME%\jre\bin"
"-Djnlpx.remove=false" "-Djnlpx.offline=false"
"-Djnlpx.heapsize=NULL,NULL"
"-Djava.security.policy=file:%JAVA_HOME%\jre\lib\security\javaws.policy"
-DtrustProxy=true -Xverify:remote

"%JAVA_HOME%\jre\bin\java.exe" %VM_ARGS% -esa %DEBUG% %WS_OPTS%
com.sun.javaws.Main %URL%


Please use this as the basis of any Netbeans integration you build. I
got these command-line options by enabling full logging on Java
Webstart and grabbing the cmdline it was using to launch the JVM. I
then plugged in that same cmdline into my batch file and it worked!
Comment 6 Jesse Glick 2005-01-04 14:41:18 UTC
*** Issue 33473 has been marked as a duplicate of this issue. ***
Comment 7 Jesse Glick 2005-01-04 14:42:36 UTC
*** Issue 47512 has been marked as a duplicate of this issue. ***
Comment 8 _ gtzabari 2005-01-04 14:45:58 UTC
Jesse,

There was mention in the duplicate issues of Tim having worked on this
kind of support. Did he get far?
Comment 9 _ gtzabari 2005-01-04 14:47:40 UTC
Argh, this bites. This issue had 13 votes, then it was moved to a
different component and our vote count got reset.

Can everyone please re-vote for this issue?

Thanks,
Gili
Comment 10 Jesse Glick 2005-01-04 14:54:02 UTC
FWIW: I think there is a much easier way to launch JWS in debugging
mode, calling the regular javaws executable but using some special
environment variables which insert additional VM options for JPDA. (Of
course this is specific to Sun's impl of the spec.) Can't remember
details offhand but could look them up if work begins on this in earnest.

Support for JWS would either take the form of a new project type, or
JWS capabilities in the existing plain Java project type. And no, Tim
did not get far.

Looks like vote count got reset during move from core -> ide, no idea
why. Was 14. Doesn't really matter; the issue is certainly well known.
There is no need for anyone to revote.
Comment 11 _ gtzabari 2005-01-04 15:18:15 UTC
Jesse,

What is the best target milestone you guys can do? :) As I mentioned
earlier on, I don't mind waiting longer for full-fledged Webstart
support if you add the ability to debug Webstart projects early on.

Another issue I should point out is that an application is not a
"Webstart project" as much as it *could* be launced from Webstart as
much as it could be launced as a standalone application. My thoughts
is that we would/should be binding support for JNLP files, not the
application files themselves. This actually makes things easier
because you don't need to create a new project type, just augment the
preexisting "Java Application" project. Ideally we should be able to
launch as standalone or Webstart, regardless of the encapsulating
"project type".

Lastly, the reason I am so keen on JNLP debugging is because I've
found specific bugs that only occured within the Webstart container
and not when my application ran standalone.
Comment 12 Jesse Glick 2005-01-04 16:44:45 UTC
Re. target milestone - not up to me, and I don't know.

Re. debugging JNLP - I imagine you can do it today (in 4.0) if you
know how to launch javaws with the correct flags, using Ant or just
some shell script. I haven't tried. IDE support would be a
convenience. Doing it without a JNLP project type would not be
simpler, it would just be wasted effort.

Re. whether a JNLP project is really a distinct project type - the
decision whether to use a new project type, or add support to
j2seproject, is mostly UI/technical and relates to ease of initial
configuration; it is not a question of what the nature of the app is.
Note that *some* JNLP-able apps can be launched standalone, if they
use no javax.jnlp.** services and do not rely on other aspects of the
JNLP environment, but many JNLP apps can only be launched through
javaws. A JNLP project type would probably have an option to run the
app w/o javaws, for apps in the first category. Anyway, for proper GUI
configuration, you really need the project type to know (a lot) about
JNLP.

Re. JNLP environment not being the same as standalone, for purposes of
debugging - yes, of course. At a minimum, the class loader setup is a
bit different.

Once again - we already have a pretty clear idea of what we need to
do; we just have not yet committed people to work on it. If and when
we do, we will put out a detailed proposal.
Comment 13 achimwessling 2005-01-06 18:34:55 UTC
Hi,

I use netbeans for all my java development. All my private java
desktop projects and also all the desktop projects in my company use
webstart-technic. So a better support for debugging/developping would
be great!

Achim
Comment 14 lordy 2006-02-13 09:24:39 UTC
- JNLP file editor support
I start working on this issue, you can find my work here: http://public.wuapaa.com/public/NetBeans/
Comment 15 Jesse Glick 2006-02-13 16:01:35 UTC
I believe a webstart module is coming to available update centers right around
now. Petr J. please update w/ status.
Comment 16 Petr Jiricka 2006-02-13 16:56:49 UTC
Yes, should come like tomorrow.
Comment 17 Petr Jiricka 2006-02-14 08:33:59 UTC
The module is now available on the Beta Update Center for NetBeans 5.0 as:

NetBeans Module for Java Web Start

Comment 18 lordy 2006-02-14 08:42:26 UTC
Yes i have seen it.

Our visual editors look simular in some parts. I have some ideas and some already done things in my one i 
now want to add, so where is the source, and against which component/subcomponent should i fill bugs/
RFE that we can discuss the ideas?
Comment 19 Milan Kubec 2006-11-16 13:52:42 UTC
We're working on Java Web Start support, see UI Spec:
http://javawebstart.netbeans.org/proposals/jnlp-ui-spec.html

Development is being discussed on mailing list dev@javawebstart.netbeans.org,
(archive: http://javawebstart.netbeans.org/servlets/SummarizeList?listName=dev)
Comment 20 Antonin Nebuzelsky 2006-11-16 14:09:29 UTC
Closing as a duplicated of issue 89465, created for the purpose of 6.0 planning
exercise.

Please, discuss your ideas and views on this feature on the mailing list
mentioned above.

*** This issue has been marked as a duplicate of 89465 ***