Bug 21465

Summary: Plugin Resolving - reorder REQUIRES clause & different plugins are disabled
Product: [Eclipse Project] Platform Reporter: Debbie Wilson <debbie_wilson>
Component: ResourcesAssignee: Debbie Wilson <debbie_wilson>
Status: VERIFIED FIXED QA Contact:
Severity: normal    
Priority: P3 CC: dj.houghton
Version: 2.0   
Target Milestone: 2.0.1   
Hardware: PC   
OS: All   
Whiteboard:

Description Debbie Wilson CLA 2002-07-10 15:27:04 EDT
This problem is best described with an example.

Suppose you have a plugin structure as follows:
a requires b, c and d
b requires e, f and g
c requires h, i and j
d requires k, l and m

Suppose further that each of the requires clauses in each of these plugins has 
the same ordering as listed above.  So the requires clause for plugin a would 
look like:
  <requires>
     <import plugin="testb"/>
     <import plugin="testc"/>
     <import plugin="testd"/>
  </requires>
and not:
  <requires>
     <import plugin="testc"/>
     <import plugin="testb"/>
     <import plugin="testd"/>
  </requires>
And now, suppose the plugin i has something wrong with it so it becomes 
disabled (maybe it doesn't have all the required fields - i.e. take out 
the 'version' attribute for this plugin).

The following plugins are disabled:  a, c, d, i, j, k, l, m

Now change the ordering of the requires clauses so that all the plugins that 
are suppose to be disabled (plugin i and its direct ancestors only) are at the 
end of each requires.  So, now the requires clauses will resemble the following 
ordering:
a requires b, d and c
b requires e, f and g
c requires h, j and i
d requires k, l and m

Now the only plugins that are disabled are a, c and i!!!

The order should NOT matter!!!

Cases to check:
- all subtrees get disabled
- more than one, but not all, subtrees are disabled
- a subtree is disabled but another root plugin requires another, enabled 
subtree (e.g. a requires b, c and d; c is disabled; a2 requires b and d)
- the root plugin is disabled
Comment 1 Debbie Wilson CLA 2002-07-23 17:00:22 EDT
Fixed for release 2.0.1 (in R2_0_1 stream).
Fix yet to be applied to main stream (HEAD).
Comment 2 Debbie Wilson CLA 2002-07-24 09:46:49 EDT
Fix now applied in main stream (HEAD).
Comment 3 John Arthorne CLA 2002-08-22 11:57:40 EDT
Verified that the above test case is fixed in 2.0.1 candidate build 20020821