Summary: | [efs] ArrayIndexOutOfBounds in RSEFileSystemContributor.browseFileSystem() | ||||||
---|---|---|---|---|---|---|---|
Product: | [Tools] Target Management | Reporter: | Greg Watson <g.watson> | ||||
Component: | RSE | Assignee: | Martin Oberhuber <mober.at+eclipse> | ||||
Status: | RESOLVED FIXED | QA Contact: | Martin Oberhuber <mober.at+eclipse> | ||||
Severity: | major | ||||||
Priority: | P2 | CC: | dmcknigh | ||||
Version: | 2.0 | Flags: | dmcknigh:
review+
|
||||
Target Milestone: | 2.0.1 | ||||||
Hardware: | PC | ||||||
OS: | Mac OS X - Carbon (unsup.) | ||||||
Whiteboard: | |||||||
Attachments: |
|
Description
Greg Watson
2007-09-10 19:17:52 EDT
BTW, I've tested this code by adding it to the beginning of browseFileSystem() and it appears to fix my problem at least. Created attachment 78070 [details]
Patch fixing the issue
Attached patch fixes the issue as follows:
* Fix the Exceptions in SystemResourceSelectionInputProvider, since it is a
valid use-case to have no connections at all. The code must be prepared
for that.
* Make the SystemResourceSelectionForm listen to systemRegistry change events.
That way, if started during early init, the dialog comes up with an empty
list first; but as soon as the init job is complete, SystemRegistry sends
events to which the selection combo listens, so it fills itself
asynchronously. That's fast enough for users not to notice.
By using asynchronous initialization, we can be sure not to run into any
deadlocks. I think that this is good enough for 2.0.1.
In the longer run, I think we must avoid having client code to wait for SystemRegistry initialization. For TM 3.0, the following should be done:
* Move SystemRegistry completely into non-UI and make it have minimal
dependencies
* Make the SystemRegistry Getters ensure that clients always get a fully
initialized registry. This will make the getters a little slower; but it
ensures that no client needs to worry about not-yet-initialized registry.
The Eclipse core.resources plugin is also working that way (i.e.
synchronous initialization only).
Dave can you please review the patch? I haven't tested the patch, but the changes to the code look good. Patch committed. [202866] Fix exceptions in RSE browse dialog when SystemRegistry is not yet fully initialized |