Bug 580524 - Improve the retrieval of all dependencies
Summary: Improve the retrieval of all dependencies
Status: CLOSED FIXED
Alias: None
Product: Sirius
Classification: Modeling
Component: Core (show other bugs)
Version: 7.0.2   Edit
Hardware: All All
: P3 enhancement (vote)
Target Milestone: 7.1.0   Edit
Assignee: Laurent Fasani CLA
QA Contact:
URL:
Whiteboard:
Keywords: triaged
Depends on:
Blocks:
 
Reported: 2022-08-05 10:35 EDT by Glenn Plouhinec CLA
Modified: 2023-03-29 12:45 EDT (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Glenn Plouhinec CLA 2022-08-05 10:35:19 EDT
We need to provide an API to list all project dependencies, based on semantic resources dependencies.

We also need to find a way to improve the way image dependencies are retrieved without having to go through all the representations and graphical elements looking for a referenced image.

A first suggested solution is to add metadata in the aird. We would add DAnnotationEntry in the DAnalysis to list all projects that contain images referenced by some representations and require a dependency to this project.
If this solution is chosen, it will be necessary to make these metadata "optional", which can be activated in the preferences to avoid making aird files unnecessarily large for users who don't need this option. We will also need a way to force the update of these metadata, in case a project that contains images is renamed for example.
Comment 1 Eclipse Genie CLA 2022-08-05 10:41:40 EDT
New Gerrit change created: https://git.eclipse.org/r/c/sirius/org.eclipse.sirius/+/195075
Comment 3 Eclipse Genie CLA 2022-12-08 09:35:35 EST
New Gerrit change created: https://git.eclipse.org/r/c/sirius/org.eclipse.sirius/+/197569
Comment 4 Eclipse Genie CLA 2022-12-09 11:45:30 EST
New Gerrit change created: https://git.eclipse.org/r/c/sirius/org.eclipse.sirius/+/197609
Comment 5 Eclipse Genie CLA 2022-12-09 11:50:42 EST
New Gerrit change created: https://git.eclipse.org/r/c/sirius/org.eclipse.sirius/+/197610
Comment 6 Laurent Fasani CLA 2022-12-09 11:54:44 EST
What have been done on this ticket:

* The image project dependencies are persisted in a DAnnotationEntry on
the main DAnalysis. A precommit listener has been created to add and
remove dependencies to images projects for each modification of the
WorkspaceImage style.
* A new class SiriusProjectDependencyQuery is added to get serialized
project dependencies from a given project. It is based on registered
IProjectDependencyProvider. This commit provides one implementation for
local project that uses SAXParser to leverage the serialized
information.
* SessionDetailsReport is updated to always show the general
dependencies (aird, semantic resoruces) even for not opened Session
Comment 7 Laurent Fasani CLA 2022-12-09 12:01:14 EST
Steps to validate
1- import the three projects from the attached ProjectDependenciesEcore.zip
2- right click on project1Ecore.aird/Properties/Sirius Session Details
Expected:
The dependencies should be:

*** Dependencies

General projects dependencies(direct and transitive) (2)
  project2Ecore
  (Transitive dependency)project3Ecore

Image projects dependencies(direct) (1)
  project3Ecore

3- open the session and redo step 2
4- delete project2Ecore from the workspace
5- right click on project1Ecore.aird/Properties/Sirius Session Details
Expected:
The dependencies should be:

*** Dependencies

General projects dependencies(direct and transitive) (1)
  (Not analysed)project2Ecore

Image projects dependencies(direct) (1)
  project3Ecore


6- open the session and redo step 2
Comment 9 Laurent Fasani CLA 2023-02-08 12:42:40 EST
ticket reopened to update the API to manage the images.
This API are used to calculate the image dependencies
Comment 10 Eclipse Genie CLA 2023-02-08 12:47:23 EST
New Gerrit change created: https://git.eclipse.org/r/c/sirius/org.eclipse.sirius/+/199817
Comment 12 Eclipse Genie CLA 2023-02-09 10:59:56 EST
New Gerrit change created: https://git.eclipse.org/r/c/sirius/org.eclipse.sirius/+/199827
Comment 14 Eclipse Genie CLA 2023-02-10 10:59:37 EST
New Gerrit change created: https://git.eclipse.org/r/c/sirius/org.eclipse.sirius/+/199840
Comment 16 Eclipse Genie CLA 2023-02-24 09:07:07 EST
New Gerrit change created: https://git.eclipse.org/r/c/sirius/org.eclipse.sirius/+/200164
Comment 19 Eclipse Genie CLA 2023-02-28 12:44:00 EST
New Gerrit change created: https://git.eclipse.org/r/c/sirius/org.eclipse.sirius/+/200247
Comment 20 Eclipse Genie CLA 2023-03-01 03:28:54 EST
New Gerrit change created: https://git.eclipse.org/r/c/sirius/org.eclipse.sirius/+/200262
Comment 23 Pierre-Charles David CLA 2023-03-29 12:44:09 EDT
Available in Sirius Desktop 7.1.0:
- Release record: https://projects.eclipse.org/projects/modeling.sirius/releases/sirius-desktop-7.1.0
- Update site: https://download.eclipse.org/sirius/updates/releases/7.1.0/2021-06/