Monday, August 2, 2010

Remote debugging with Tomcat 6 and Eclipse

Life as a developer is so easier if you know this. What it meant is debugging the code running on another JVM in tomcat. lets see how to configure.
You don't have to make any changes in catalina.bat in bin folder if its tomcat 6. For tomcat 6 default jpda(java platform debugging architecture) port is 8000. So go to the your eclipse and navigate to debug menu. Select Remote java application. Click on new to create new configuration. In project select project you want to debug. In host select host where tomcat is running and port will be JPDA port(In this case 8000). Hit apply and then hit debug. Set your break point. Go to bin folder of tomcat and execute following command to start tomcat.

catalina jpda start

Your are good to go.

No comments:

Post a Comment