• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Ron McLeod
  • Paul Clapham
  • Devaka Cooray
  • Liutauras Vilda
Sheriffs:
  • Jeanne Boyarsky
  • paul wheaton
  • Henry Wong
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Tim Moores
  • Carey Brown
  • Mikalai Zaikin
Bartenders:
  • Lou Hamers
  • Piet Souris
  • Frits Walraven

Debug J2EE appl in Eclipse

 
Ranch Hand
Posts: 79
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello,

Is there any way to debug a J2EE app in eclipse. If so please tell me how.

Thanks,

Bhumika.
 
Bhumika Thakkar
Ranch Hand
Posts: 79
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
please help
 
Ranch Hand
Posts: 169
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I was able to do this with Eclipse. I was running Jetty as an app-server. First, you should configure and enable support for your app-server in Windows/prefs/MyExclipse/Application Servers.

What I did then was deploy my .war file and run Jetty through eclipse. I could then hit servlet (but not JSP) breakpoints.

good luck
 
Ranch Hand
Posts: 333
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I haven't tried the following, but from what I've heard, these options might be viable:
log4J
MyEclipse WorkBench
 
Ranch Hand
Posts: 129
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Bhoomika,

You need to start your server in debug mode and place breakpoint in the JSP,Java code.
Go to debug mode you will get the server name and its status.(started,stopped)Right click on the server name and click on debug.By doing this your server will start in debug mode and with the help of break points you can debug your application.
 
Bhumika Thakkar
Ranch Hand
Posts: 79
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I'm using Eclipse and I start/stop Tomcat manually. How do I configure a server in Eclipse? I think its possible in Websphere but not in Eclipse.
 
Tom Katz
Ranch Hand
Posts: 169
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Depending on your version, it should be what I mentioned earlier:

"First, you should configure and enable support for your app-server in Windows/prefs/MyExclipse/Application Servers."
 
Bhumika Thakkar
Ranch Hand
Posts: 79
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Got it!!!

set 2 environment variables:

set JPDA_TRANSPORT=dt_socket
set JPDA_ADDRESS=8000

start tomcat by
---------------
catalina jpda start

Eclipse
--------
set breakpoints
debug as --> remote java application --> New


http://jakarta.apache.org/tomcat/faq/development.html
[ July 06, 2005: Message edited by: Bhumika Thakkar ]
 
Joel Salatin has signs on his property that say "Trespassers will be Impressed!" Impressive tiny ad:
We need your help - Coderanch server fundraiser
https://coderanch.com/wiki/782867/Coderanch-server-fundraiser
reply
    Bookmark Topic Watch Topic
  • New Topic