Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Lagom debugger Intellij

I can't get the debugger to work. Steps to reproduce:

1) sbt lagom:runAll

enter image description here

2) sbt -jvm-debug 5005

enter image description here

3) Set remote config in Intellij + start debugging

enter image description here

enter image description here

4) Set breakpoints

enter image description here

5) Make request

enter image description here

The debugger doesn't stop at the breakpoints.
What is the problem here?

like image 831
html_programmer Avatar asked Jul 27 '18 23:07

html_programmer


1 Answers

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.

like image 94
Tim Moore Avatar answered Nov 11 '22 23:11

Tim Moore