Unable to debug JNLP with Java 8
Asked Answered
I

1

8

I have tried all ways

running application as

1) javaws -J-Xdebug -J-Xrunjdwp:transport=dt_socket,server=y,suspend=n,address=9123 My.jnlp

2) setting the same option in JAVA_TOOL_OPTIONS

3) setting the same option in JAVAWS_VM_ARGS

4) setting the same option (without -J) in Java control panel

Tried the same options with or without Xnoagent

Each and every way, after doing it when I try to connect from eclipse - it cannot connect. When I do netstat -a - it doesn't show anyone listening on 9123.

I am on windows 10

Isometry answered 24/7, 2017 at 9:49 Comment(2)
Did you read: #26669223Chrystal
@Chrystal - yes - nothing worksIsometry
E
2

The solution reported in Remote debugging java web start under JVM 1.8

is good, but, on windows environment, you have to follow exactly the indication putting everything in a batch file and invoking that one. I have just tried even with java 9 creating a file launchMyJnlp.bat with this content.

setlocal

set JAVAWS_TRACE_NATIVE=1
set JAVA_TOOL_OPTIONS=-agentlib:jdwp=transport=dt_socket,address=9999,server=y,suspend=n %JAVA_TOOL_OPTIONS%

"c:\Program Files\Java\jre-9"\bin\javaws my.jnlp

endlocal

Launching >launchMyJnlp.bat I found the application listening on port 9999 has expected!

Electrograph answered 25/7, 2017 at 17:52 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.