Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 304668 - IModelChangedListener reporting stale information
Summary: IModelChangedListener reporting stale information
Status: CLOSED WONTFIX
Alias: None
Product: PDE
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 3.6   Edit
Hardware: PC Windows XP
: P3 major with 1 vote (vote)
Target Milestone: ---   Edit
Assignee: PDE-UI-Inbox CLA
QA Contact:
URL:
Whiteboard: stalebug
Keywords:
Depends on:
Blocks:
 
Reported: 2010-03-04 08:57 EST by James Willans CLA
Modified: 2019-09-09 02:25 EDT (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description James Willans CLA 2010-03-04 08:57:15 EST
Build Identifier: 

I am adding a listener to instances of IPluginModelBase using the
following code:

private void bundleAdded(final IPluginModelBase pluginModel) {

// Create a new bundle to model the one added

pluginModel.addModelChangedListener(new IModelChangedListener() {

@Override
public void modelChanged(IModelChangedEvent event) {

System.out.println("** Change event **");
String id = pluginModel.getPluginBase().getId();
String version = pluginModel.getPluginBase().getVersion();
System.out.println("id : " + id);
System.out.println("Version: " + version);
}
});
}

When I change and save the bundle details in the manifest editor, I seem
to be getting stale information. For example, assuming that the bundle
id is "BundleA" and the version is 1.0:

1) Bundle id is changed to "BundleB" the output is correct:

** Change event **
id : BundleB
Version: 1.0.0

2) Bundle version is changed to "2.0.0" the event is fired but the
output is stale:

** Change event **
id : BundleB
Version: 1.0.0

3) Bundle version is changed to "3.0.0" the output continues to be stale:

** Change event **
id : BundleB
Version: 2.0.0

This is similarly the case when monitoring the dependencies and other
features of the model.

Reproducible: Always
Comment 1 Eclipse Webmaster CLA 2019-09-06 15:37:07 EDT
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet.

If you have further information on the current state of the bug, please add it. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant.
Comment 2 Julian Honnen CLA 2019-09-09 02:25:13 EDT
Please remove the stalebug flag, if this issue is still relevant and can be reproduced on the latest release.