Reputation: 18889
I can't get the debugger to work. Steps to reproduce:
1) sbt lagom:runAll
2) sbt -jvm-debug 5005
3) Set remote config in Intellij + start debugging
4) Set breakpoints
5) Make request
The debugger doesn't stop at the breakpoints.
What is the problem here?
Upvotes: 5
Views: 1270
Reputation: 375
@Ruslan Stelmachenko as @Tim Moore said - just execute:
mvnDebug lagom:runAll
and maven will tell you on what port is it listening to connect with remote debug connection and will nicely wait for this connection:
Upvotes: 0
Reputation: 9482
You need to use the -jvm-debug
flag on the sbt runAll
command, like this:
sbt -jvm-debug 5005 runAll
The following steps in your list are correct.
When you run sbt runAll
and sbt -jvm-debug 5005
as separate commands, you are creating two separate sbt sessions: one that runs your services, and the other is doing nothing but waiting for input at the prompt. When you connect your debugger, it is connecting to the second, idle session, instead of the one that is running your services.
Upvotes: 5