Page 1 of 1

OWS 1.1.[7-8] W10x64 : DEADLOCK on net.sourceforge.jnlp.util.logging at startup ?!

Posted: 08 Jun 2020, 17:02
by Th3WalkingDad
Hi,

From times to times, the launching of an application is freezing.
This is happening *prior* to loading the resources in jnlpx, so I'm pretty sure this is not an issue on the application side.

The itw-clienta-<timestamp>.log is not even created but the console displays that single line:

Code: Select all

Mon Jun 08 15:26:58 CEST 2020 [DEBUG  ] net.adoptopenjdk.icedteaweb.client.parts.dialogs.security.SecurityDialogMessageHandler: Starting security dialog thread 
The itw-javantx-<timestamp>.log last line is the launch of the java.exe command with all parameters

Code: Select all

About to launch external with commands: '[C:\Users\myuser\.cache\icedtea-web\jvm-cache\adopt_11.0.6-1\bin\java.exe, "-Xbootclasspath/a:C:\Program Files\OpenWebStart\openwebstart.jar", --add-exports=java.base/sun.net.www.protocol.jar=ALL-UNNAMED,java.desktop, --add-exports=java.base/jdk.internal.util.jar=ALL-UNNAMED,java.desktop, --add-exports=java.base/com.sun.net.ssl.internal.ssl=ALL-UNNAMED,java.desktop, --add-reads=java.naming=ALL-UNNAMED,java.desktop, --add-exports=java.desktop/sun.awt.X11=ALL-UNNAMED,java.desktop, --add-exports=java.desktop/sun.applet=ALL-UNNAMED,java.desktop,jdk.jsobject, --add-exports=java.base/sun.security.action=ALL-UNNAMED,java.desktop, --add-reads=java.base=ALL-UNNAMED,java.desktop, --add-exports=java.base/sun.net.www.protocol.http=ALL-UNNAMED,java.desktop, --add-exports=java.naming/com.sun.jndi.toolkit.url=ALL-UNNAMED,java.desktop, --add-exports=java.base/sun.security.util=ALL-UNNAMED,java.desktop, --add-reads=java.desktop=ALL-UNNAMED,java.naming, --add-exports=java.desktop/sun.awt=ALL-UNNAMED,java.desktop, --add-exports=java.base/sun.security.x509=ALL-UNNAMED,java.desktop, --add-exports=java.desktop/javax.jnlp=ALL-UNNAMED,java.desktop, --add-exports=java.base/sun.security.provider=ALL-UNNAMED,java.desktop, --add-exports=java.base/sun.security.validator=ALL-UNNAMED,java.desktop, net.sourceforge.jnlp.runtime.Boot, -Xnofork, -verbose, C:\Users\myuser\Desktop\dummy.jnlpx]'
I've reproduced it several times and launched a jstack against the java.exe PID.
Each time that's the same deadlock (FYI full outputs attached)

Code: Select all

Found one Java-level deadlock:
=============================
"main":
  waiting to lock monitor 0x000002a1bc59e080 (object 0x00000000d2c8c1b0, a net.sourceforge.jnlp.util.logging.OutputController),
  which is held by "Output controller consumer daemon"
"Output controller consumer daemon":
  waiting to lock monitor 0x000002a1bc59df80 (object 0x00000000d2bc5db0, a net.sourceforge.jnlp.util.logging.TeeOutputStream),
  which is held by "main"

Known issue ? Am I the only one ?

Last minute. I also checked with OWS 1.1.8 that is just out. Still exists but seems hardly to reproduce...

The problem with that deadlock :
a) if you don't have a console opened, you can't say what is happening. You app just don't start.
b) Furthermore with consoles, if you close them, both javaws.exe and java.exe process stay opened. You'll have to kill them to free resources !

Anything else I can provided ?
OWS_logging_deadlock_X5.7z
OWS 1.1.7
(4.82 KiB) Downloaded 263 times
OWS_118_deadlock6.7z
OWS 1.1.8
(2.72 KiB) Downloaded 281 times

Re: OWS 1.1.[7-8] W10x64 : DEADLOCK on net.sourceforge.jnlp.util.logging at startup ?!

Posted: 08 Jun 2020, 21:46
by Th3WalkingDad
Fancy graphical representation:

Image

Re: OWS 1.1.[7-8] W10x64 : DEADLOCK on net.sourceforge.jnlp.util.logging at startup ?!

Posted: 09 Jun 2020, 16:59
by Th3WalkingDad
Strange ... the picture is '404' now...

Added inline (maybe better):
OWS_Deadlock!!.gif
OWS_Deadlock!!.gif (57.9 KiB) Viewed 5636 times

Re: OWS 1.1.[7-8] W10x64 : DEADLOCK on net.sourceforge.jnlp.util.logging at startup ?!

Posted: 10 Jun 2020, 16:48
by Stephan Classen
Thanks for this detailed post.
We will take a deep look at logging for the next release.
There should be no need for having the Logger going through the TeeOutputStream to the OutputController.

[CLOSED]: OWS 1.1.[7-8] W10x64 : DEADLOCK on net.sourceforge.jnlp.util.logging at startup ?!

Posted: 22 Aug 2020, 23:31
by Th3WalkingDad
Little feedback after using OWS 1.2.1.
After about 100 launches for several tests, I didn't reproduced A SINGLE TIME that deadlock at startup.
Althought this cannot be a proof, OWS 1.2.x seems to have addressed that killer problem for me !

Thumbs up ! :)

Re: OWS 1.1.[7-8] W10x64 : DEADLOCK on net.sourceforge.jnlp.util.logging at startup ?!

Posted: 24 Aug 2020, 11:12
by Janak Mulani
Thanks for testing so thoroughly and your confirmation.