Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Tracing Javaws launch

I have a Java application which is launched via Java Webstart. Occasionally, following a new deployment of the application, it will happen that launching the application results in it being downloaded twice on every launch. I haven't got to the bottom of this but I think it may be related to our squid proxy which seems to interact badly with Java. What I would like, in order to investigate this further, is to see a trace of what javaws is doing. Is there any such option available to javaws?

Just a minor update, if Java is configured to show the console then hitting "5" when focussed on the console will set the logging level to 5 which is the most verbose logging level. This can be useful but it doesn't address cases where the application doesn't get this far.

like image 378
PhilDin Avatar asked Dec 15 '10 18:12

PhilDin


People also ask

How do I enable tracing in Java?

Tracing for Java Plug-in and Java Web Start can be turned on by setting the property deployment. trace property to true . This property turns on all tracing facilities inside Java Plug-in and Java Web Start.

Is Java Web Start still used?

In computing, Java Web Start (also known as JavaWS, javaws or JAWS) is a deprecated framework developed by Sun Microsystems (now Oracle) that allows users to start application software for the Java Platform directly from the Internet using a web browser.

What is javaws command?

The javaws command launches Java Web Start, which is the reference implementation of the Java Network Launching Protocol (JNLP). Java Web Start launches Java applications/applets hosted on a network. If a JNLP file is specified, javaws will launch the Java application/applet specified in the JNLP file.


2 Answers

To enable full trace mode issue the following commands in a command line:

"C:\Program Files (x86)\Java\jre8\bin\javaws.exe" -userConfig deployment.trace true
"C:\Program Files (x86)\Java\jre8\bin\javaws.exe" -userConfig deployment.trace.level all

The trace files will be placed in %USERPROFILE%\AppData\LocalLow\Sun\Java\Deployment\log.

To disable full trace mode again:

"C:\Program Files (x86)\Java\jre8\bin\javaws.exe" -userConfig deployment.trace
"C:\Program Files (x86)\Java\jre8\bin\javaws.exe" -userConfig deployment.trace.level
like image 109
jansohn Avatar answered Oct 12 '22 08:10

jansohn


You may either want to run the jnlp file with -verbose option via javaws command from the command line and/or check the logs. The logs location is java version dependant, In earlier windows releases default path was: c:\Documents and Settings\_user_\Application Data\Sun\Java\Deployment\log

In Windows 7,default path is 'C:\Users\_user_\AppData\LocalLow\Sun\Java\Deployment\log'

like image 39
Jan Zyka Avatar answered Oct 12 '22 09:10

Jan Zyka