AxonFramework-Full — publishing pipeline

From ./gradlew publish to Maven Central

Sonatype has no official Gradle plugin for Central Portal publishing the way central-publishing-maven-plugin covers Maven — this is wired through nmcp's settings plugin instead, layered on Gradle's own maven-publish and signing.

1

Each published module builds a MavenPublication

Any module applying axonframework.published-conventions gets a jar, a sources jar, a javadoc jar, and POM metadata pointing at this fork's own repo and maintainer.

Gate — only if SIGNING_KEY / SIGNING_PASSWORD are set
2

GPG-sign the publication

In-memory PGP keys via Gradle's signing plugin. Absent credentials don't fail the build — they just mean nothing gets signed, matching upstream's own "sign" Maven profile only activating during an actual release.

3

com.gradleup.nmcp.settings aggregates every subproject

Applied once in settings.gradle.kts. Auto-applies com.gradleup.nmcp to every subproject and com.gradleup.nmcp.aggregation to root — no per-module registration needed as new modules come online.

4

publishAggregationToCentralPortal

Stages every publication locally, zips the bundle, uploads it to the Central Portal publisher API using a Central Portal user token (CENTRAL_PORTAL_USERNAME/CENTRAL_PORTAL_PASSWORD). Mirrors upstream's own "one publish execution per reactor build" behavior.

Gate — USER_MANAGED: requires a manual release click in the Central Portal UI
5

Maven Central

Nothing reaches Central automatically — matches the deliberate, inspected-release ethos of the whole migration.

A real bug found building this, not a guess

nmcpSettings { centralPortal { username = providers.environmentVariable(...) } } crashes Gradle 9.2's configuration cache — cannot serialize object of type ... ValueSourceProvider. Reproduced directly; nothing documented about it publicly at the time. Fixed with plain System.getenv(...) instead of the lazy provider.