Skip to content

Fix 5.x release: Migrate to Maven Central Publishing API - #1702

Merged
ricardozanini merged 4 commits into
open-workflow-specification:5.xfrom
ricardozanini:fix-ci-release-5.x-maven-central
Sep 21, 2026
Merged

ricardozanini merged 4 commits into
open-workflow-specification:5.xfrom
ricardozanini:fix-ci-release-5.x-maven-central

Conversation

@ricardozanini

Copy link
Copy Markdown
Collaborator

Resolves the 402 Payment Required error when releasing from the 5.x branch.

Problem

The 5.x branch was still using the legacy Sonatype OSSRH publishing endpoint, which now enforces publishing limits with a 402 error. The approved exemption (10 releases, 100 MB, 8160 files monthly for io.serverlessworkflow) only applies to the new Maven Central Publishing API.

Solution

Backported the Maven Central migration from main (originally done in f20021f) to the 5.x branch:

  • Add central-publishing-maven-plugin v0.11.0
  • Update workflow server-id from ossrh to central
  • Remove distributionManagement section (new plugin handles this)
  • Simplify release:perform invocation

Testing

After merge, retry releases from 5.x - they should now publish successfully through the new API that respects the exemption limits.

Migrates from legacy Sonatype OSSRH to new Maven Central Publishing API.
This resolves the 402 Payment Required error by using the new publishing
system that respects the approved exemption limits (10 releases, 100 MB,
8160 files monthly for io.serverlessworkflow).

Changes:
- Add central-publishing-maven-plugin v0.11.0
- Update workflow server-id from 'ossrh' to 'central'
- Remove distributionManagement section (handled by new plugin)
- Simplify release:perform invocation

Signed-off-by: GitHub Action <action@github.com>
Copilot AI lite review requested due to automatic review settings September 21, 2026 16:06

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot review overview

🟢 Approval recommended

The changes match the established Maven Central migration pattern with no unresolved issues found.

Review effort: Lite
Findings: None

What changed in this PR

Migrates 5.x release publishing from legacy OSSRH to the Maven Central Publishing API.

Changes:

  • Adds and configures the Central Publishing Maven plugin.
  • Removes legacy Sonatype distribution management.
  • Updates release workflow credentials and invocation.
File Description
pom.xml Configures Central Publishing and removes OSSRH repositories.
.github/​workflows/​release.yml Uses the central server ID and simplified release command.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

The plugin was only in pluginManagement, not in the active build/plugins
section, causing maven-deploy-plugin to run instead. This resulted in:
"repository element was not specified in the POM inside distributionManagement"

Moving the plugin configuration to build/plugins ensures it's active during
the release process.

Signed-off-by: GitHub Action <action@github.com>
@ricardozanini

Copy link
Copy Markdown
Collaborator Author

Closing - recreating from upstream branch

To match main branch structure, the plugin should only be in the active
build/plugins section, not in pluginManagement.

Signed-off-by: GitHub Action <action@github.com>
Add contents: write permission to allow pushing tags and commits.

Signed-off-by: GitHub Action <action@github.com>
@ricardozanini
ricardozanini merged commit 90a7d1f into open-workflow-specification:5.x Sep 21, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants