- This topic has 18 replies, 3 voices, and was last updated 20 years, 11 months ago by
Scott Anderson.
-
AuthorPosts
-
vlewisMemberSorry if this is a repost but I have not gotten any straight search results
I am running eclipse 3.0 M8 , myeclipse 3.7.2 , jdk 1.4.2_02 target for weblogic 7. Can I debug jsp’s embedded within and un-exploded ear files or do I need to explode it somewhere. The ear is created by ant , all debug of pure java source works excellently ! I just can’t get at the jsp’s . I do have the weblogic.xml set for jsp debug.
BTW The project originally started as a java (not J2EE) project. I have seen some help on converting such a file to a web based “debuggable”, any gfuther guidance on this would be most appreciated
Thanks in advance
Vince Lewis
June 16, 2004 at 11:34 pm #208650
Riyad KallaMemberVince,
Debugging requires two things:
1) JDK 1.4 or above
2) JSR 45 compliant application serverAFAIK WebLogic supports the JSR 45 spec, so you *shouldn’t* be having a problem with the JSP debugging. Also it is OK to run either exploded or packaged deployment with the debugger.
When you say that you have your weblogic.xml set for JSP debugging, can you paste what you have set here for us to look at?
I have seen some help on converting such a file to a web based “debuggable”, any gfuther guidance on this would be most appreciated
Its hard to say what would be helpful here.. all code should be debuggable, but I’m guessing that this project probably isn’t in a web application-friendly format (meaning directories are in different orders and such).
But if you can deploy and run your app, you should be able to debug it just fine. After we get you fixed up with JSP debugging, let us know any specific debugging problems you are having.
June 17, 2004 at 7:24 am #208656
vlewisMemberHere is my weblogic.xml contents
<!DOCTYPE weblogic-web-app (View Source for full doctype…)>
– <weblogic-web-app>
<description>External Data Management Web Application</description>
– <jsp-descriptor>
– <jsp-param>
<param-name>keepgenerated</param-name>
<param-value>true</param-value>
</jsp-param>
– <jsp-param>
<param-name>debug</param-name>
<param-value>true</param-value>
</jsp-param>
– <jsp-param>
<param-name>workingDir</param-name>
<param-value>/www/websites/edm.merck.com/jsp</param-value>
</jsp-param>
– <jsp-param>
<param-name>pageCheckSeconds</param-name>
<param-value>-1</param-value>
</jsp-param>
</jsp-descriptor>
</weblogic-web-app>June 17, 2004 at 8:58 am #208660
Riyad KallaMemberVince, I asked our WebLogic guy to look at this, hang tight.
June 17, 2004 at 10:29 am #208685
Scott AndersonParticipantVince,
There are a couple of things in your configuration that could be causing the problem, but definately not a ‘smoking gun’. Here’s what comes to mind.
1) The early releases of JDK 1.4.2 (like your copy of 1.4.2_02) had known problems in their debugger API implementation which have been known to cause problems with Eclipse. I’d suggest either updating to the latest 1.4.2 release or falling back to the final release of 1.4.1 for BOTH the JDK used to start WebLogic and Eclipse itself.
2) You’re creating your EAR with Ant, manually, and there might be something there. Can you try this experiment? Create a simple EAR project with a single Web project containing a default JSP generated from our wizard. Set up weblogic for debugging this project as you did in your other EAR and then deploy it in exploded format. Navigate to the application with a browser to be sure it’s there. Once you see it’s up and running, set a breakpoint in the JSP page and refresh the page in the browser. Is the JSP breakpoint hit? What happens.
June 17, 2004 at 3:38 pm #208700
vlewisMemberwell this worked after I put a weblogic.xml file with jsp debug into the dir structure. Debugs jsp helloWorld fine.
However, I tried to get this to deploy unexploded and I could not get it to even run. I am looking at the ear it seems wierd. What do you think I should try next.
June 17, 2004 at 3:57 pm #208703
Scott AndersonParticipantI am looking at the ear it seems wierd.
Ok, so exploded works but not packaged. Can you articulate what you think the problem is with the packaged ear?
June 18, 2004 at 6:46 am #208729
vlewisMemberwell I’m no expert but …
exploded the dir structure lloks like this (not showing META-INFs)DebugTest (enterprise dir)
DebugTestWeb (web dir)
helloWorld.jsp
WEB-INF (dir)
web.xml
weblogic.xml
etcHowever the ear DebugTest.ear contains no META-INF, and a DebugTest.war , this war contains no second directory level (DebugTestWeb) so if I explode it , it is not the same dir a structure
June 18, 2004 at 10:09 am #208744
vlewisMemberwell I have gone the other way and I am exploding my ear in the applications directory. In parallel with the DebugTest deployment. Removed the ear. All the code works, the java code debugs, the DebugTest helloWorld.jsp debugs BUT the main jsps do not. This leaves very few possibilities, including the idea that the JSPs must be deployed through the MyEclipse deployment tool in order to tie the debugger and the deployment . Is this possible? or please give me any ideas. I feel SO close.
June 19, 2004 at 12:54 pm #208815
Scott AndersonParticipantDebugTest helloWorld.jsp debugs BUT the main jsps do not.
Are your main jsp’s top-level JSP’s? I mean, they’re not included in another larger JSP, right? Also, are they all located under the web root of the project? If the JSPs aren’t under a web project’s web root, the source lookup will not find them.
June 21, 2004 at 7:41 am #208845
vlewisMemberNo they were not under the project root, the were refered to a seperate directory structure throught the config.xml file. I had a feeling this might be the case, and I am restructuring to see if this will help. I will keep you posted and thanks for the help so far.
June 21, 2004 at 9:28 am #208851
Scott AndersonParticipantNo they were not under the project root, the were refered to a seperate directory structure throught the config.xml file
This would certainly keep the source lookup for working properly. Please let us know how it goes after you restructure.
June 21, 2004 at 9:47 am #208858
Riyad KallaMemberNo they were not under the project root
I think you meant this anyway, but I just wanted to clarify… Scott meant under the WebRoot (<Project Root>\WebRoot) not under the <Project Root> directory.
June 22, 2004 at 10:30 am #208909
vlewisMemberyes this is what I meant. Okay, here is where we are at. I reconfigured things so that the jsp directorieS are under the the web-root. The directory structure has several levels, that I cannot change, (BTW it is a struts implementation). The first directory level is a dir called jsp/ . index.jsp is in here, among several others. All of these now debug fine !
However when I go after jsp’s that are down two levels from there (there are none down 1) I cannot get the debug to work for these pages.
Getting close. Any ideas ?
June 22, 2004 at 11:55 am #208916
Riyad KallaMemberHowever when I go after jsp’s that are down two levels from there (there are none down 1)
We used to have a bug with debugging if the directories had underscores in the names… I’m curious what the directory names are in this situation, where the debugging works and then where the debugging doesn’t work?
-
AuthorPosts