maven-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Jack Jia (JIRA)" <j...@codehaus.org>
Subject [jira] (MDEPLOY-173) Enhance the Maven Deploy Plugin to support Flat POM
Date Thu, 05 Dec 2013 02:17:44 GMT

     [ https://jira.codehaus.org/browse/MDEPLOY-173?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Jack Jia updated MDEPLOY-173:
-----------------------------

    Description: 
*Problem*
The pom.xml has dual purpose.

Building and distributing a jar
Used by another project for dependency management.
For #1 build and distribution, pom.xml makes good sense with many sections and hierarchies.
In this case the main objective is dealing with sources and various aspects of build.

For #2, lets say project B needs the jar produced by project A ( #1), the only things B needs
from A  are,

jar files
dependencies of this jar file
For #2 use-case, none of the sections or hierarchies of pom.xml make sense, except for <dependencies>.sections
and GAV.

Unfortunately maven simply copies the same pom.xml used for build to the repository for distribution.

This problem gets complicated when there are pom hierarchies and <dependencyManagement>
sections

In such cases, to resolve the dependencies of an artifact, maven needs to use more than one
pom.xml. This results in complex release and patch process and potential build time issues.

*Solution*
Enhance the maven deploy plugin to deploy a "flattened" pom that contains only GAV and <dependencies>
section.

The <dependencies> section contains, properly resolved direct dependencies of the artifact,
which are the same of "pom hierarchy" direct dependencies.

"flattened" pom means it cannot have any parent or any other sections that are not necessary
while deploying the artifact.

Note that we may have to add removeMetadata method to 

*Acceptance Criteria*
1. "mvn deploy" could deploy "flatten" pom onto maven repo and its "flatten" pom's dependencies
version should be same to versions of "pom hierachy".
2. "flatten" pom only contains GAV and <dependencies> section.
3. "flatten" pom only contains original direct dependencies, not including transitive dependencies.
4. "flatten" pom won't inherit from any parent pom.


  was:
*Problem*
The pom.xml has dual purpose.

Building and distributing a jar
Used by another project for dependency management.
For #1 build and distribution, pom.xml makes good sense with many sections and hierarchies.
In this case the main objective is dealing with sources and various aspects of build.

For #2, lets say project B needs the jar produced by project A ( #1), the only things B needs
from A  are,

jar files
dependencies of this jar file
For #2 use-case, none of the sections or hierarchies of pom.xml make sense, except for <dependencies>.sections
and GAV.

Unfortunately maven simply copies the same pom.xml used for build to the repository for distribution.

This problem gets complicated when there are pom hierarchies and <dependencyManagement>
sections

In such cases, to resolve the dependencies of an artifact, maven needs to use more than one
pom.xml. This results in complex release and patch process and potential build time issues.

*Solution*
Enhance the maven deploy plugin to deploy a "flattened" pom that contains only GAV and <dependencies>
section.

The <dependencies> section contains, properly resolved direct dependencies of the artifact,
which are the same of "pom hierarchy" direct dependencies.

"flattened" pom means it cannot have any parent or any other sections that are not necessary
while deploying the artifact.

*Acceptance Criteria*
1. "mvn deploy" could deploy "flatten" pom onto maven repo and its "flatten" pom's dependencies
version should be same to versions of "pom hierachy".
2. "flatten" pom only contains GAV and <dependencies> section.
3. "flatten" pom only contains original direct dependencies, not including transitive dependencies.
4. "flatten" pom won't inherit from any parent pom.


    
> Enhance the Maven Deploy Plugin to support Flat POM
> ---------------------------------------------------
>
>                 Key: MDEPLOY-173
>                 URL: https://jira.codehaus.org/browse/MDEPLOY-173
>             Project: Maven Deploy Plugin
>          Issue Type: New Feature
>          Components: deploy:deploy
>            Reporter: Jack Jia
>
> *Problem*
> The pom.xml has dual purpose.
> Building and distributing a jar
> Used by another project for dependency management.
> For #1 build and distribution, pom.xml makes good sense with many sections and hierarchies.
In this case the main objective is dealing with sources and various aspects of build.
> For #2, lets say project B needs the jar produced by project A ( #1), the only things
B needs from A  are,
> jar files
> dependencies of this jar file
> For #2 use-case, none of the sections or hierarchies of pom.xml make sense, except for
<dependencies>.sections and GAV.
> Unfortunately maven simply copies the same pom.xml used for build to the repository for
distribution.
> This problem gets complicated when there are pom hierarchies and <dependencyManagement>
sections
> In such cases, to resolve the dependencies of an artifact, maven needs to use more than
one pom.xml. This results in complex release and patch process and potential build time issues.
> *Solution*
> Enhance the maven deploy plugin to deploy a "flattened" pom that contains only GAV and
<dependencies> section.
> The <dependencies> section contains, properly resolved direct dependencies of the
artifact, which are the same of "pom hierarchy" direct dependencies.
> "flattened" pom means it cannot have any parent or any other sections that are not necessary
while deploying the artifact.
> Note that we may have to add removeMetadata method to 
> *Acceptance Criteria*
> 1. "mvn deploy" could deploy "flatten" pom onto maven repo and its "flatten" pom's dependencies
version should be same to versions of "pom hierachy".
> 2. "flatten" pom only contains GAV and <dependencies> section.
> 3. "flatten" pom only contains original direct dependencies, not including transitive
dependencies.
> 4. "flatten" pom won't inherit from any parent pom.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Mime
View raw message