Releasing

Overview

The following steps describe how to release dbUnit.

The Maven Release Plugin’s release:prepare goal automates the version bump, build verification, commit, tag, and push. Pushing the resulting tag triggers the release.yml GitHub Actions workflow, which builds, signs, and deploys the release to Maven Central and publishes the GitHub Release. Local Central and GPG credentials are no longer needed to cut a release: release:prepare only runs a plain build (no signing, no deploy), and the workflow holds the deploy credentials instead.

dbUnit still has manual file update steps that are outside the scope of the Maven Release Plugin: the japicmp comparison reportSets, site.xml menu entries, changes.xml release metadata, and the index.adoc news entry. These must be committed and pushed before running release:prepare, since the plugin requires a clean working tree and creates its own commits on top.

Release Steps

  1. Confirm the commit to release is green on the build-any-branch-with-all-dbs.yml workflow across all database profiles: the build that release:prepare runs below only exercises the default profile, so it will not catch a database-specific regression.
  2. Review site results for issues and correct as necessary, whether the current published or a local gen.
  3. Determine the release version
  4. If needed, rename the "Release Version" (Milestone in GitHub Issues) used during development to the determined version
  5. Update pom.xml
    1. Update japicmp-maven-plugin configuration
      1. Add reportSet for prior version to new version comparison
      2. Comment out reportSet comparison to latest snapshot until a new snapshot exists; keep its id and reportLinkName in sync when renaming it for the next cycle
  6. Update site.xml
    1. Add menu entry for japicmp prior version to new version comparison
    2. Comment out comparison to latest snapshot until a new snapshot exists
  7. Update changes.xml (see Changelog for the full attribute/schema reference)
    1. Update release version
    2. Set release date to today
  8. Update index.adoc
    1. Add entry to release section; ensure correct links
  9. Commit files "chore(release): Prep x.y.z"
  10. Push the commit to main
  11. Run the Maven Release Plugin
    mvnw release:prepare

    This prompts for the release version, SCM release tag, and new development version — defaulting respectively to the current SNAPSHOT with -SNAPSHOT stripped, dbunit-x.y.z (the pattern release.yml listens for), and the next SNAPSHOT. Pass -DreleaseVersion=, -Dtag=, -DdevelopmentVersion=, and -B instead to run non-interactively.

    It then, in order:

    • Sets the pom.xml version to the release version and runs clean verify
    • Commits "[maven-release-plugin] prepare release dbunit-x.y.z" and tags it
    • Sets the pom.xml version to the new development version
    • Commits "[maven-release-plugin] prepare for next development iteration"
    • Pushes both commits and the tag to main

    That push is what makes the release public — it triggers the deploy and site publish below. Before it pushes, release:rollback undoes the local commits and tag. After it pushes, undo instead by reverting the commits and deleting the tag; the Maven Central deployment itself cannot be un-published.

  12. Release deploy (automatic)

    The pushed tag triggers release.yml, which verifies the tag matches the tagged commit’s project.version, runs "mvnw deploy -Prelease -DskipTests" to sign and deploy to Maven Central (tests already ran during release:prepare), and creates the GitHub Release with auto-generated notes. Monitor the run and correct any issues.

  13. Build and deploy the site
    1. Publish:

      The commits release:prepare pushed to main automatically trigger publish-docs.yml, which builds the site and deploys it to GitHub Pages.

  14. Clean up local release files
    mvnw release:clean

    Removes the local release.properties file and backup pom files that release:prepare leaves behind. Nothing else needs them once release.yml has taken over the deploy.

  15. Post Announcement Discussion https://github.com/dbunit/dbunit-extension/discussions/categories/announcements
    1. Consider using the changes plugin’s announcement-generate goal
      mvnw changes:announcement-generate -Dchanges.version=theNewVersion

      Review and adjust the text as desired before using.

  16. Finish preparing the next development iteration The release:prepare step above already bumped pom.xml to the new SNAPSHOT version and pushed it. The remaining dbUnit-specific files still need a manual follow-up commit, e.g. "build(pom): Prep x.y.z-SNAPSHOT development":
    1. Update pom.xml japicmp-maven-plugin configuration: uncomment the comparison of the release just shipped to the new snapshot
    2. Update index.adoc with a new SNAPSHOT news entry
    3. Update changes.xml with a new SNAPSHOT release entry (date="TBD"); required before the Dependabot changelog automation can append entries — see Changelog