Reputation: 59
I want to debug agilereview plugin, which I download from here:
https://github.com/AgileReview-Project/AgileReview-EclipsePlugin
But I have no idea, how to debug this big plugin which has many plugin projects. From where should I start? For example, from which projects? There are many plugin projects:
org.agilereview.common
org.agilereview.core
org.agilereview.storage
org.agilereview.export
org.agilereview.test
I am not finding any main method, which is the problem. Another problem could be, I don't know how to debug such big plugins. I am new in eclipse plugin development and debugging.
Upvotes: 2
Views: 75
Reputation: 7275
Start your application in debug mode. As long as no Bug occurs, there is nothing to debug.
If an Exception occurs in your console, jump into the line where it happened. Find out what the Exception means and work up along the stack-trace to find the cause of the problem.
If a (non-Exception-) logical error occurs, add a break point where the problem appears (i.e. in the view or console-printer). Restart the application. When it stops at the break point, work up along the stack trace again.
You have an inherent problem in your question: you assume that it is a good idea, to work from the entry point of your application, down to the bug. But eclipse plugins have more than one entry point (called extension points). Instead using the Bug as a starting point for your research and work towards an entry point is the better approach. This is also true for non-plugin applications with only one entry point.
In some cases it makes sense to work top-down, instead of bottom-up: e.g. if a Button-Click doesn't trigger anything. Then you start at the onClick
method of the button and work yourself down though the code, to see why nothing is triggered.
Upvotes: 1