POM Synchronization

Mevenide POM/IDE synchronization works in similar fashion than the "Team Synchronization". It supports Maven multiproject in a practical and simple way :

A single POM is represented by a "POM node" and under each POM node, only the artifacts declared in this underlying POM are displayed. Thus to synchronize a multiproject, you have to select all relevant POMs from a dialog.

Any artifact can be added or removed to and from POM or .classpath. Availability of the various actions depends of the current vizualisation mode.

Also if the current Eclipse project doesnot have the Java nature, user will be asked wether to add it or not.

Synchronization Process

The synchronization view can be populated from the contextual menu of either an IContainer or a pom (project.xml, or more generally xml files) (Screenshot 1, below).

In the later case, only the selected file will be involved in the synchronization process.



Screenshot 1 Synchronization Contextual Menu

When triggered from an Eclipse container contextual menu, if multiple project.xml files are found in the selected container, user will be asked to choose which POMs are to be included in the synchronization process. Also if any project.xml inherits from another POM, this POM can be synchronized as well (Screenshot 2).



Screenshot 2 POM Choice dialog

Synchronization View

The synchronization View provides two visualization modes :

  • incoming mode displays artifacts (dependencies or directories) present in pom but not in project .classpath.
  • outgoing mode displays artifacts present in .classpath but not found in pom.

In the future another mode will be available to show conflicting artefacts. Conflicts are still to be defined more clearly, but they include :

  • inheritance conflicts (much like the Maven Dependency Convergence)
  • .classpath/pom conflicts





Screenshot 3 Synchronization View


In the Outgoing mode (IDE to POM) Properties can also be attached to dependencies.

Every synchronization node is adaptable and can vizualized in the properties view (Screenshot 4, below). In Incoming Mode, properties sheets are read-only whereas they can are writable in Outgoing Mode (IDE to POM).



Screenshot 4 Properties View

You can filter the view thanks the Menu Manager using either regular expressions or selecting which nodes are to be filtered. This is an alternative to the 'add to .mvnignore' action.



Screenshot 5 Artifact Synchronization Filtering

In Incoming Mode, another action is present in ActionBar that allows you to specify wether project.properties file should be written or not (useful while dealing with jar overriding).



Screenshot 6 Toggle Overwrite (Outgoing Mode only)