質問

I can't find any documentation or examples of debugging Scalatra apps in IntelliJ Idea. Is it possible to run the Scalatra app in debug mode to attach the Idea?

役に立ちましたか?

解決

First. Go to the IDEA an choose edit configurations action:

enter image description here

On this tab, add new remote configuration:

enter image description here

Next, run Scalatra with those options:

enter image description here

For example:

java 
-agentlib:jdwp=transport=dt_socket,server=y,suspend=n,address=5005  -jar **-assembly-**.jar

Now hit the green debug button of your IDEA and enjoy debugging. There might be another ways to run scalatra (e.g. from sbt jetty-run) but generally all you need is to feed those options to the jvm instance.

ライセンス: CC-BY-SA帰属
所属していません StackOverflow
scroll top