[ 
https://issues.apache.org/jira/browse/SLING-8468?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16860105#comment-16860105
 ] 

David Bosschaert commented on SLING-8468:
-----------------------------------------

Thanks for the quick responses, [~simone.tripodi]!

{quote}> Is it possible to specify that the comparison ignores certain things 
from the comparison. For example can I state that the feature ID be ignored 
during compares, or for example the bundle start level attribute on bundles?

Not yet, this is something I need to add, but that's not a big deal!
{quote}

It might be an idea to allow JSONPath expressions to specify elements in the 
Feature model that are ignored. Just an idea 
https://goessner.net/articles/JsonPath/
So maybe the tool can take as arguments some expressions which are excluded 
from the compare. This was we don't have to bake in the tool what parts to 
ignore and which ones to look at...

> [slingfeature-m-p] donate a new MOJO which is able to scan and detect 
> differences between different versions of the same Feature model
> --------------------------------------------------------------------------------------------------------------------------------------
>
>                 Key: SLING-8468
>                 URL: https://issues.apache.org/jira/browse/SLING-8468
>             Project: Sling
>          Issue Type: New Feature
>          Components: Feature Model, Maven Plugins and Archetypes
>    Affects Versions: slingfeature-maven-plugin 1.0.2
>            Reporter: Simone Tripodi
>            Assignee: Simone Tripodi
>            Priority: Major
>             Fix For: slingfeature-maven-plugin 1.0.4
>
>
> I would like to donate a new {{features-diff}} MOJO I developed in the spare 
> time that could be helpful detecting systems evolution.
> I got inspiration from my previous contribution of the [Felix 
> Baseline|https://felix.apache.org/components/bundle-plugin/baseline-mojo.html]
>  MOJO, users can configure the feature selection (inherited by the 
> {{AbstractIncludingFeatureMojo}}) and the previously released version of the 
> they are interested comparing, i.e.:
> {noformat}
>           <plugin>
>             <groupId>org.apache.sling</groupId>
>             <artifactId>slingfeature-maven-plugin</artifactId>
>             <executions>
>               <execution>
>                 <id>features-diff</id>
>                 <phase>package</phase>
>                 <goals>
>                   <goal>features-diff</goal>
>                 </goals>
>                 <configuration>
>                   <comparisonVersion>1.0.2</comparisonVersion>
>                   <selection>
>                     <includeClassifier>cloud-ready</includeClassifier>
>                     <includeClassifier>base</includeClassifier>
>                   </selection>
> {noformat}
> then the plugin will take care of resolving the configured version of 
> selected classified Feature and compare each other, producing the outputs in 
> the {{target/features-diff/<classifier>.diff.json}} files, enlisting for each 
> Feature section what was added/removed/changed.
> The new MOJO relies on the [Feature Model API Regions 
> model|https://github.com/apache/sling-org-apache-sling-feature-apiregions-model]
>  and the [Feature 
> Diff|https://github.com/apache/sling-whiteboard/tree/master/feature-diff] 
> (still in the whiteboard) which contains the core implementation of the diff 
> tool.
> I will start pushing the MOJO in a separated branch in order to discuss the 
> development evolution.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to