Remote Debug With SBT and Intellij Idea

In this Blog, I will show you how to leverage the SBT and IntelliJ Idea to debug scala applications remotely.

1, we open the run/debug configuration setting window and create a new Remote configuration as the below picture shows.

remote debug

2, we copy the the debug parameters.

debug vm options

3, we open the project and config the SBT tool.
We add the command we copied just now to the VM parameters of SBT command.

sbt vm parameter settings

4, we start to run the sbt by click the run button.

run sbt console

5. We run the debug and it shows the remote debug connection is successfully connected.

connect remote debug

6. At last, we input run command in the sbt console. Then the program will start to run and will stop in the break points where you set.

sbt run

Leave a Reply

Your email address will not be published. Required fields are marked *