Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 399677 - [CDO] Dawn integration into graphical editors
Summary: [CDO] Dawn integration into graphical editors
Status: RESOLVED FIXED
Alias: None
Product: Papyrus
Classification: Modeling
Component: Core (show other bugs)
Version: 0.10.0   Edit
Hardware: PC Mac OS X
: P2 enhancement (vote)
Target Milestone: M6   Edit
Assignee: Christian Damus CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 290952
  Show dependency tree
 
Reported: 2013-01-31 15:20 EST by Christian Damus CLA
Modified: 2013-03-06 11:15 EST (History)
0 users

See Also:
give.a.damus: kepler+


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Christian Damus CLA 2013-01-31 15:20:19 EST
The Dawn component of CDO provides an infrastructure for adapting GMF's transactional editing domain for diagram editors to CDO's transaction model.  It also provides edit-part/edit-policy support for handling remote object updates, conflicts, etc.

Papyrus needs to provide extensibility hooks for injection of CDO integration adapters into its diagram editors, along with specific implementations of Dawn API required to handle CDO remote interactions.
Comment 1 Christian Damus CLA 2013-01-31 15:21:06 EST
I'll take this (work already in progress).
Comment 2 Christian Damus CLA 2013-01-31 17:01:13 EST
r9983 on cdo_kepler branch:

Defined an IGraphicalEditorSupport service that enables injection of CDO-specific hooks into a GMF-based editor.  The default implementation does nothing, but the CDO implementation will attach various Dawn editor-support adapters and stuff to the editor.

After creating the diagram IEditorPart, the GmfEditorFactory obtains the IGraphicalEditorSupport service and installs it on the editor.

This should eliminate the need for generating Dawn fragments with subclasses of every Papyrus diagram editor and various edit parts (which Dawn offers primarily for external integration into CDO of third-party editors).
Comment 3 Christian Damus CLA 2013-01-31 18:12:26 EST
r9997 on cdo_kepler branch:

Initial implementation of Dawn integration into Papyrus's GMF-generated diagram editors, including the following components injected by an implementation of the new IGraphicalEditorSupport service:

  * PapyrusGMFEditorSupport - installs CDO transaction handlers for
    updating editors to reflect changes committed by remote clients
  * PapyrusGMFHandler - specializes the DawnGMFHandler to post diagram
    refreshes asynchronously for UI-thread-safe access to GEF figures
    from Papyrus's edit-parts
Comment 4 Christian Damus CLA 2013-02-05 17:29:28 EST
In r10061 on the cod_kepler branch, we now have decorations in the diagrams (shape edit parts, not yet edges and text) and the Model Explorer for CDO object states:

  - conflict (dirty updates on an object committed
       by a remote transaction)
  - locked remotely (remote transaction reserves
       modifications on an object)
  - locked locally

Conflicts and remote locks are shown as and when they are reported by the CDO Server on-the-fly.  Remotely locked objects are not editable; this is accomplished by

  - adding an isReadOnly(EObject) query to the ModelSet API and
    using this in the related EMFHelper API.  The default
    implementation in the ModelSet just checks whether the editing
    domain has the containing resource as read-only; the CDOAwareModelSet
    checks for remote locks on the object (object-level permissions
    check TBD)

  - updating the IElementEditServiceProvider to return a non-editing
    service for read-only objects (as determined by the ModelSet)

Context-menu actions in the diagrams and Model Explorer provide the means to Lock and Unlock objects (locally, of course) and to resolve conflicts (currently only by rolling back the transaction).
Comment 5 Christian Damus CLA 2013-02-05 17:47:29 EST
Now r10062 has CDO object state decorations on edges in the diagrams, too.
Comment 6 Christian Damus CLA 2013-03-06 11:15:46 EST
r10380

This enhancement has been merged into the trunk.