Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 331733

Summary: Inconsistency between changes shown by Task List and change notifications
Product: z_Archived Reporter: Robert Munteanu <robert.munteanu>
Component: MylynAssignee: Mylyn Inbox <mylyn-inbox>
Status: CLOSED MOVED QA Contact:
Severity: normal    
Priority: P3 CC: steffen.pingel
Version: 3.4   
Target Milestone: ---   
Hardware: PC   
OS: Linux   
Whiteboard:
Attachments:
Description Flags
Inconsistent change notifications none

Description Robert Munteanu CLA 2010-12-02 17:53:30 EST
I am repeatedly able to get Mylyn to display out of date change notifications regarding changes coming in from the MantisBT connector. I have re-traced my steps and logged traffic and conversions - but I could find no fault in the connector.

The popup notifications seem to be one step behind of what is actually happening. If I have one task in my task list and I modify it outside Eclipse, I get a notification about a change which includes the summary and description as the 'change'. The following changes will notify of the first oldest change, i.e. when performing change #3 I get a notification about change #2. The tooltip on the task list is correct, however.
Comment 1 Robert Munteanu CLA 2010-12-02 17:55:52 EST
Created attachment 184423 [details]
Inconsistent change notifications
Comment 2 Robert Munteanu CLA 2010-12-06 17:55:48 EST
Digging down a bit, it seems that TaskListNotified.getDiff is based on the persisted state, rather than the incoming (partial) state, and that persistent state is stale in my case. Is that the way it is expected to be?

In my situation I have 2 previous sychronization states:

* S1
* S2

and when S3 comes in , a partial update is applied, but the diff from S1 to S2 is shown , instead of S2 to S3. I looked up what the Bugzilla and Trac connectors were doing but noticed nothing different.
Comment 3 Steffen Pingel CLA 2010-12-06 18:06:28 EST
That sounds like an inconsistency indeed in the handling of task data state. I'll need to look into this further but it sounds like it could be related to bug 291242.
Comment 4 Robert Munteanu CLA 2010-12-06 18:22:36 EST
Thanks.

I am currently experimenting with the implementation of AbstractRepositoryConnector.hasTaskChanged . With my current implementation I get invoked three times, twice for the same partial task and once for the complete task, and all of them return true. Apparently saying that a partial task has changed triggers the wrong notification, since the full state is not persisted. But on the other hand, just checking changes for complete tasks doesn't seem to always trigger the notification.

Getting these notifications right seems a bit fragile. Either that, or I'm doing something subtly wrong.
Comment 5 Robert Munteanu CLA 2010-12-12 06:31:43 EST
FWIW, my current workaround is to not pass in the last updated property to my partial tasks, which means they are not eligible for change detection in ARC.hasTaskChanged, but they are still marked as stale in ARC.presynchronization . 

This seems to work fine so far, but I'm not too happy about this it since it already assumes too much knowledge about how change notification popups and task list diff notifications work.
Comment 6 Eclipse Webmaster CLA 2022-11-15 11:45:08 EST
Mylyn has been restructured, and our issue tracking has moved to GitHub [1].

We are closing ~14K Bugzilla issues to give the new team a fresh start. If you feel that this issue is still relevant, please create a new one on GitHub.

[1] https://github.com/orgs/eclipse-mylyn