For help with installation, bugs reports or feature requests, please head over to our new forums.
Genuitec Community on GitHub
- This topic has 3 replies, 3 voices, and was last updated 19 years, 4 months ago by
Riyad Kalla.
-
AuthorPosts
-
How and where do I begin to trace an exception that occurs in one of the libraries automatically added to a MyEclipse project?
I have a project that has ‘Struts capabilities’ added. The ‘struts.jar’ blue pot symbol appears in the package explorer.
An unexplained exception is occuring within the ‘org.apache.struts.validator’ package of the ‘struts.jar’ blue pot entry. Its not clear to me how and if I can append the equivalent source code to start tracing the error.
Ideas?
April 2, 2007 at 9:30 am #268234
RussMemberDav:
I don’t know if this helps or if you already know this information, but I thought I would offer some assistance.
If the jar file is an open source type, then you can attach the source code to the jar file. Struts does have a jar file called “struts.jar” and you can get the source code from the following link: http://struts.apache.org/download.cgi
Here is what you do with the source once you get it on your box:
Click on project where the jar file exist
Right click mouse button and select “Properties”
Click on the “Java Build Path” in the left pane area.
Select the “Libraries” tab.You will note the different libraries used by the specific project. Expanding these libraries, you will find the different jar files used in the Library. Expanding the different jar files you will find the ability to add the path to the source code your dowloaded and installed on your box for the specific jar file. What you want to do here is provide the path to the source code for the “struts.jar.” That’s it!
What this will get you is the ability to see the actual code/error when your application experiences an error.
I hope this was not too elementary for you. If so, I apologize now! 🙂
Russ
April 4, 2007 at 2:44 am #268389I’ve added source code paths for two JAR files as directed (Struts 1.2.4 and commons-validator 1.1.3). I can now see where in the ‘commons-validator’ source code the exception occurs.
What I can’t seem to do is place a breakpoint on the commons-validator source code that will work! The IDE shows the breakpoint symbol but when the app executes it does not stop on these breakpoints.
I’m an ex-JBuilder IDE user, so a lot of the MyEclipse IDE facilities remain a mystery. I suppose what I’m asking is how can I temporarily incorporate the source code for a library into a project to enable debugging on that library code.
Any help will be greatly appreciated!
April 5, 2007 at 6:20 am #268448
Riyad KallaMemberdavout,
When the app is running and the breakpoint is set, is the marker a blue ball with a check mark in it, or just a blue ball? If the breakpoint is getting skipped and you are sure you are executing a code path that should cause it to get hit, then chances are that you may have attached an incompatible version of source to the JAR and the source lookup is failing or more likely the library you are trying to debug wasn’t compiled with debugging information in the class files, so the debugger cannot break because it has no line-mapping information.The last cause would be my guess.
-
AuthorPosts

