Sonatype deployment problems

Hi Folks,

I was running release travis scripts for my Java/Kotlin FOSS to publish artifacts to Maven Central via OSS Sonatype Repository. Bu doing so, the default Maven Deploy plugin publishes to a so-called staging repository and then, the artifact can be synced and released to maven central.

Starting from today (at least I observed it today) this procedure stopped working. After some investigations and reading the change-log - here is my theory…

OSS Sonatype Nexus auto creates a staging repository for the build / deploy based on machine name, ip address and group name of the published artifact. They do have a problem for builds running behind firewalls and changing outgoing IP Address between artifact pushes (see https://issues.sonatype.org/browse/OSSRH-5454).

I read, that you changed your infrastructure setup from container-based towards VM based which involved the change of IP Addresses. This fact should not be a problem, but is it possible that you are using a different outgoing connection infrastructure, than it was for the containers?

Do you have any idea, if my theory is correct and how can I avoid that every upload from the Travis infrastructure comes from a different public IP address? Today I got seven staging repositories instead of one created - in fact this means that publishing of artifacts is not possible anymore, because it separates JARs from Source-JARs from JavaDoc files from POM.xmls to different staging repos and closing / releasing is not possible anymore…

P.S. to be more precise I just got the following IP addresses as sources:

  • 35.192.85.2
  • 35.193.7.13
  • 104.154.120.187
  • 35.184.226.236
  • 35.224.112.202
  • 35.202.145.110
  • 35.188.1.99
  • 35.184.96.71

here is the build https://travis-ci.org/holunda-io/camunda-bpm-taskpool/builds/466091296

Thanks,

Simon

Hello @zambrovski,

Thanks for bringing up this issue and sorry for the delay in providing feedback. @bbranan raised this issue with Sonatype here [1].

The primary recommendation from Sonatype came down to 2 things:

  1. Use the nexus-staging-maven-plugin to perform the deployment (in place of the default maven deploy plugin)
  2. Include a tag in the configuration in the configuration of that plugin

Can you try this solution as well and confirm it works for you? Thanks

[1] Loading...

@zambrovski You can also migrate to Gradle which (after proper configuration) works fine with the “new” Travis infrastructure :wink: