Skip to content

Fix deploy

Antoine Mottier requested to merge fix-deploy-to-ow2-nexus into master

Currently the GitLab job deploy that lead to Maven deploy phase execution are both successful (cf https://gitlab.ow2.org/weblab/core/-/jobs/49848) but actually don't deploy the artifact on https://repository.ow2.org/nexus/content/repositories/snapshots/org/ow2/weblab/

This might be related to https://issues.apache.org/jira/browse/MDEPLOY-201

After reading https://www.robinhowlett.com/blog/2019/05/15/solved-when-the-maven-deploy-plugin-silently-fails-to-deploy/ I tried to make sure that both root pom and parent pom have exact same configuration regarding plugins and did the following modification:

  • Remove explicit dependencies on Maven Wagon.
  • Include root pom plugins in parent pom pluginManagement.
  • Use same ordering in parent pom and root pom.
  • Fix typo in compiler plugin configuration.

With those changes I can see at the end of the build the following log messages (after that build failed because I don't have credentials locally to upload to OW2 Nexus):

[INFO] --- maven-deploy-plugin:2.8.2:deploy (default-deploy) @ core ---
[INFO] Downloading: https://repository.ow2.org/nexus/content/repositories/snapshots/org/ow2/weblab/core/parent/1.2.9-SNAPSHOT/maven-metadata.xml
[INFO] Uploading: https://repository.ow2.org/nexus/content/repositories/snapshots/org/ow2/weblab/core/parent/1.2.9-SNAPSHOT/parent-1.2.9-20210524.135201-1.pom

whereas when building the current master branch I don't see the Downloading and Uploading log message and build is successful (but deploy don't even try to upload artifacts).

So I guess my changes solve the issue but can explain for sure why.

Merge request reports