idea 远程调试
2014-08-15 16:54
183 查看
http://www.jroller.com/JamesGoodwill/entry/debugging_web_application_with_intellij
03:02PM Jun 15, 2006 in category Java by James Goodwill
I have been asked about remote debugging using IntelliJ and Tomcat several times. So I thought I would make it easy on myself and everyone else by posting it as a blog. There are several ways to debug an application running in
Tomcat, but I have always found it easier and more useful to debug web applications using IntelliJ's remote debugging tools. It more realistically emulates the real environment and it is easy to debug clustered applications. So anyway, when connecting to Tomcat
using IntelliJ you need to complete the following steps:
Select the Run and then Edit Configurations menus.
When the Run/Debug Configurations dialog box appears, select the Remote tab, and click the plus (+) symbol on the left side of the dialog box. This creates an Unnamed configuration.
Enter the value Tomcat for the name. The other settings will vary depending on whether you are running Tomcat in Windows or UNIX. With UNIX, set the Port value to 8000. The remaining values can remain at their default.
Note: You can specify the host to connect to. If you have access to the port and the process is running on another machine, then you can debug the process remotely. This works out really well for
those situations where the application works fine in your local environment but not in the test environment.
If the JPDA_ADDRESS is something other than 8000, make the appropriate change to the Port input box.
If you use Windows and did not change the default catalina.bat script settings, select the Shared Memory option, and set the Shared memory address to Tomcat's default, jdbconn.
If you have not already launched Tomcat in debug mode, do so now with the following (depending upon your OS):
Once Tomcat is up and running, go back to IntelliJ and either click the Debug button or select the Run->Debug menus items. You should new see a Debug-Tomcat message window with the message "Connected to the target VM at 'localhost:8000' using socket trans-port"
or a similar message in Windows.
That is it. You can now set a breakpoint in your deployed web application and start debugging.
03:02PM Jun 15, 2006 in category Java by James Goodwill
I have been asked about remote debugging using IntelliJ and Tomcat several times. So I thought I would make it easy on myself and everyone else by posting it as a blog. There are several ways to debug an application running in
Tomcat, but I have always found it easier and more useful to debug web applications using IntelliJ's remote debugging tools. It more realistically emulates the real environment and it is easy to debug clustered applications. So anyway, when connecting to Tomcat
using IntelliJ you need to complete the following steps:
Select the Run and then Edit Configurations menus.
When the Run/Debug Configurations dialog box appears, select the Remote tab, and click the plus (+) symbol on the left side of the dialog box. This creates an Unnamed configuration.
Enter the value Tomcat for the name. The other settings will vary depending on whether you are running Tomcat in Windows or UNIX. With UNIX, set the Port value to 8000. The remaining values can remain at their default.
Note: You can specify the host to connect to. If you have access to the port and the process is running on another machine, then you can debug the process remotely. This works out really well for
those situations where the application works fine in your local environment but not in the test environment.
If the JPDA_ADDRESS is something other than 8000, make the appropriate change to the Port input box.
If you use Windows and did not change the default catalina.bat script settings, select the Shared Memory option, and set the Shared memory address to Tomcat's default, jdbconn.
If you have not already launched Tomcat in debug mode, do so now with the following (depending upon your OS):
$CATALINA_HOME/bin/catalina.sh jpda start $CATALINA_HOME/bin/catalina.bat jpda start
Once Tomcat is up and running, go back to IntelliJ and either click the Debug button or select the Run->Debug menus items. You should new see a Debug-Tomcat message window with the message "Connected to the target VM at 'localhost:8000' using socket trans-port"
or a similar message in Windows.
That is it. You can now set a breakpoint in your deployed web application and start debugging.
相关文章推荐
- IDEA远程调试(图解)
- 如何使用 Idea 远程调试 Java 代码
- 看图说话,idea 远程调试 tomcat下项目
- IntelliJ IDEA远程调试
- Win下用idea远程在hadoop上调试spark程序及读取hbase
- IDEA上远程调试Resin
- Tomcat及remote jar使用IDEA远程Debug调试
- IDEA远程部署+调试
- IDEA 远程调试tomcat中的jsp
- IDEA远程调试需要注意事项(一)
- win7安装Hadoop2.7.1 ,IDEA本地远程调试
- idea配置远程调试tomcat
- 【转】idea远程调试
- IDEA远程调试(Windows)Tomcat的详解
- Spark基础随笔:Spark1.6 Idea下远程调试的2种方法
- 从零搭建基于sbt和IDEA的远程spark调试工程
- Intellij IDEA远程调试tomcat
- IDEA 12 + tomcat 进行远程调试
- idea14远程调试tomcat项目