How to perform a release of the Log4j Kotlin API.
Step-by-step guide
Prerequisite Steps
- Run
mvn clean verify
on the project to make sure it builds cleanly. - Make sure you have an up to date PGP key (at least 4096-bit RSA or stronger; use of ECDSA or EdDSA keys should be in addition to the RSA keys for broader compatibility) in the Logging KEYS file along with having it mirrored in a common public PGP key repository such as Ubuntu Keyservers.
- Configure your
git config
user.signingKey
,user.name
, anduser.email
values to match that key. - Ensure you have your credentials set up in
~/.m2/settings.xml
as described in Log4j 2 Release Process.- TODO: insert information about using encrypted passwords.
Release Steps
- Edit
pom.xml
and change theLog4jKotlinVersion
property to the new versionn.n.n
. - Update the
Log4jReleaseManager
andLog4jReleaseKey
properties if necessary. - Generate the site locally and verify it looks alright.
mvn site
cd target/site
python3 -m http.server
- Go to http://localhost:8000
- Build, sign, tag, and publish a release candidate
n.n.n-rcn
. If your GPG key isn't on a hardware key, it should be password protected; you'll be prompted to enter the password to sign artifacts during the build.mvn -Papache-release -DskipTests -Darguments="DskipTests" release:prepare release:perform -DreleaseVersion=n.n.n -DdevelopmentVersion=n.n.n-SNAPSHOT -Dtag=log4j-api-kotlin-n.n.n-rcn
- Login to https://repository.apache.org/ with your ASF credentials. Select "Staging Repositories", then find the newly created orgapachelogging-* staging repository and close it.
- Checkout the release tag and stage the website into a working copy of the
asf-staging
branch of https://github.com/apache/logging-log4j-site/tree/asf-staging tolog4j-kotlin-n.n.n
and update the symlink ofkotlin
to point to it.mvn site && mvn site:stage -DstagingDirectory=$HOME/code/logging/site-java/log4j-kotlin-n.n.n
- Check result of deployment: https://logging.staged.apache.org/log4j/kotlin/
- Copy the archives and signatures from
log4j-api-kotlin/target/
to https://dist.apache.org/repos/dist/dev/logging/log4j/kotlin/. - Run
for f in *.bz2 *.gz *.zip; do shasum -a 512 $f >$f.sha512; shasum -a 256 $f >$f.sha256; done
to generate hashsums. - Send a release vote email to dev@logging.apache.org with links to everything.
- If the release fails, drop the staging repository on repository.a.o and start over with a fresh release candidate number.
- Otherwise, if the release passes, complete the release on the staging repository.
- Create an immutable signed release tag.
git tag -s rel/n.n.n 'log4j-api-kotlin-n.n.n-rcn^{}' -m 'Release n.n.n of Log4j Kotlin API' && git push --tags
- Move the distribution artifacts to https://dist.apache.org/repos/dist/release/logging/log4j/kotlin/ where a new version directory should be made.
svn mkdir '^/release/logging/log4j/kotlin/n.n.n'
svn mv $(svn ls '^/dev/logging/log4j/kotlin' | xargs printf '^/dev/logging/log4j/kotlin/%s ') '^/release/logging/log4j/kotlin/n.n.n/'
- Login to https://reporter.apache.org/ to record the release.
- Wait 12-24 hours for mirrors to propagate.
- Delete the previous version in https://dist.apache.org/repos/dist/release/logging/log4j/kotlin/.
svn rm '^/release/logging/log4j/kotlin/n.n.n-1'
- Merge the
asf-staging
site branch intoasf-site
git checkout asf-site && git rebase asf-staging && git push origin asf-site
- Update any redirect to point to new version for latest (if applicable).
- Send announcement email (from your apache.org email) to dev@logging.apache.org, log4j-user@logging.apache.org, and announcements@apache.org.
Related articles