-
Notifications
You must be signed in to change notification settings - Fork 339
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Debug Java Web Applications #140
Comments
Currently, the launch mode cannot support launch web app in web container, but the attach mode should support debug servlet (jsp is not supported) , but we have not tested it yet, I will keep this issue open as the task from supporting web containers, please keep eyes on this issue for updates. |
@AlexMAS take a look at this article. Even if you don't use JRebel, you'll see how to attach the debugger to a remote tomcat process. |
@fbricon thank you, it works fine! I have a Gradle project, so I imported the gretty plugin as described comprehensively in this article and configured an appropriate task to run the project: {
"taskName": "Run Debug",
"type": "shell",
"command": "gradlew appRunDebug",
"group": "build",
"problemMatcher": []
} You also have to configure debug options like next: allprojects {
apply plugin: 'org.akhikhl.gretty'
gretty {
// Hosting
servletContainer = 'tomcat8'
host = 'localhost'
httpPort = 8080
// Debug
debugPort = 5005
debugSuspend = true
}
} And finally the launch configuration: {
"version": "0.2.0",
"configurations": [
{
"type": "java",
"name": "Debug (Attach)",
"request": "attach",
"hostName": "localhost",
"port": 5005
}
]
} |
Please take a look at this plugin, we will prepare the tutorials for debug java web apps(jsp is not supported by now) . |
hi @andxu i too have trouble figuring out how to do it cheers |
Hello!
I suppose my question can be quite stupid because I have not enough experience with Java. But anyway. Is there possible to debug Java Web Applications? For example, I have an application which can be hosted on Apache Tomcat and I would like to debug it in VSCode using your extension, like I can debug it in Eclipse or IntelliJ IDEA using an appropriate debug configuration.
The text was updated successfully, but these errors were encountered: