• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Debugging Help

 
Bishal Ghimire
Greenhorn
Posts: 26
Firefox Browser
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi all,

I am trying to debug application deployed in weblogic server in eclipse. I am having an interesting issue with it. When I put a break point in java file and run the application, it actually gets stop at its class file. Interesting enough, I can also see the changes in valiables area but I can't do much with class files as I could do with java file.

Suggestions are welcome. In the mean time, I will keep on try to find the way to fix it.

Thanks,
Bishal



 
James Boswell
Bartender
Posts: 1051
5
Chrome Eclipse IDE Hibernate
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Bishal

When your breakpoint is hit, I am assuming you are in the eclipse Debug perspective.

In the Debug tab, right click on the executing thread and select the 'Edit Source Lookup...' option.

From the Edit Source Lookup Path window, click the Add button and select Java Project (this is assuming your application code is already loaded into the workspace as an Eclipse project). Select the check box beside the project you want and click OK.

The perspective should refresh and the actual Java source will be displayed with the breakpoint sitting on the desired line.
 
Akhilesh Trivedi
Ranch Hand
Posts: 1608
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
James Boswell wrote:Hi Bishal

When your breakpoint is hit, I am assuming you are in the eclipse Debug perspective.

In the Debug tab, right click on the executing thread and select the 'Edit Source Lookup...' option.

From the Edit Source Lookup Path window, click the Add button and select Java Project (this is assuming your application code is already loaded into the workspace as an Eclipse project). Select the check box beside the project you want and click OK.

The perspective should refresh and the actual Java source will be displayed with the breakpoint sitting on the desired line.


Do you mean we can debug line-by-line inside a class file in eclipse?
 
Akhilesh Trivedi
Ranch Hand
Posts: 1608
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Bishal Ghimire wrote:Hi all,

I am trying to debug application deployed in weblogic server in eclipse. I am having an interesting issue with it. When I put a break point in java file and run the application, it actually gets stop at its class file. Interesting enough, I can also see the changes in valiables area but I can't do much with class files as I could do with java file.

Suggestions are welcome. In the mean time, I will keep on try to find the way to fix it.

Thanks,
Bishal





Please let us know if you are using Weblogic Workshop or Eclipse for debugging, if your application is console(stand-alone) application or if it is a webapplication and if you have the 'source-code' of the class file where your debugger gets inside? (I think, James is suggesting to link that source to your class file.)
 
James Boswell
Bartender
Posts: 1051
5
Chrome Eclipse IDE Hibernate
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
In standalone eclipse distributions, the instructions I have given will allow you to debug with the java (not the class) file. Not sure about eclipse workshop which in my experience, I see no extra benefit in using.
 
Akhilesh Trivedi
Ranch Hand
Posts: 1608
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
James Boswell wrote: Not sure about eclipse workshop which in my experience, I see no extra benefit in using.


And I have not seen eclipse workshop either. I talked about Weblogic Workshop, I think we get both Welogic server and Weblogic workshop(IDE similar to eclipse) bundled in one single product, in fact there are many-many IDEs built on same Eclipse platform.
 
Bishal Ghimire
Greenhorn
Posts: 26
Firefox Browser
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
@James: I tried that but didn't help (in fact the project was already there look up path window). Btw, thank you for the suggestion.

@Akhilesh: I am using eclipse for the debugging purpose and opening in the Debug perspective too.

 
Akhilesh Trivedi
Ranch Hand
Posts: 1608
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Bishal Ghimire wrote:@James: I tried that but didn't help (in fact the project was already there look up path window). Btw, thank you for the suggestion.

@Akhilesh: I am using eclipse for the debugging purpose and opening in the Debug perspective too.



So did it solve your problem? Mostly you would have the source for your class files and you can get them to debug yourself(by linking as James mentioned). If you are having third-party jars/class, you would hardly be required to debug inside them because you will not be changing them. While debugging I would mostly not be worried what the code is inside a jar/built-in class file does, when my debugger gets inside there i simply run through the thread by pressing F6(step-over) or clicking on the resume button.
 
Bishal Ghimire
Greenhorn
Posts: 26
Firefox Browser
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
This issue hasn't been resolved yet. In addition to the problem I have expressed above, I have another one. When I go through my error console and click on any java file related to my program that is causing error, it pops up a dialogue box saying "Source not found for <some package name>" instead of opening a java file that has the problem.
 
Bishal Ghimire
Greenhorn
Posts: 26
Firefox Browser
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I missed an info- It is a maven project.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic