I'm developing a project using Vert.X
framework using Gradle
build tool. The problem I have is that breakpoints in IntelliJ
simply doesn't work in any way I've tried.
Here is a run configuration for Vert.X
which I use in Gradle:
run {
args = [
'run', mainVerticleName,
"-conf", confPath,
"--redeploy=$project.ext.watchForChange",
"--launcher-class=$mainClassName",
"--on-redeploy=$project.ext.doOnChange"
]
}
So the deployment is done using Gradle
, runs without any issues, IntelliJ
debugger is connected, but breakpoints are not working.
The ways I've tried to make it work:
1) Gradle run configuration. Here is a run configuration for Intellij IDEA
:
Tried to use a Remote debugging tool, started application with the following VM options:
-agentlib:jdwp=transport=dt_socket,server=y,suspend=n,address=8000
But this didn't work.
2) Application configuration:
In this case I just can't start the project as I get the following message on the startup:
Error: Could not find or load main class io.vertx.core.Launcher
Vert.X Core
library is in the classpath and configuration seems to be correct, so can't get were is the problem.
The source code of the project is public and can be found on GitHub
:
vertx-gradle-architecture-starter
Vert.X version - 3.4.0. Gradle version - 3.4.1. IntelliJ IDEA version - 2016.3.5. OS - MacOS Sierra 10.12.3.
Interesting fact is when I deploy Vert.X
from tests - breakpoints work. Any ideas why breakpoints doesn't work in cases I've described above?