- This topic has 11 replies, 3 voices, and was last updated 21 years, 2 months ago by Scott Anderson.
-
AuthorPosts
-
caronMemberI’m using eclipse 2.1.1, myEclipse 2.61, tomcat 5.09b.
I deploy my web apps (a myEclipse web project) using Ant because I need to copy some resources that are out of projects.
When I put a breakpoint on a jsp, the debug process always stop on the line defining <html:html> and doing a step over go to the closing </html:html> and if I do step in I go into struts taglib classes.
I try to deploy using myEclipse for a minimal deployement, I try to compile with and without jsp compilation, but nothing to do : always the same behavior (not depenent from the jsp I put a breakpoint into).
Did I miss something ?
Testing myEclipse with a ‘hello world’ web project I encounter the same problem but it fix itselft amazingly (maybe after a compilation and deployement using myEclipse).
Scott AndersonParticipantThere are a couple of things that come to mind here. First, you didn’t say which JDK you’re using. For debugging to work properly, you should be using at least JDK 1.4.1 to launch Tomcat. Another thing to check is be sure that your Tomcat instance is configured for debugging. This is typically the default, unless it has changed, but please review the settings described here: http://jakarta.apache.org/tomcat/tomcat-5.0-doc/jasper-howto.html
–Scott
MyEclipse Support
caronMemberI’m using jdk 1.4.1_02 under windows and I haven’t changed anything to tomcat configuration.
Scott AndersonParticipantInteresting. I’ll download 5.0.9b and see if I can replicate the behavior. Our testing is generally done on an earlier release.
–Scott
MyEclipse Support
Scott AndersonParticipantI tried Tomcat 5.0.9b and debugging worked as expected. Now we need to determine if this issue is universal to all JSP’s on your machine or just this particular one. Please deploy the following JSP to Tomcat and set a breakpoint on several of the Java lines. When the page is activated, are they hit as expected?
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> <%@ page language="java" import="java.lang.*,java.util.*" %> <% String path = request.getContextPath(); String basePath = "http://"+request.getServerName()+":"+request.getServerPort()+path+"/"; %> <HTML> <HEAD> <BASE HREF="<%=basePath%>"> <TITLE>My JSP 'TestJSP.jsp' starting page</TITLE> </HEAD> <BODY> <% Date date1 = new Date(); out.println("Today's date is " + date1); Junk junk1 = new Junk(); int ret1 = junk1.getValue(); %> This is my JSP page 2. <BR> </BODY> </HTML>
If debugging on this page works, then your Tomcat and JDK configurations are OK. That would imply that the issue is somehow related to pages “like” your particular JSP page. At that point, I’ll need some help in coming up with a small test case that reproduces the behavior so we can track the problem down.
–Scott
MyEclipse Support
caronMemberI tried the jsp you provide in a ‘hell world’ project and it works quiet well.
I put a breakpoint on :
1 – <BASE HREF=”<%=basePath%>”>
2 – String path = request.getContextPath();
3 – Date date1 = new Date();and I’ve changed Junk to Interger to compile…
When bp 2 an 3 are reached, all is ok : it stops on the right line and can do all espected.
But when bp is reached, it stop on the line just before and can’t do step over/in, can only do a resume…
Scott AndersonParticipantThanks for testing that out. Sorry about the compilation problem; I removed an include to simplify the example before I sent it and obviously did a poor job of it.
I think the issue with bp1 selecting the wrong line is fixed in the upcoming 3.6.2 service release. Since this JSP works as expected (minus the afformentioned known issue) I’ll conclude that your Tomcat and JDK configurations are correct for JSP debugging. However, that doesn’t tell us why you were having trouble on your original JSP, unfortunately. Is it possible to create a simple test case that demonstrates the behavior you witnessed? Perhaps it’s possible to recreate it with one of the standard struts examples?
–Scott
MyEclipse Support
caronMemberI’ll try to reproduce the behavior in a small project, not sur to manage to do it…
Thanks for your time and advices.
Scott AndersonParticipantThank you also. We really appreciate it when people take the time to provide feedback to us so that we can improve the product. Unfortunately, intermitent problems like this are very tough to run down and it’s often hard to even create a small test case. We appreciate any help or ideas you can provide us in this regard.
–Scott
MyEclipse Support
No OperationMemberWhen I put a breakpoint on a jsp, the debug process always stop on the line defining <html:html> and doing a step over go to the closing </html:html> and if I do step in I go into struts taglib classes.
Since you debug a JSP tag, the behaviour seems ok. The content of the tag is handled by the taglib, so there is not any more code in your JSP where the debugger could step through!
regards
NOP
caronMemberThe fact is that beetween <html:html> and </html:html> there is some instructions : taglib but java code too. And anywhere I put a breakpoint, the debugger stop on the line <html:html>
ex :
[some declaration]
<html:html> –> debugger always stop here[some tagliib]
<%
[some javao code] –> bp somewhere on java code
%>
</html:html>
Scott AndersonParticipantCaron,
I’ve managed to replicate this functionality internally and have kicked it back to development for investigation. It appears to only occur when using the <html:html> tags, for some reason. We’ll try to address it in the next service release.
–Scott
MyEclipse Support -
AuthorPosts