I'm debugging a jnlp application, and I used to be able to remote debug it through eclipse, but not anymore.
the command to start it is:
/usr/java/jdk1.6.0_14/jre/bin/java -Xnoagent -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=1445 -Djnlpx.heapsize=64m,512m -DtrustProxy=true -Xverify:remote -Djava.security.policy=/lib/security/javaws.policy -Dfile.encoding=UTF-8 -Xbootclasspath/a:/usr/java/jdk1.6.0_14/jre/lib/deploy.jar:/usr/java/jdk1.6.0_14/jre/lib/javaws.jar:/usr/java/jdk1.6.0_14/jre/lib/plugin.jar -classpath /usr/java/jdk1.6.0_14/jre/lib/deploy.jar com.sun.javaws.Main launch.jnlp
Listening for transport dt_socket at address: 1445
and the problem is that when I attach the eclipse debugger, it shuts down and restarts; so the debugger attaches to the first process; and when that dies so does the debugger.
the debugger script actually doesn't matter; as the jnlp process re-starts on its own before the debugger ever gets launched if suspend=n .
I've tried tracing it, but the option -XX:TraceSupport=true (and other variations I have tried) causes a jvm error.
I'm using fedora 11, Eclipse Java EE IDE for Web Developers. (Build id: 20090621-0832)
I'm asking if anyone knows how to fix this, or at least how to turn on better logging (ie, capture all the console output to a log; so that I can take a look at the first console that flashes up on my screen for a millisecond)
thanks!
This blog post has environment variables you can set to debug jnlp. This has always worked for me.
set JAVAWS_TRACE_NATIVE=1
set JAVAWS_VM_ARGS=-Xdebug -Xnoagent -Djava.compiler=NONE
-Xrunjdwp:transport=dt_socket,address=8989,server=y,suspend=y
javaws http://server:port/descriptor.jnlp