- This topic has 8 replies, 2 voices, and was last updated 19 years, 11 months ago by Riyad Kalla.
-
AuthorPosts
-
t_shivamMemberHI
Im trying to debug a JSP using remote debugging technique. I configured the postEnvironment.bat by adding the following configurationREM enable the debugger
set JAVA_VM=C:\j2sdk1.4.2_07\bin\java
set JAVA_ARGS=-Xdebug -Xrunjdwp:transport=dt_socket,address=8000,server=y,suspend=n %JAVA_ARGS%and started the DynamoServer. I opened up eclispe, configured Externally launched server by providing localhost, 8000 as recommended in myeclipse documentation. I started the debugger and the communication was established between myeclipse debugger and the ATG server.
Im trying to debug a JSP that is in the file system path of ATG/Dynamo5.6.1/. Hence i opened up a project pointing the directory where i place the JSP under ATG directory. I opened up the JSP in source editor, provided a break point. And then i invoked the JSP from a web browser expecting myeclipse debugger to take over and take me to the break point i made on the source JSP. But the JSP executed and i was not taken to the break point.
I also right cliked on the JSP and selected Debug. This also didnt take me to the break point. Rather it gave me an exception “Failed to connect to remote VM: Connection refused”
Am i missing some configuration?
Your inputs will be of much help
Thx
ShivA
Riyad KallaMemberShiv,
Can you please post all the information we request in the [URL=http://www.myeclipseide.com/PNphpBB2+file-viewtopic-t-393.html]Posting Guidelines[/URL] thread at the top of this forum? That will give us some context so that we can determine if this is an installation issue, a configuration problem, or a bug. Thanks.Also, are you able to debug normal Java classes? And does Dynamo support JSR-45? It will need to in order to debug JSP pages.
t_shivamMemberHi
Sorry abt that. im new to the forum. Shall do it hence forth.Here are the details:
What operating system and version are you running? – Windows XP
What Eclipse version and build id are you using? (Help > About Eclipse Platform) – 3.0.1
– Was Eclipse freshly installed for MyEclipse? – Yes
– If not, was it upgraded to its current version using the update manager?
– Are any other external plugins installed? – N/A
– How many plugins in the <eclipse>/plugins directory are like org.eclipse.pde.* – 8
What MyEclipse version are you using? (Help > About Eclipse Platform > Features) – 3.8.4
What JDK version are you using to run Eclipse? (java -version) –1.4.2_07
What JDK version are you using to launch your application server? – when i use debugging option i use 1.4.2_07
What steps did you take that resulted in the issue? – Trying to remotely debug a JSP on ATG Dynamo
What application server are you using? ATG Dynamo Applciation Server
Are there any exceptions in the Eclipse log file? (<workspace>/.metadata/.log) – Yes but, i got this exception when i right clicked on the JSP file and selected my remote debug option to debug. java.net.ConnectException: Connection refused: connect
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.PlainSocketImpl.doConnect(Unknown Source)
at java.net.PlainSocketImpl.connectToAddress(Unknown Source)
at java.net.PlainSocketImpl.connect(Unknown Source)
at java.net.Socket.connect(Unknown Source)
at java.net.Socket.connect(Unknown Source)
at java.net.Socket.<init>(Unknown Source)
at java.net.Socket.<init>(Unknown Source)
at org.eclipse.jdi.internal.connect.SocketTransportImpl.attach(SocketTransportImpl.java:47)
at org.eclipse.jdi.internal.connect.SocketAttachingConnectorImpl.attach(SocketAttachingConnectorImpl.java:103)
at org.eclipse.jdt.internal.launching.SocketAttachConnector.connect(SocketAttachConnector.java:131)
at org.eclipse.jdt.internal.launching.JavaRemoteApplicationLaunchConfigurationDelegate.launch(JavaRemoteApplicationLaunchConfigurationDelegate.java:75)
at org.eclipse.debug.internal.core.LaunchConfiguration.launch(LaunchConfiguration.java:569)
at org.eclipse.debug.internal.ui.DebugUIPlugin.buildAndLaunch(DebugUIPlugin.java:788)
at org.eclipse.debug.internal.ui.DebugUIPlugin$6.run(DebugUIPlugin.java:955)
at org.eclipse.core.internal.jobs.Worker.run(Worker.java:66)The break points didnt change to little check marks as it normally does when there is a debugger running for the source code.
And im not sure if ATG Dynamo 5.6.1 that im using conforms to JSR 045. I tried to get the information from their site but could not get the spec doc for ATG Dynamo.
Either the JSP im working is not at the right place or Dynamo doesnt conform to JSR 045.
Would you require some more information. Please let me know.
Thx
ShivA
t_shivamMemberI forgot to answer your another question.
Im able to debug java classes. But my objective is to debug end to end from JSP to Java..
Riyad KallaMemberShivA,
I asked around and none of us have experience with ATG Dynamo so we can’t offer much help in this regard. However, if you ARE able to debug servlet classes and such and not JSP pages, I would venture that the JSR 45 spec is not implemented. You can try doing development on JBoss or Tomcat and then deploying to dynamo, as those two have excellent out-of-the-box JSR 45 support and are both free/OS.
t_shivamMemberHello Riyad
Thanks.We cant think of developing our projects on Tomcat or JBoss as our DAO layer is made of relational views that are proprietary to ATG Dynamo. Hence we need to live with ATG Dynamo.
I have a question,
Some introspection on JVMs on my machine made me realize that there are two JVMs. One under c:\j2sdk1.4.2_07 and the other one under c:\Program Files\Java\jre1.4.2_03.In Eclipse–> Preferences–>Java–>Build Path–>Classpath variables, the JRE_LIB and other reserved variables point to VM under Program Files
The stand alone java classes that i said i was able to debug point to this JVM and works fine. How ever when i try to modify the JREs under ‘Installed JRE’ to point to the c:\j2sdk1.4.2_07 JRE, the stand alone java class also fails to debug.
So my question is, in order for me to debug the JSP, should i have eclipse point to correct JVM? Im not sure about changing JREs would resolve the JSP debugging problem.
Thx
ShivA
Riyad KallaMemberShivA,
I think the reason for the failing debugging is likely that MyEclipse (+debugger) are being run with the C:\Program Files JRE and ATG Dynamo is being run with it as well. When you change the MyEclipse (+debugger) JRE to point to your JDK install, you should also do the same in the ATG Dynamo batch file to make sure it is being run with the same VM.
t_shivamMemberHi Riyad
I have changed my settings. Now, the ATG Dynamo and Eclipse point to the SDK, c:\j2sdk1.4.2_07.
Im able to debug the java class file. But not the JSP.
What bewilders me is, I have configured ATG Dynamo to start in debug mode on port 8000. I have congfifured eclipse to hit ATG on Debug mode. Im able to see the ‘java HotSpot(TM) Client VM[localhost:8000] and threads under it that indicates that it has connected to ATG in debug mode successfully. When i stop ATG Dynamo App server, the threads on Eclipse get killed as well – just to confirm that eclipse gets connected to the appropriate server.
But when i invoke the JSP thru a browser, eclipse doesnt take over at the break points.
What could be the possible reasons besides ATG not conforming to JSR 045 spec.
Riyad KallaMemberWhat could be the possible reasons besides ATG not conforming to JSR 045 spec.
Please ask the ATG team that, we are not farmiliar with the ATG software unfortunately.
-
AuthorPosts