开发者

How to debug a java application

We are using weblogic 9.2, and its a UI application. How I am running it is - via ant script I am building the complete project & then starting the weblogic.

Suppose if I have to debug the application - checking some values in java files which are getting reflected on my JSP files, how do I do that?

I just went to setServerEnv.bat inside weblogic folder & set the debug options, to start weblogic in debug mode. But my question is how do I debug? If I put some toggle-breakpoints in Eclipse will it开发者_C百科 work? Or Do I have to use some logger info/debug to see the values time to time.


You can attach via remote debugger from inside Eclipse, to your application code running in Weblogic. As long as the source and byte code match it will stop at the correct location in your source for all breakpoints set.

Note that if you change your source without rebuilding/redeploying the breakpoints will still cause a halt, but that the halt location will be incorrect, just something to watch out for.


You will have to create a new "Remote debug configuration" in Eclipse. For the details you can check, for example, this article. That is, provided you properly launched your application server in debug mode.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜