| Summary: | Runtime launch config & source lookup | ||||||
|---|---|---|---|---|---|---|---|
| Product: | [Eclipse Project] PDE | Reporter: | Darin Wright <darin.eclipse> | ||||
| Component: | UI | Assignee: | Wassim Melhem <wassim.melhem> | ||||
| Status: | RESOLVED FIXED | QA Contact: | |||||
| Severity: | normal | ||||||
| Priority: | P2 | CC: | Darin_Swanson, jed.anderson, knut_radloff, veronika_irvine | ||||
| Version: | 2.0 | ||||||
| Target Milestone: | 2.1 M5 | ||||||
| Hardware: | PC | ||||||
| OS: | Windows 2000 | ||||||
| Whiteboard: | |||||||
| Attachments: |
|
||||||
|
Description
Darin Wright
Please suggest the possible changes in PDE launcher to achieve the desired effect - we are not sure we understand the issues clearly to be able to do it ourselves. See bug 29225. There is an additional problem in that pressing "OK" to dismiss the source lookup dialog causes the source lookup path in the source locator to be incomplete for the rest of the debug session. *** Bug 27263 has been marked as a duplicate of this bug. *** I suggest we mark this bug as critical since 27263 was marked critical and because it makes one style of selfhosting impossible (i.e. selfhosting without importing the plugins). If there are no protests, I will futher investigate a fix for this bug. I have seen how it manifests itself by working with Joe. The PDE team is planning to address all major launcher issues (i.e. source code lookups, etc) for M5. The reason why this one has not been addressed yet after all this time is because Darin's original description of the bug is worded in a language that can only be understood by Debug team members, and the clarification that we had requested was not provided. OK, I am late on this one. I did not realize the original description was unclear. The problem is this: The PDE launcher sets up a source locator, which is an instance of the JavaUISourceLocator. When source cannot be found for a stack frame, this source locator prompts the user to find source. This source locator assumes certain attributes are present on the underlying launch config - attributes which define the source lookup path being used. PDE does not use these attributes, and thus, when prompted to find source, the dialog does not display the proper source lookup path that is being used (it displays only the class libraries, since that is all it can infer from the launch config). Worse, when the user presses OK, the associated source locator is changed to use the source locations listed in the dialog (which is obviously incomplete). Thus, as the user continues to debug, they are now severely handicapped, since their source lookup path only contains system libraries. [The dialog also updates the launch config with the new source lookup path attributes, but since PDE does not use these attributes, subsequent re-launches begin with the proper source lookup path again.] I'm looking at the PDE code to determine the best/simplest solution. *** Bug 18603 has been marked as a duplicate of this bug. *** Created attachment 3144 [details]
Contribution for source lookup path support
Attached is a zip file containing three source files (two changed, once new),
and a changed "plugin.xml" file. This is a contribution that adds a source
lookup tab to the Runtime Workbench launch config tab group (the same as the
source lookup tab on java launch configs).
Overview:
* I have defined a "source path provider", as an extesnion point -
WorkbenchSourcePathProvider. A source path provider is responsible for
computing an unresolved source lookup path for a launch config, and is
responsible for resolving the source lookup path at runtime to specific source
locations
* An unresolved source lookup path contains entries such as projects, classpath
containers, etc. This is the path that is displayed and manipulated in the UI.
* A resolved source lookup path resolves contains the corresponding archives,
source folders, etc.
* There is a new extension point definition in the plug-in xml for this
* I have added the "source lookup tab" to the workbench tab group
* The delegate has been changed to only construct a source locator if the
configuration being launched does not have a source locator associated with it
(which will run the same as the old previous implementation)
* Newly created configs & configs that are re-opened in the LCD will be
updated, and tagged as ATTR_SOURCE_LOCATOR_ID = "Java UI Source Locator".
* The source locator will be constructed by the launching framework via this ID
Give it a whirl. I have tried it with the latest PDE code from HEAD and it
seems to play well.
Fixed by applying Darin's suggested changes. |