Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 165961 - Notification duplicates when using shared .mylar data directory
Summary: Notification duplicates when using shared .mylar data directory
Status: RESOLVED DUPLICATE of bug 130658
Alias: None
Product: z_Archived
Classification: Eclipse Foundation
Component: Mylyn (show other bugs)
Version: unspecified   Edit
Hardware: PC Windows XP
: P3 enhancement (vote)
Target Milestone: ---   Edit
Assignee: Robert Elves CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-11-27 14:59 EST by Joseph Marques CLA
Modified: 2006-12-19 00:37 EST (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Joseph Marques CLA 2006-11-27 14:59:28 EST
As expected, when I have multiple Eclipse instances open at the same time, I get multiple notifications for the same task, if that task appears on multiple queries.  Since I'm using a shared .mylar data directory, I have one notification for each task update in each instance of Eclipse I have open.  Ideally, I'd like to be able to have a central mechanism to eliminate duplicate notification pop-ups.

However, if this were to be implemented, you'll need to deal which Eclipse instance to give the focus to (and to open the task in) if the notification link is clicked.  Perhaps each notification should perform a lookup of which instances currently have that task in their respective task lists, and provide a drop-down option to choose the appropriate instance to open it in.

Granted, having multiple instances open could probably be considered an exceptional path, but I often keep several open.  For instance, I'll work on bugs reports in one while doing new development in another.  Or sometimes I'll want to keep an eye on the incoming change sets for several disparate projects simultaneously.  In these cases, this notification consolidation would be great to have.   I also think it would really make the product seemed polished by handling these complex scenarios gracefully.
Comment 1 Joseph Marques CLA 2006-11-27 15:02:11 EST
Oh, and I suppose this is actually a more general problem because the user can keep seperate mylar data directories for each workspace, create quite different queries, and still have some items appear in multiple task lists...thus generating duplicate notifications.
Comment 2 Mik Kersten CLA 2006-12-18 21:58:11 EST
We can not gracefully support having two live instances both writing to the .mylar directory because things like long-running operations or some user-created changes could have bad effects.  We handle most cases gracefully which is why you are able to work this way, but this mode is not supported.  Not on bug 130658 that we are waiting on Platfrom bug 154097 to figure out how best to support this.

*** This bug has been marked as a duplicate of bug 130658 ***
Comment 3 Eugene Kuleshov CLA 2006-12-18 22:57:02 EST
Mik, Mylar should try to create a lock file on startup and put Task List into a read only mode if lock can't be acquired.
Comment 4 Mik Kersten CLA 2006-12-19 00:13:16 EST
I was wondering about that too.  The thing is, I'm pretty sure that if the file is being written or read it will be locked, which means that it should be impossible to corrupt it.  But if we lock it we make impossible this kind of experimentation described on this bug report, or opening the file while Eclipse is running.  While we can't support this mode, I wonder if locking the file is worth it.
Comment 5 Eugene Kuleshov CLA 2006-12-19 00:37:28 EST
Not locking the task list file, but a separate .lock file, similar to one you can find in .metadata directory. On startup this file should be opened for writing, then closed on shutdown.

On the other hand we need to support pluggable task list writers, those may allow better concurrency...