[
https://issues.apache.org/jira/browse/MNG-6940?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17138246#comment-17138246
]
Rupert Madden-Abbott commented on MNG-6940:
-------------------------------------------
I'm not sure. What are the precedence rules for multiple mixins?
With a parent, it's easy to understand that whatever you inherit will take
precedence. However, there is sometimes a need to define some things that will
apply to the parent and should not apply to the child. Often the reverse is
true too.
If a mixin has a URL, how does it declare that the URL should apply only to the
mixin in some cases, and to both the mixin and the inheriting pom in other
cases, and only to the inheriting pom in other cases?
> Allow parent to prevent inheritance of some items
> -------------------------------------------------
>
> Key: MNG-6940
> URL: https://issues.apache.org/jira/browse/MNG-6940
> Project: Maven
> Issue Type: Improvement
> Reporter: Rupert Madden-Abbott
> Priority: Major
>
> Maven central requires that the following items are specified in artifacts
> that are uploaded:
> [https://central.sonatype.org/pages/requirements.html#sufficient-metadata]
> Of these, the following are inherited by child poms:
> * groupId
> * version
> * developers
> * licenses
> * scm
> * url
> There are a variety of poms deployed to central that are intended to be used
> as parent poms e.g. spring-boot-starter-parent.
> Children of these parents are never going to want to inherit these
> attributes. Since the parent is forced to declare these in order to deploy to
> Maven Central, the child is forced to add boilerplate to override these. It
> is also not trivial to override since all sub-properties must also be
> overridden. This is also brittle to the parent pom declaring more elements in
> the future which it does not wish for the child to inherit.
> Please can we have a mechanism for parent poms to declare that attributes
> should not be inherited. Please can this work for at least those attributes
> required by Maven central.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)