Which server are you using?
Like already said:
- In your debug configuration you'll have to define the right port of your server (GF:9009 / Tomcat:8000)
- You'll have to set the JVM property of the server to
debug
For Glassfish:
Log in to admin-console > Configurations > server-config > JVM-Settings > check DEBUG checkbox > restart server
For Tomcat:
create file debug.bat/.sh
(depending on your OS) in %TOMCAT_HOME%/bin
directory and write
set JPDA_ADDRESS=8000
set JPDA_TRANSPORT=dt_socket
catalina.bat jpda start
in it.
After you've created this file start server by executing debug.bat/.sh.
Now you should be able to debug remotely in Eclipse after you set the necessary properties in your debug configuration.
Hope this helped! Have Fun!
EDIT
If you're running tomcat in a Win environment as a service you don't have a catalina.bat file in the bin-directory of your tomcat installation.
To set your server into debug-mode please try the following:
- Run the Configuration option in Windows Menu or run
%catalina_home%/bin/tomcat6w.exe
- In Java tab, add this line to Java:
options:-Xrunjdwp:transport=dt_socket,address=8000,server=y,suspend=n