Open Gohan opened 7 years ago
also tried the demo, not working either:
Hi, you might want to use runJavaParameter
for this
jfx {
runJavaParameter = '-Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=n,address=5005'
}
This parameter was introduced to have debug-settings running, but not having this in production outcome.
I'll try it tonight ! It works!
Can't repeat this in my.
build.gradle
group 'ru.mc'
version '1.0'
buildscript {
dependencies {
classpath group: 'de.dynamicfiles.projects.gradle.plugins', name: 'javafx-gradle-plugin', version: '8.8.2'
}
repositories {
mavenLocal()
mavenCentral()
}
}
apply plugin: 'java'
sourceCompatibility = 1.8
repositories {
mavenLocal()
mavenCentral()
}
apply plugin: 'javafx-gradle-plugin'
dependencies {
testCompile group: 'junit', name: 'junit', version: '4.12'
}
jfx {
verbose = true
mainClass = 'ru.mc.ltec.MainClass'
vendor = 'dev'
runJavaParameter = '-Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=n,address=5005'
}
Set breakpoint (for example to MainClass.launch(args)
method) and click Debug for jfxRun task.
Running log
12:09:54: Executing external task 'jfxRun'...
:compileJava UP-TO-DATE
:processResources NO-SOURCE
:classes UP-TO-DATE
:jar UP-TO-DATE
:jfxJar
:jfxRun
Running JavaFX Application
Running command: java -Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=n,address=5005 -jar project-jfx.jar
Application starts immediately without stopping.
I need some additional actions about which in the topic was not explicitly mentioned above?
Hi @zvpdev, did you solve this issue?
Hi @FibreFoX when I run debug mode with
runJavaParameter = '-Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=n,address=5005'
it's not work (port 5005 isn't open).
But when I run command:
java -Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=n,address=5005 -jar project-jfx.jar
manually - it opens the port 5005.
Is there any debuggable example working for IDEA + gradle ?
Tried the gradle Debug "jfxRun" using IDEA, but not working..
netstat -an | find "5005" not find the debug server port..
my build.gradle looks like below: