Bug 182951 - PDE does full resolution of state each time eclipse is restarted
Summary: PDE does full resolution of state each time eclipse is restarted
Status: CLOSED DUPLICATE of bug 326974
Alias: None
Product: PDE
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 3.3   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: PDE-UI-Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords: performance
Depends on:
Blocks:
 
Reported: 2007-04-18 09:24 EDT by Thomas Watson CLA
Modified: 2011-06-16 12:56 EDT (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Thomas Watson CLA 2007-04-18 09:24:25 EDT
PDE does a full state resolution the first time the PDE classpath container is used.  I observed this behavior while debugging bug 181327.

Here is what I think is going on (Wassim and others correct me if I'm wrong)

- PDE caches a copy of the target state which contains the BundleDescriptions of all the binary bundles in the target.
- PDE caches a copy of the workspace state which contains the BundleDescriptions of all the bundles in the workspace.
- The first time the PDE classpath container is used both the workspace and target states are read from disk into memory.
- A third state (or maybe one of the loaded states?) is used to merge the two states into one.
- A full resolution is then performed on the merged state.

This is not an issue for smaller targets (<150 like the sdk) because the resolver will do a full resolution in ~1ms per bundle.  But as your target grows into the 1000s we are talking about 1000s of ms.  To make matters worse, if you close a workspace with a PDE manifest editor open, on restart this full resolution takes place *before* the workspace is shown.  This directly affects startup performance.

Possible solutions:
- Cache the merged resolved state and only reconstruct it if you notice the target or the workspace set of bundles has changed.
- Figure out why PDE is doing full resolution at startup.  Can this be done in the background, right now it happens on the main event loop.
Comment 1 Chris Aniszczyk CLA 2008-09-04 10:56:33 EDT
I will look at this in M3
Comment 2 Thomas Watson CLA 2009-03-23 14:37:41 EDT
I am wary about doing such a change after M7.  M7 is supposed to be used for performance improvements.  If we cannot fit this in then I suggest we defer out of 3.5.
Comment 3 Chris Aniszczyk CLA 2009-03-23 17:04:43 EDT
I'll leave it on the list for M7, but no guarantees.
Comment 4 Darin Wright CLA 2009-04-24 12:40:58 EDT
deferred.
Comment 5 Curtis Windatt CLA 2011-06-16 12:56:11 EDT

*** This bug has been marked as a duplicate of bug 326974 ***