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

Bug 518524

Summary: [aird editor] Support contribution of additional pages to the editor
Product: [Modeling] Sirius Reporter: Pierre-Charles David <pierre-charles.david>
Component: CoreAssignee: Pierre Guilet <pierre.guilet>
Status: CLOSED FIXED QA Contact: Jessy Mallet <jessy.mallet>
Severity: enhancement    
Priority: P1 CC: florian.barbin, jessy.mallet, julien.dupont
Version: 5.0.0Keywords: triaged
Target Milestone: 5.1.0   
Hardware: All   
OS: All   
See Also: https://git.eclipse.org/r/101157
https://git.eclipse.org/r/101345
https://git.eclipse.org/r/101708
https://git.eclipse.org/r/101707
https://git.eclipse.org/r/101706
https://git.eclipse.org/r/101822
https://git.eclipse.org/c/sirius/org.eclipse.sirius.git/commit/?id=2a558aba45bacafe31b0aec30efa0e717070b8a4
https://git.eclipse.org/c/sirius/org.eclipse.sirius.git/commit/?id=be0a34ef16906ab4f0e725d814223a229992751a
https://git.eclipse.org/c/sirius/org.eclipse.sirius.git/commit/?id=e420bc0104bcefa6835828b055a6dae23623792c
https://git.eclipse.org/c/sirius/org.eclipse.sirius.git/commit/?id=2b729a632ab4bdbc1f90759314b0a8e9d0b3bb4b
https://git.eclipse.org/r/102306
https://git.eclipse.org/c/sirius/org.eclipse.sirius.git/commit/?id=ecadab994e07292d8babbb78efc3c277de9a4356
https://bugs.eclipse.org/bugs/show_bug.cgi?id=521104
https://git.eclipse.org/c/sirius/org.eclipse.sirius.git/commit/?id=0e8f175fda771f12f05831e1067a038bce2dc845
https://git.eclipse.org/c/sirius/org.eclipse.sirius.git/commit/?id=f2d6dda40977a9096210d02e499447e6ab1fa1dc
https://git.eclipse.org/r/104048
https://git.eclipse.org/c/sirius/org.eclipse.sirius.git/commit/?id=2c5278c78b998b234a95664e37cc647a4c0e77c3
https://git.eclipse.org/r/104053
https://git.eclipse.org/c/sirius/org.eclipse.sirius.git/commit/?id=7a13d1bdb44e11b9d96cce887867791c6f456c81
https://git.eclipse.org/r/104929
https://git.eclipse.org/r/105576
https://git.eclipse.org/c/sirius/org.eclipse.sirius.git/commit/?id=3e492c967265db3d160f7b370fd54bd197f4f223
https://git.eclipse.org/c/sirius/org.eclipse.sirius.git/commit/?id=7e56e69ad1cb237eaea09aed96da428debbfe299
https://git.eclipse.org/r/101344
Whiteboard: aird_editor ux extensibility
Attachments:
Description Flags
Sample plug-in which contributes an additional page
none
New Sample plug-in which contributes an additional page (to use from sirius 5.1) none

Description Pierre-Charles David CLA 2017-06-20 11:42:06 EDT
The aird editor is a multi-page editor, even though in Sirius 5.0 we only support a single, hard-coded one.

We should make it extensible so that additional pages can be added. Some requirements:
* The extensibility should be designed primarily as a dynamic mechanism, controllable through APIs. There will probably be an extension point for static configuration, but it should not be the only/primary configuration mechanism.
* It should be possible not only to add new pages, but to control the order of the pages, including putting a different page that the current hard-coded "Overview" as the first/default.
* It should be possible to *replace* the "Overview" page, so that the editor is still present and has its normal behavior/lifecycle, but the actual content is different (for example to be replaced by a business-oriented overview for users that would be lost with the technical details about models/resources/viewpoints/representations...).
* It should be possible for different sessions to have different sets of pages.
* It should be possible for the set/order of pages to change dynamically during the lifecycle of a session depending on its state (at least depending on which viewpoints are enabled).

First thoughts:
* When the editor is opened, it is attached to a given session. It should be from the session's content that we determine which pages to display and in which order.
* One possible source of pages could be the VSMs of the viewpoints enabled in the session, in a way similar to what was done for properties views. The end-game of the activity explorer integration (see bug #509735) is to have "activity descriptions" configured inside the VSMs and contributed as pages to this editor, and it will be through this mechanism. Note that this source of pages can be dynamic, e.g. when viewpoints are enabled/disabled.
* Another possible source of pages would be an extension point, with more static configuration. Some "enablement" expression will be needed to control in which sessions the pages should be visible.
* One possible hard-coded extension using the previous extension point would read existing activity explorer's pages/sections/activities to contribute these pages. This is the "backward compatibility" part of bug #509735).
Comment 1 Eclipse Genie CLA 2017-07-13 04:25:06 EDT
New Gerrit change created: https://git.eclipse.org/r/101157
Comment 2 Eclipse Genie CLA 2017-07-17 09:31:29 EDT
New Gerrit change created: https://git.eclipse.org/r/101345
Comment 3 Eclipse Genie CLA 2017-07-21 05:42:39 EDT
New Gerrit change created: https://git.eclipse.org/r/101708
Comment 4 Eclipse Genie CLA 2017-07-21 05:42:42 EDT
New Gerrit change created: https://git.eclipse.org/r/101707
Comment 5 Eclipse Genie CLA 2017-07-21 05:42:46 EDT
New Gerrit change created: https://git.eclipse.org/r/101706
Comment 6 Eclipse Genie CLA 2017-07-24 09:49:21 EDT
New Gerrit change created: https://git.eclipse.org/r/101822
Comment 11 Eclipse Genie CLA 2017-08-01 09:45:27 EDT
New Gerrit change created: https://git.eclipse.org/r/102306
Comment 15 Eclipse Genie CLA 2017-08-31 03:18:06 EDT
New Gerrit change created: https://git.eclipse.org/r/104048
Comment 17 Eclipse Genie CLA 2017-08-31 03:49:58 EDT
New Gerrit change created: https://git.eclipse.org/r/104053
Comment 19 Eclipse Genie CLA 2017-09-12 05:29:30 EDT
New Gerrit change created: https://git.eclipse.org/r/104929
Comment 20 Julien Dupont CLA 2017-09-20 08:44:55 EDT
Can not be verified: missing or incomplete reproduction information.
Comment 21 Pierre-Charles David CLA 2017-09-20 11:16:10 EDT
Created attachment 270278 [details]
Sample plug-in which contributes an additional page

Steps to validate:
1. Import the attached project in the workspace.
2. Verify that it compiles.
3. Launch a runtime, open a session and open the aird editor.
4. Verify that in addition to the standard "Overview" page (which should still be present), there is a new "Browser" page (defined in the plug-in). Its content and behavior are not relevant (it's just a prototype).
5. Also check that the release notes mention this new capability and that there is an associated documentation accessible in the "Sirius Developer" manual section.
Comment 22 Julien Dupont CLA 2017-09-21 04:47:56 EDT
Validated for parts 1-2-3-4.
In the last part (5); it's missing in TOC the "Provide custom aird editor pages"
Comment 23 Eclipse Genie CLA 2017-09-21 11:42:42 EDT
New Gerrit change created: https://git.eclipse.org/r/105576
Comment 26 Jessy Mallet CLA 2017-09-25 05:23:50 EDT
Created attachment 270335 [details]
New Sample plug-in which contributes an additional page (to use from sirius 5.1)

The preceding use case is not functional with new Sirius version (at least 5.1.0). Please use the new sample plug-in as test.
Comment 27 Jessy Mallet CLA 2017-09-25 05:25:18 EDT
Validated on Sirius Stable 5.1.0.201709221508
Comment 28 Pierre-Charles David CLA 2017-11-08 03:37:43 EST
Available in Sirius 5.1.0, see https://wiki.eclipse.org/Sirius/5.1.0.