Releases are done with the maven-release-plugin.
Artifacts are signed and uploaded to the JBoss Nexus repository,
from which they are synced to Maven Central.
Most of the release configuration is inherited from org.jboss:jboss-parent and the project-specific overrides live in
bom/pom.xml.
release:performactivates thejboss-releaseprofile, which builds the javadoc and source-release archives, signs all artifacts with GPG and uploads them to JBoss Nexus (server idjboss) with the staging tagorg.jboss.mod_cluster-<version>.- Tests are skipped in both the
release:prepareandrelease:performbuilds (-DskipTests -DskipITs). We test combinations that are impossible to test from a single machine and platform in CI. Ensure that CI is green on the commit being released. - SCM changes are temporarily kept manual:
release:preparedoes not push the release commits and tag, andrelease:performbuilds from the local repository rather than cloning from GitHub. The commits and tag are pushed by hand once the upload succeeded. - The
code-coveragemodule is built but never deployed.
-
Temurin JDK 17
-
No maven installation required – always use provided Maven Wrapper!
-
Credentials for JBoss Nexus in
~/.m2/settings.xmlobtained from https://repository.jboss.org/nexus/<server> <id>jboss</id> <username>...</username> <password>...</password> </server>
-
A GPG key usable by
gpg-agentfor signing artifacts and the release tag. Maven Central rejects unsigned artifacts and verifies signatures against the public key, so the key must be published on a public key server (e.g.keys.openpgp.org) and must not expire before the release is synced. The passphrase can be passed to Maven via theMAVEN_GPG_PASSPHRASEenvironment variable. -
A clean working tree and push access to
github.com/modcluster/mod_cluster, referred to as theupstreamremote below.
The examples below release X.Y.Z.Final and move the development version to X.Y.(Z+1).Final-SNAPSHOT.
-
Create a temporary
releasebranch from the latest upstreammain:git fetch upstream git checkout -b release upstream/main -
Prepare the release. This sets the release version, builds, commits, creates a signed
X.Y.Z.Finaltag and then moves to the next development version. Nothing is pushed../mvnw -B release:prepare -DreleaseVersion=X.Y.Z.Final -DdevelopmentVersion=X.Y.(Z+1).Final-SNAPSHOT -
Check the result. The tag must not contain any
SNAPSHOTversions andmainmust only contain the next development version:git log --oneline -3 git grep SNAPSHOT X.Y.Z.Final -- '*pom.xml' git grep SNAPSHOT -- '*pom.xml' -
Perform the release. This builds the tag, signs the artifacts and uploads them to JBoss Nexus:
./mvnw -B release:perform -
Check the uploaded artifacts in JBoss Nexus under
org/jboss/mod_cluster/*/X.Y.Z.Final. Each jar must come with its-sources.jar,-javadoc.jarand.ascsignatures. -
Push the release commits and the tag, then remove the temporary branch:
git push upstream release:main git push upstream X.Y.Z.Final git checkout main git branch -D release -
Once synced, verify the release on Maven Central.
As long as nothing was uploaded or pushed, a failed release can simply be discarded and started over from step 1:
git checkout main
git branch -D release
git tag -d X.Y.Z.Final
./mvnw release:clean
Artifacts that were already synced to Maven Central cannot be changed or removed; fix the problem and release a new version instead.
- Navigate to https://github.com/modcluster/mod_cluster/tags
- Find the tag and create a release
- Ensure to create discussion for the new release
- Go to https://redhat.atlassian.net/projects/MODCLUSTER/versions/
- Create the new release
- Perform the release of the X.Y.Z.Final and move all issues to the next release
Happy releasing!
Rado