[Commented] (MDEPLOY-251) generatePom=false not working with 3.0.0-M1

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

[Commented] (MDEPLOY-251) generatePom=false not working with 3.0.0-M1

JIRA jira@apache.org

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

Robert Lieske commented on MDEPLOY-251:
---------------------------------------

I have updated my sample to fix the issue with the content of the POM (artifact name differs from filename).

Basicly you missed the point, that the uploaded artifacts should have a different name.

I have changed the code upload a released version, so you'll see the problem (overwriting uploaded POM is not allowed), when you change the plugin-version to 3.0.0-M1. To make the sample work for you, supply 'releaseRepositoryUrl' and 'releaseRepository' with credentials in your settings.xml

> generatePom=false not working with 3.0.0-M1
> -------------------------------------------
>
>                 Key: MDEPLOY-251
>                 URL: https://issues.apache.org/jira/browse/MDEPLOY-251
>             Project: Maven Deploy Plugin
>          Issue Type: Bug
>    Affects Versions: 3.0.0-M1
>            Reporter: Robert Lieske
>            Priority: Major
>             Fix For: waiting-for-feedback
>
>
> Steps to reproduce:
> {{mvn archetype:generate -DarchetypeGroupId=org.apache.maven.archetypes -DarchetypeArtifactId=maven-archetype-quickstart -DarchetypeVersion=1.4 -DgroupId=test1 -DartifactId=test1 -Dversion=1.0-SNAPSHOT}}
>  
> {{mvn clean package deploy:deploy-file -Dfile=target/test1-1.0-SNAPSHOT.jar -DgeneratePom=false -DgroupId=test1 -DartifactId=test1 -Dversion=1.0-SNAPSHOT -DrepositoryId=snapshotRepository -Durl=${snapshotRepositoryUrl}}}
> produces:
> {quote}[INFO] --- maven-deploy-plugin:2.8.2:deploy-file (default-cli) @ test1 ---
> Downloading from snapshotRepository: http://xxx/repository/snapshots/test1/test1/1.0-SNAPSHOT/maven-metadata.xml
> Downloaded from snapshotRepository: http://de01-xxx/repository/snapshots/test1/test1/1.0-SNAPSHOT/maven-metadata.xml (583 B at 2.0 kB/s)
> Uploading to snapshotRepository: http://xxx/repository/snapshots/test1/test1/1.0-SNAPSHOT/test1-1.0-20190204.162443-2.jar
> Uploaded to snapshotRepository: http://xxx/repository/snapshots/test1/test1/1.0-SNAPSHOT/test1-1.0-20190204.162443-2.jar (2.4 kB at 8.1 kB/s)
> Downloading from snapshotRepository: http://xxx/repository/snapshots/test1/test1/maven-metadata.xml
> Downloaded from snapshotRepository: http://xxx/repository/snapshots/test1/test1/maven-metadata.xml (268 B at 1.8 kB/s)
> Uploading to snapshotRepository: http://xxx/repository/snapshots/test1/test1/1.0-SNAPSHOT/maven-metadata.xml
> Uploaded to snapshotRepository: http://xxx/repository/snapshots/test1/test1/1.0-SNAPSHOT/maven-metadata.xml (583 B at 3.3 kB/s)
> Uploading to snapshotRepository: http://xxx/repository/snapshots/test1/test1/maven-metadata.xml
> Uploaded to snapshotRepository: http://xxx/repository/snapshots/test1/test1/maven-metadata.xml (268 B at 1.4 kB/s)
> [INFO] ------------------------------------------------------------------------
> {quote}
>  
> changing the version of the maven-deploy-plugin in pom.xml to 
> {{<plugin>}}
> <artifactId>maven-deploy-plugin</artifactId>
> <version>3.0.0-M1</version>
> </plugin>
>  
> the same call to
> {{mvn clean package deploy:deploy-file -Dfile=target/test1-1.0-SNAPSHOT.jar -DgeneratePom=false -DgroupId=test1 -DartifactId=test1 -Dversion=1.0-SNAPSHOT -DrepositoryId=snapshotRepository -Durl=${snapshotRepositoryUrl}}}
> produces:
> {quote}[INFO] --- maven-deploy-plugin:3.0.0-M1:deploy-file (default-cli) @ test1 ---
> Downloading from snapshotRepository: http://xxx/repository/snapshots/test1/test1/1.0-SNAPSHOT/maven-metadata.xml
> Downloaded from snapshotRepository: http://xxx/repository/snapshots/test1/test1/1.0-SNAPSHOT/maven-metadata.xml (583 B at 1.6 kB/s)
> Uploading to snapshotRepository: http://xxx/repository/snapshots/test1/test1/1.0-SNAPSHOT/test1-1.0-20190204.162607-3.jar
> Uploaded to snapshotRepository: http://xxx/repository/snapshots/test1/test1/1.0-SNAPSHOT/test1-1.0-20190204.162607-3.jar (2.4 kB at 7.7 kB/s)
> {color:#d04437}Uploading to snapshotRepository: http://xxx/repository/snapshots/test1/test1/1.0-SNAPSHOT/test1-1.0-20190204.162607-3.pom{color}
> {color:#d04437}Uploaded to snapshotRepository: http://xxx/repository/snapshots/test1/test1/1.0-SNAPSHOT/test1-1.0-20190204.162607-3.pom (2.7 kB at 9.6 kB/s){color}
> Downloading from snapshotRepository: http://xxx/repository/snapshots/test1/test1/maven-metadata.xml
> Downloaded from snapshotRepository: http://xxx/repository/snapshots/test1/test1/maven-metadata.xml (268 B at 2.6 kB/s)
> Uploading to snapshotRepository: http://xxx/repository/snapshots/test1/test1/1.0-SNAPSHOT/maven-metadata.xml
> Uploaded to snapshotRepository: http://xxx/repository/snapshots/test1/test1/1.0-SNAPSHOT/maven-metadata.xml (754 B at 4.0 kB/s)
> Uploading to snapshotRepository: http://xxx/repository/snapshots/test1/test1/maven-metadata.xml
> Uploaded to snapshotRepository: http://xxx/repository/snapshots/test1/test1/maven-metadata.xml (268 B at 1.5 kB/s)
> [INFO] ------------------------------------------------------------------------
> {quote}
>  
> Which also deploys a POM - which is not what we want!
>  
> NOTE: there is a similar issue with the maven-install-plugin



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