-
Notifications
You must be signed in to change notification settings - Fork 1k
Releasing Micrometer
This page documents the release process for Micrometer and is intended as a reference for Micrometer maintainers.
Git tags in a specific format are how we mark and start the release process. Once tagged, our CI workflow will run for the new tag and perform the release process.
-
See the deploy script used to publish artifacts
Make all the changes you want before the release:
-
Merge PRs
-
Generate (if this is a Milestone/RC release) or update the dependency lock files:
./gradlew downloadDependencies resolveAndLockAll --write-locks --no-build-cache
-
Make sure that the CI build is passing after these changes
A git tag and GitHub release can be made together at https://github.com/micrometer-metrics/micrometer/releases/new. Make maintenance release tags from the corresponding maintenance branch. For example, a release version 1.1.2 would be tagged as v1.1.2
from the 1.1.x
branch.
Release notes can be generated using https://github.com/spring-io/github-changelog-generator. GitHub’s built-in release note generating feature only includes changes made via pull request.
The CI workflow will go through the steps of building, testing, and publishing the artifacts for the version.
If the previous step succeeded, artifacts are published to Maven Central but they might need time to be browsable and searchable.
Go to the milestones and close the one that belongs to the release, this is also a good time to create a new one.
Revert dependency lock files commit (see prerequisites) only if this was a Milestone/RC release.
If this wasn’t a Milestone/RC release, skip this step.
Uploading artifacts to Maven Central can take a long time and the HTTP client used to make these calls has timeouts. Until these timeouts are increased or made configurable, we can restart the sync job (NOT the whole workflow; see next paragraph) and hope the timeouts are not reached on another attempt. CircleCI also has a timeout for no output (see Build has hit timeout limit). For this, we can increase the no_output_timeout
for the maven sync command (see a73f7d0).
To restart a failed job without running the whole workflow again, select the arrow to the right of "Rerun" on the failed workflow from the workflows view, and choose "Rerun from failed".
To make a release, you need to have privileges to push tags to this repository. Secrets are encrypted and the key to decrypt them needs to be configured in the CI. You need privileges on the Micrometer CircleCI to approve the job that blocks the Maven Central sync. That’s it. The rest is handled by plugins, scripts, and workflows.
Knowing these details shouldn’t be necessary for successfully making releases, but if interested you can check them.
The project version is determined at build time by the nebula-release-plugin.
Publishing of the artifacts is handled by the Nebula Publishing Plugin and the Gradle Nexus Publish Plugin