[
https://issues.apache.org/jira/browse/SLING-9489?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17119718#comment-17119718
]
A. J. David Bosschaert commented on SLING-9489:
-----------------------------------------------
The use-case is that sometimes optimizations can be made when certain parts of
a feature model are the same. Think of for example processing of an extension.
If the extension is the same between 2 feature models you can sometimes save
time during the build by only processing it once.
Or for example when code is generated from an extension. If 2 extensions are
the same between 2 feature models then the same generated code can be shared
between them.
I looked at the FeaturesDiff mojo and it doesn't seem to fit very well for this
use-case.
That mojo takes a number of feature models and compares them with older
versions of the same feature models. Then it produces a diff feature model for
each, i.e. a model that can be applied to the older feature model to get the
newer feature model.
For the use-case that this issue is about we need to:
* compare different feature models (not older versions of the same)
* compare only parts, not the whole
* generate a build error if there is a difference, no need to generate a diff
model
I looked at refactoring the FeaturesDiff mojo, but because the use-cases are so
different I think it would be cleaner to create a new, separate mojo for this
issue here.
> Make it possible to compare parts of feature models
> ---------------------------------------------------
>
> Key: SLING-9489
> URL: https://issues.apache.org/jira/browse/SLING-9489
> Project: Sling
> Issue Type: New Feature
> Components: Feature Model, Maven Plugins and Archetypes
> Affects Versions: slingfeature-maven-plugin 1.3.4
> Reporter: A. J. David Bosschaert
> Assignee: A. J. David Bosschaert
> Priority: Major
> Fix For: slingfeature-maven-plugin 1.3.6
>
>
> We need a mojo that allows the comparison of parts of a feature model. If
> these parts are not equal the mojo should fail the build.
> Right now comparing extensions would be a good start. But comparing
> configurations or bundles would also be good.
> Key is that not everything needs to be compared. The configuration in the
> pom.xml should specify what is being compared.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)