From 63527a376740bc92ceba960b32d829453efdcaed Mon Sep 17 00:00:00 2001 From: karel rehor Date: Wed, 2 Sep 2026 14:54:39 +0200 Subject: [PATCH 001/105] ci: start maven-release.yml workflow --- .github/workflows/maven-release.yml | 38 +++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) create mode 100644 .github/workflows/maven-release.yml diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml new file mode 100644 index 00000000..889751a5 --- /dev/null +++ b/.github/workflows/maven-release.yml @@ -0,0 +1,38 @@ +name: Maven Releasing + +on: + + release: + types: [created] + branches: + +jobs: + release: + permissions: + contents: write # may want to update version + runs-on: ubuntu-latest + env: + SONATYPE_USERNAME: ${{ secrets.SONATYPE_USERNAME }} + SONATYPE_PASSWORD: ${{ secrets.SONATYPE_PASSWORD }} + MAVEN_SETTINGS_EXPERIM: ${{ vars.MAVEN_SETTINGS_FILE }} + GPG_PASSPHRASE_PRELIM: ${{ secrets.GPG_PASSPHRASE }} + RELEASE_TAG_NAME: ${{ github.event.release.tag_name }} + IS_PRERELEASE: ${{ github.event.release.prerelease }} + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + steps: + - name: Checkout + uses: actions/checkout@v6 + - name: Setup JDK 21 + uses: actions/setup-java@v5 + with: + java-version: '21' + distribution: 'temurin' + cache: maven + gpg-private-key: ${{ secrets.GPG_PRIVATE_KEY }} + - name: Add dependencies + run: | + sudo apt-get update + sudo apt-get install libxml2-utils + - name: Check environment + run: | + env From a7fb4546b5eebb6341a9dd337943adaba30fa6f0 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Wed, 2 Sep 2026 15:11:05 +0200 Subject: [PATCH 002/105] chore: remove branches tag on release trigger --- .github/workflows/maven-release.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index 889751a5..331a1ced 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -4,7 +4,6 @@ on: release: types: [created] - branches: jobs: release: From 07c0179a31ac4aa4f00f982321da73173857781b Mon Sep 17 00:00:00 2001 From: karel rehor Date: Wed, 2 Sep 2026 16:41:52 +0200 Subject: [PATCH 003/105] chore: add here doc for generating release.properties --- .github/workflows/maven-release.yml | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index 331a1ced..650395e0 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -18,6 +18,7 @@ jobs: RELEASE_TAG_NAME: ${{ github.event.release.tag_name }} IS_PRERELEASE: ${{ github.event.release.prerelease }} GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + GITHUB_REPO: ${{ github.repository }} steps: - name: Checkout uses: actions/checkout@v6 @@ -35,3 +36,10 @@ jobs: - name: Check environment run: | env + - name: Model release + run: | + cat << EOF > release.properties + scm.url=scm\:git\:https\://github.com/${GITHUB_REPOSITORY}.git + scm.tag=${RELEASE_TAG_NAME} + EOF + cat release.propertie \ No newline at end of file From fc9e61f7ec089e27f67ed68496ab5e01e7cdf9e7 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Wed, 2 Sep 2026 16:56:35 +0200 Subject: [PATCH 004/105] chore: fix typo --- .github/workflows/maven-release.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index 650395e0..1b2bc73f 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -42,4 +42,4 @@ jobs: scm.url=scm\:git\:https\://github.com/${GITHUB_REPOSITORY}.git scm.tag=${RELEASE_TAG_NAME} EOF - cat release.propertie \ No newline at end of file + cat release.properties \ No newline at end of file From f9e2f7b37fe113336dab5d29e4b99aa7817ee10c Mon Sep 17 00:00:00 2001 From: karel rehor Date: Wed, 2 Sep 2026 17:09:37 +0200 Subject: [PATCH 005/105] chore: update pom.xml and deploy-settings.xml for fork. --- deploy-settings.xml | 4 ++-- pom.xml | 32 +++++++++++++++++--------------- 2 files changed, 19 insertions(+), 17 deletions(-) diff --git a/deploy-settings.xml b/deploy-settings.xml index f3761fc5..0acec203 100644 --- a/deploy-settings.xml +++ b/deploy-settings.xml @@ -25,7 +25,7 @@ xsi:schemaLocation="http://maven.apache.org/SETTINGS/1.1.0 http://maven.apache.org/xsd/settings-1.1.0.xsd"> - ossrh + central ${env.SONATYPE_USERNAME} ${env.SONATYPE_PASSWORD} @@ -33,7 +33,7 @@ - ossrh + central true diff --git a/pom.xml b/pom.xml index d5ac49c5..8c873d20 100644 --- a/pom.xml +++ b/pom.xml @@ -25,10 +25,10 @@ 4.0.0 - com.influxdb + io.github.karel-rehor influxdb3-java jar - 1.12.0-SNAPSHOT + 1.12.0 InfluxDB 3 Java Client @@ -64,9 +64,9 @@ - scm:git:git@github.com:InfluxCommunity/influxdb3-java.git - scm:git:git@github.com:InfluxCommunity/influxdb3-java.git - https://github.com/InfluxCommunity/influxdb3-java/tree/main + scm:git:https://github.com/karel-rehor/influxdb3-java.git + scm:git:git@github.com:karel-rehor/influxdb3-java.git + https://github.com/karel-rehor/influxdb3-java/tree/main HEAD @@ -81,7 +81,7 @@ GitHubPages - https://InfluxCommunity.github.io/influxdb3-java/ + https://github.com/karel-rehor/influxdb3-java @@ -408,6 +408,12 @@ + + org.apache.maven.plugins + maven-release-plugin + 3.3.1 + + org.apache.maven.plugins maven-checkstyle-plugin @@ -633,7 +639,7 @@ 3.3.0 target/staging - scm:git:git@github.com:InfluxCommunity/influxdb3-java.git + scm:git:git@github.com:karel-rehor/influxdb3-java.git ${project.basedir}/../influxdb3-scmpublish-checkout gh-pages UTF-8 @@ -749,20 +755,16 @@ - org.sonatype.plugins - nexus-staging-maven-plugin - 1.7.0 + org.sonatype.central + central-publishing-maven-plugin + 0.9.0 true - ossrh - https://ossrh-staging-api.central.sonatype.com/ - true - 15 + central - From e4924eb9eac870477e974a02519240d4b3587d39 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Wed, 2 Sep 2026 17:10:52 +0200 Subject: [PATCH 006/105] chore: add simple volume check to workflow --- .github/workflows/maven-release.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index 1b2bc73f..b590d291 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -42,4 +42,5 @@ jobs: scm.url=scm\:git\:https\://github.com/${GITHUB_REPOSITORY}.git scm.tag=${RELEASE_TAG_NAME} EOF - cat release.properties \ No newline at end of file + cat release.properties + ls -al \ No newline at end of file From e3c8b735bdd1c9443dc264f9793ad5f41621fe7e Mon Sep 17 00:00:00 2001 From: karel rehor Date: Wed, 2 Sep 2026 17:23:45 +0200 Subject: [PATCH 007/105] chore: add release command to model release step --- .github/workflows/maven-release.yml | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index b590d291..8b0e48e7 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -43,4 +43,9 @@ jobs: scm.tag=${RELEASE_TAG_NAME} EOF cat release.properties - ls -al \ No newline at end of file + ls -al + # TODO fix -Darguments - we don't want to skip everything in production + mvn release:perform \ + -Dgoals=deploy \ + -s ./deploy-settings.xml \ + -Darguments="-DskipTests -DskipITs -Dlicense.skip -DperformRelease=true" \ No newline at end of file From ca363cad5780197c52a47fda46a8be4bd9fd1572 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Thu, 3 Sep 2026 10:01:53 +0200 Subject: [PATCH 008/105] chore: reintroduce verify step to maven0release.yml workflow --- .github/workflows/maven-release.yml | 58 +++++++++++++++++++++++++++++ 1 file changed, 58 insertions(+) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index 8b0e48e7..65d8995f 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -35,7 +35,65 @@ jobs: sudo apt-get install libxml2-utils - name: Check environment run: | + # TODO this is a debug step and can be removed before push to production env + - name: Verify + run: | + if [[ -n "$SONATYPE_USERNAME" ]] + then + echo "DEBUG have SONATYPE_USERNAME" + else + echo "Release requires SONATYPE_USERNAME, which was not found. exiting" + exit 1 + fi + + if [[ -n "$SONATYPE_PASSWORD" ]] + then + echo "have SONATYPE_PASSWORD" + else + echo "Release requires SONATYPE_PASSWORD, which was not found. exiting" + exit 1 + fi + + if [[ -n "$GPG_PASSPHRASE_PRELIM" ]] + then + echo "have GPG_PASSPHRASE_PRELIM" + else + echo "Release requires GPG_PASSPHRASE, which was not found. exiting" + exit 1 + fi + + if [[ "$GPG_PASSPHRASE_PRELIM" == "EMPTY" ]] + then + echo "GPG_PASSPHRASE empty requested" + export GPG_PASSPHRASE="" + else + export GPG_PASSPHRASE="$GPG_PASSPHRASE_PRELIM" + fi + + echo "DEBUG GPG_PASSPHRASE ${GPG_PASSPHRASE}" + + echo "GPG_PASSPHRASE=${GPG_PASSPHRASE}" >> $GITHUB_ENV + + echo "ROVER_ACTION=JUMP_THE_FENCE" >> $GITHUB_ENV + + # Verify GPG2 environment + if ! command -v gpg2 &> /dev/null + then + echo "Failed to locate gpg2 on this host. GPG2 is required to continue." + exit 1 + fi + + gpg2 --version + export GPG_EXECUTABLE=$(command -v gpg2) + echo "DEBUG GPG_EXECUTABLE ${GPG_EXECUTABLE}" + + echo "DEBUG MAVEN_SETTINGS_EXPERIM ${MAVEN_SETTINGS_EXPERIM}" + echo "DEBUG MAVEN_SETTINGS_FILE ${{ vars.MAVEN_SETTINGS_FILE }}" + + # N.B. this is for debugging only. TODO remove before release + mvn -s ${{ vars.MAVEN_SETTINGS_FILE }} help:effective-settings + # mvn help:effective-settings - name: Model release run: | cat << EOF > release.properties From ef9469d16b1b905c1a98681551eeca3f6095c0d7 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Thu, 3 Sep 2026 14:08:33 +0200 Subject: [PATCH 009/105] docs: start RELEASE.md --- RELEASE.md | 133 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 133 insertions(+) create mode 100644 RELEASE.md diff --git a/RELEASE.md b/RELEASE.md new file mode 100644 index 00000000..c44aaae6 --- /dev/null +++ b/RELEASE.md @@ -0,0 +1,133 @@ +## Releasing + +This document contains a general description and tips for releasing Influxdb3-java using Github Actions with the ultimate goal of pushing the release to Maven Central. + +### Generating a new GPG signing key + +1. Generate a random password for the key. + +e.g. On a Linux box... + +``` +$ head -c 6 /dev/urandom | base64 | tr -dc 'a-zA-Z0-9+-' +HiF4YcF +``` + +Store this somewhere safe. + +2. Generate a key with a passphrase and no expiration. + +``` +gpg --batch --passphrase= --quick-generate-key "@users.noreply.github.com" default default never +``` + +TODO - to be continued. + +### Addenda + +#### Revoking a compromised GPG2 key + +1. verify that the key is on the local server. + +``` +$ gpg2 --list-keys +/home/karl/.gnupg/pubring.kbx +----------------------------- +pub ed25519 2026-07-27 [SC] [expires: 2029-07-26] + KEY_ID_REDACTED +uid [ultimate] karel-rehor@users.noreply.github.com +sub REDACTED 2026-07-27 [E] + +``` + +or... + +``` +$ gpg2 --list-keys KEY_ID_REDACTED +pub ed25519 2026-07-27 [SC] [expires: 2029-07-26] + KEY_ID_REDACTED +uid [ultimate] karel-rehor@users.noreply.github.com +sub REDACTED 2026-07-27 [E] +``` + +2. Verify that the key is on the remote server. + +``` +$ gpg2 --keyserver keyserver.ubuntu.com --search-keys KEY_ID_REDACTED +gpg: data source: http://185.125.188.27:11371 +(1) karel-rehor@users.noreply.github.com + 263 bit EDDSA key REDACTED, created: 2026-07-27 +Keys 1-1 of 1 for "KEY_ID_REDACTED". Enter number(s), N)ext, or Q)uit > 1 +gpg: key REDACTED: "karel-rehor@users.noreply.github.com" not changed +gpg: Total number processed: 1 +gpg: unchanged: 1 +``` + +3. Create a revocation request locally. + +``` +$ gpg2 --output revoke-karel-rehor.asc --gen-revoke KEY_ID_REDACTED +... +``` + +4. Revoke the key locally. + +``` +$ gpg2 --import revoke-karel-rehor.asc +gpg: key REDACTED: "karel-rehor@users.noreply.github.com" revocation certificate imported +gpg: Total number processed: 1 +gpg: new key revocations: 1 +gpg: marginals needed: 3 completes needed: 1 trust model: pgp +gpg: depth: 0 valid: 1 signed: 0 trust: 0-, 0q, 0n, 0m, 0f, 1u +gpg: next trustdb check due at 2029-07-26 +``` + +5. Verify revocation succeeded. + +``` +$ gpg2 --list-keys +/home/karl/.gnupg/pubring.kbx +----------------------------- +pub ed25519 2026-07-27 [SC] [revoked: 2026-09-03] + KEY_ID_REDACTED +uid [ revoked] karel-rehor@users.noreply.github.com +``` + +6. Push change of key state to remote server. + +``` +$ gpg2 --keyserver keyserver.ubuntu.com --send-keys KEY_ID_REDACTED +gpg: sending key REDACTED to hkp://keyserver.ubuntu.com +``` + +7. Verify key state on remote server. + +``` +$ gpg2 --keyserver keyserver.ubuntu.com --search-keys KEY_ID_REDACTED +gpg: data source: http://185.125.188.27:11371 +gpg: key "KEY_ID_REDACTED" not found on keyserver +``` + +8. Delete secret key locally. + +``` +$ gpg2 --delete-secret-key KEY_ID_REDACTED +... +# Confirmation required +``` + +9. Delete key locally + +``` +$ gpg2 --delete-key 01EAECEC736391172C6520F48B5778484117B952 +... +# Confirmation required +``` + +10. Verify key is deleted + +``` +$ gpg2 --list-keys +gpg: checking the trustdb +gpg: no ultimately trusted keys found +``` From 1bb389637b8a9834de39a4d74e48285a4a4f1a28 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Thu, 3 Sep 2026 15:07:40 +0200 Subject: [PATCH 010/105] docs: document gpg2 key generation in RELEASE.md. --- RELEASE.md | 53 +++++++++++++++++++++++++++++++++++++++++++++++++---- 1 file changed, 49 insertions(+), 4 deletions(-) diff --git a/RELEASE.md b/RELEASE.md index c44aaae6..75259c32 100644 --- a/RELEASE.md +++ b/RELEASE.md @@ -10,18 +10,63 @@ e.g. On a Linux box... ``` $ head -c 6 /dev/urandom | base64 | tr -dc 'a-zA-Z0-9+-' -HiF4YcF +jEtkLlyG ``` - Store this somewhere safe. 2. Generate a key with a passphrase and no expiration. ``` -gpg --batch --passphrase= --quick-generate-key "@users.noreply.github.com" default default never +$ gpg --batch --passphrase= --quick-generate-key "karel-rehor@users.noreply.github.com" default default never +gpg: revocation certificate stored as '/home/karl/.gnupg/openpgp-revocs.d/REDACTED_KEY_ID.rev' +``` + +3. Verify key. + +``` +$ gpg --list-keys +gpg: checking the trustdb +gpg: marginals needed: 3 completes needed: 1 trust model: pgp +gpg: depth: 0 valid: 1 signed: 0 trust: 0-, 0q, 0n, 0m, 0f, 1u +/home/karl/.gnupg/pubring.kbx +----------------------------- +pub ed25519 2026-09-03 [SC] + REDACTED_KEY_ID +uid [ultimate] karel-rehor@users.noreply.github.com +sub cv25519 2026-09-03 [E] +``` + +4. Distribute the key. + +``` +$ gpg2 --keyserver keyserver.ubuntu.com --send-keys REDACTED_KEY_ID +gpg: sending key REDACETD to hkp://keyserver.ubuntu.com +``` + +5. Verify key is on remote. Note, that it may take a few minutes to be registered. + +``` +$ gpg2 --keyserver keyserver.ubuntu.com --search-keys REDACTED_KEY_ID +gpg: data source: http://185.125.188.27:11371 +(1) karel-rehor@users.noreply.github.com + 263 bit EDDSA key REDACTED, created: 2026-09-03 +Keys 1-1 of 1 for "REDACTED_KEY_ID". Enter number(s), N)ext, or Q)uit > 1 +gpg: key REDACTED: "karel-rehor@users.noreply.github.com" not changed +gpg: Total number processed: 1 +gpg: unchanged: 1 +``` + +6. Get the secret key associated with this key. It will need to be copied then pasted to the Github project secret GPG_PRIVATE_KEY. Note you will be prompted for the passphrase. + +``` +$ gpg2 --export-secret-keys --armor REDACTED_KEY_ID +-----BEGIN PGP PRIVATE KEY BLOCK----- + + ...REDACTED... + +-----END PGP PRIVATE KEY BLOCK----- ``` -TODO - to be continued. ### Addenda From f9695e41f3dae2a2594f427851e0d18d4ba0f9f0 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Thu, 3 Sep 2026 16:43:36 +0200 Subject: [PATCH 011/105] chore: reintroduce checks in scripts/on-release.sh --- .github/workflows/maven-release.yml | 9 ++ scripts/on-release.sh | 231 ++++++++++++++++++++++++++++ 2 files changed, 240 insertions(+) create mode 100644 scripts/on-release.sh diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index 65d8995f..296fb3d8 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -94,8 +94,17 @@ jobs: # N.B. this is for debugging only. TODO remove before release mvn -s ${{ vars.MAVEN_SETTINGS_FILE }} help:effective-settings # mvn help:effective-settings + - name: Script + run: | + echo "DEBUG IS_PRERELEASE ^^^${IS_PRERELEASE}^^^" + echo "DEBUG GITHUB_ACTOR ${GITHUB_ACTOR}" + ./scripts/on-release.sh - name: Model release run: | + if [[ "${IS_PRERELEASE}" == "true" ]]; then + echo "This is a pre release and will not be deployed to Maven Central." + exit 0 + fi cat << EOF > release.properties scm.url=scm\:git\:https\://github.com/${GITHUB_REPOSITORY}.git scm.tag=${RELEASE_TAG_NAME} diff --git a/scripts/on-release.sh b/scripts/on-release.sh new file mode 100644 index 00000000..b472eeb0 --- /dev/null +++ b/scripts/on-release.sh @@ -0,0 +1,231 @@ +#!/usr/bin/env bash +# +# The MIT License +# +# Permission is hereby granted, free of charge, to any person obtaining a copy +# of this software and associated documentation files (the "Software"), to deal +# in the Software without restriction, including without limitation the rights +# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +# copies of the Software, and to permit persons to whom the Software is +# furnished to do so, subject to the following conditions: +# +# The above copyright notice and this permission notice shall be included in +# all copies or substantial portions of the Software. +# +# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +# THE SOFTWARE. +# + +set -e + +echo "Starting ${0}" + +if [ -z "${GITHUB_ACTIONS}" ] +then + echo "This script can only be run in a Github action container." + echo "Local runs are not yet supported." + exit 1 +fi +SCRIPT_DIR=$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd ) +PROJECT_DIR="${SCRIPT_DIR}/.." +CHANGELOG_PATH="${PROJECT_DIR}/CHANGELOG.md" +README_PATH="${PROJECT_DIR}/README.md" +POM_XML_PATH="${PROJECT_DIR}/pom.xml" + +RELEASE_NUM="" +NEXT_RELEASE_NUM="" +NEXT_RELEASE_BRANCH_BASE="chore/prepare-next-release-" +RC_OR_BETA=false +IS_SNAPSHOT=false + +FAILURE_BOILERPLATE="Please delete the tag ${CIRCLE_TAG} and the related release, and start again." + +# GITHUB_REF_NAME=v0.2.0 + +echo "DEBUG GITHUB_REF_NAME #${GITHUB_REF_NAME}#" + +#if [[ ${IS_PRERELEASE} ]]; then +# "DEBUG detected PRERELEASE" +#else +# "DEBUG PRERELEASE NOT detected" +#fi + +echo "DEBUG IS_PRERELEASE #${IS_PRERELEASE}#" + +echo "DEBUG AUTHOR NAME #${RELEASE_AUTHOR_NAME}#" +echo "DEBUG SONATYPE_USERNAME #${SONATYPE_USERNAME}#" + +github_check(){ + + if [ "${GITHUB_EVENT_NAME}" == "workflow_dispatch" ]; then + echo "WARNING: This script is targeted for 'release' not ${GITHUB_EVENT_NAME}." + echo "Continuing for debugging." + return + fi + + if [ "${GITHUB_EVENT_NAME}" == "push" ]; then + RELEASE_TAG_MATCH="^v[0-9]+(\.[0-9]+){2}(-(rc|beta)[0-9]+)?$" + echo "WARNING: this script is targeted for 'release' not ${GITHUB_EVENT_NAME}" + + if [[ "$GITHUB_REF_NAME" =~ $RELEASE_TAG_MATCH ]]; then + echo "Detected matching tag value in GITHUB_REF_NAME (${GITHUB_REF_NAME}). Continuing for debugging purposes." + RELEASE_TAG_NAME="${GITHUB_REF_NAME}" + return + else + echo " Checking env" + env + exit 1 + fi + fi + + if [ "${GITHUB_EVENT_NAME}" != "release" ]; then + echo "This script can run only on 'release'. Detected Github event ${GITHUB_EVENT_NAME}." + exit 1 + fi + + if [ -z "${RELEASE_TAG_NAME}" ]; then + echo "This script requires a release tag, but none was found." + exit 1 + fi + + echo "Running ${GITHUB_EVENT_NAME} with tag ${RELEASE_TAG_NAME}." +} + +setup(){ + ADDITIONAL_INSTALLS="" + if ! [ -x "$(command -v xmllint)" ] + then + ADDITIONAL_INSTALLS="${ADDITIONAL_INSTALLS} libxml2-utils" + else + printf "have xmllint\n" + fi + + if [ -n "${ADDITIONAL_INSTALLS}" ] + then + printf "This script requires the following unavailable libraries: %s\n" "${ADDITIONAL_INSTALLS}" + printf "Please install them and then continue.\n" + printf "%s\n" "${FAILURE_BOILERPLATE}" + exit 1 + else + printf "Additional requirements already satisfied.\n" + fi +} + +set_release_number(){ + RELEASE_NUM=$(echo ${RELEASE_TAG_NAME} | sed -r "s/-(rc|beta)[0-9]+//" | sed -r "s/^v//") +} + +verify_rc_or_beta(){ + if [ -n "$(echo ${RELEASE_TAG_NAME} | grep -E "rc|beta")" ] + then + RC_OR_BETA=true + fi +} + +verify_changelog() { + + CHANGELOG_RELEASE_HEADERS=$(sed -n '/^#.*[0-9].[0-9]*.[0-9].*/p' "${CHANGELOG_PATH}") + + mapfile -t HEADER_ARRAY <<< "$CHANGELOG_RELEASE_HEADERS" + + mapfile -td ' ' HEADER_LINE <<< "${HEADER_ARRAY[0]}" + + HEADER_TAG="${HEADER_LINE[1]}" + HEADER_DATE="${HEADER_LINE[2]:1:-2}" + + if [ "$HEADER_TAG" != "$RELEASE_NUM" ]; then + printf "ERROR: Latest HEADER_TAG in CHANGELOG.md (%s) does not match release number (%s) from git tag (%s)\n" \ + "$HEADER_TAG" \ + "$RELEASE_NUM" \ + "$RELEASE_TAG_NAME" + printf "Please update the latest HEADER_TAG in CHANGELOG.md\n" + printf "%s" "${FAILURE_BOILERPLATE}" + exit 1 + else + printf "CHANGELOG.md release number check: OK ✓\n" + fi + + if [[ ! "$HEADER_DATE" =~ ^[0-9]{4}-[0-9]{2}-[0-9]{2}$ ]]; then + printf "ERROR invalid commit date (%s) in last CHANGELOG.md entry\n" "$HEADER_DATE" + printf "Please update the commit date in CHANGELOG.md\n" + printf "%s\n" "${FAILURE_BOILERPLATE}" + exit 1 + else + printf "CHANGELOG.md release date check: OK ✓\n" + fi +} + +verify_version(){ + printf "verifying version\n" + PROJECT_VERSION=$(xmllint --xpath "//*[local-name()='project']/*[local-name()='version']/text()" ${POM_XML_PATH}"") + printf "Project version from pom.xml is %s\n" "${PROJECT_VERSION}" + + if [[ "${PROJECT_VERSION}" == *SNAPSHOT ]] + then + printf "Version in %s (%s) is a snapshot.\n" "${POM_XML_PATH}" "${PROJECT_VERSION}" + printf "This script does not release snapshots.\n" + printf "%s\n" "${FAILURE_BOILERPLATE}" + exit 1 + fi + + if [ "${PROJECT_VERSION}" != "${RELEASE_NUM}" ] + then + printf "PROJECT_VERSION %s in pom.xml does not match tag %s" "${PROJECT_VERSION}" "${RELEASE_TAG_NAME}" + printf "%s\n" "${FAILURE_BOILERPLATE}" + exit 1 + fi + + printf "pom.xml project version (%s) checks with release tag (%s): OK ✓\n" "${PROJECT_VERSION}" "${RELEASE_TAG_NAME}" + # TODO further checks + +} + +verify_readme(){ + printf "Verifying README %s\n" "${README_PATH}" + README_NODE_RAW="$(sed -n "/.*<\/version>/p" "${README_PATH}")" + + if [ -z "${README_NODE_RAW}" ] + then + printf "Example in %s with tag not found.\n" "${README_PATH}" + printf "The %s file should include an example with the current release version.\n" "${README_PATH}" + printf "Exiting...\n" + printf "%s\n" "${FAILURE_BOILERPLATE}" + exit 1 + fi + + README_NODE="${README_NODE_RAW#"${README_NODE_RAW%%[![:space:]]*}"}" + README_VERSION="$(echo "${README_NODE}" | sed "s///" | sed "s/<\/version>//")" + + if ! [ "${RELEASE_NUM}" == "${README_VERSION}" ] + then + VERSION_LINE=$(grep -n ".*" "${README_PATH}" | awk -F '[:]' '{ print $1 }') + printf "Release tag (%s) does not match example in README.md (%s) on line %s.\n" "${RELEASE_NUM}" "${README_VERSION}" "${VERSION_LINE}" + printf "Please update README.md to the current release before continuing.\n" + printf "%s\n" "${FAILURE_BOILERPLATE}" + exit 1 + fi + + printf "Version in README.md (%s) OK ✓.\n" "${README_VERSION}" +} + +echo "Running in Github Actions container." + +github_check + +verify_rc_or_beta +set_release_number + +verify_changelog +verify_readme +verify_version + +setup + +echo "====== DEBUG ENV =====" + +env \ No newline at end of file From 46bf3d13a9ac978d1d0f60163c209cfc771cdcbb Mon Sep 17 00:00:00 2001 From: karel rehor Date: Thu, 3 Sep 2026 17:05:02 +0200 Subject: [PATCH 012/105] docs: update temporary notes in CHANGELOG.md --- CHANGELOG.md | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index ce56bab6..60609662 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,24 @@ ## 1.12.0 [unreleased] +### karel-rehor fork TODOs + +- `pom.xml` + 1. ~~cleanup to get stable working release with `central-publishing-maven-plugin`~~. DONE + 2. Once the above is proven to work - revert `scm` and other values to `influxCommunity` before creating PR to production. +- `.github/workflows/maven-release.yml` - ~~some tasks defined in `maven-release.yml` are covered by the maven release plugin workflow. This includes automated tag generation, which may cause conflicts. So, the workflow needs a review and some revisions~~. DONE + - Workflow successfully revised. But no longer relying on `mvn release:prepare` to create tags and update `pom.xml`. + - So need to ensure that support scripts and workflow put everything into place correctly. IN PROGRESS +- Look into using `mvn versions:set` for updating pom.xml after successful release IN PROGRESS +- Need to implement documentation releasing step. From manual instructions... TODO +``` +mvn clean site site:stage -DskipTests +mvn scm-publish:publish-scm +``` +- Document new releasing procedures in `RELEASE.md` and in bonitoo docs. IN PROGRESS (note RELEASE.md document already started in branch ci/gh-action-maven-releasing) +- Full cycle test with above changes - then drop test release. PARTIALLY DONE - Core workflow validated and results dropped. +- Test hot release (1.11.1?) from maven central using fork. Can it be used in a client app? +- Cleanup, including removing this TODO List, and create PR. + ## 1.11.0 [2026-08-27] ### Breaking Changes From e26af07161659338d77e215cc8ad6ed277ad9356 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Fri, 4 Sep 2026 09:30:45 +0200 Subject: [PATCH 013/105] chore: fix file permissions for on-release.sh --- scripts/on-release.sh | 0 1 file changed, 0 insertions(+), 0 deletions(-) mode change 100644 => 100755 scripts/on-release.sh diff --git a/scripts/on-release.sh b/scripts/on-release.sh old mode 100644 new mode 100755 From bdcffe002d596ced41d8f1245986c67b4eca685d Mon Sep 17 00:00:00 2001 From: karel rehor Date: Fri, 4 Sep 2026 10:30:44 +0200 Subject: [PATCH 014/105] docs: temporary change to release date - for testing workflow. --- CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 60609662..dbac6731 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,4 +1,4 @@ -## 1.12.0 [unreleased] +## 1.12.0 [2026-09-04] ### karel-rehor fork TODOs From e0a9412433d0ec263789e78eb6c86b3f02f08061 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Fri, 4 Sep 2026 10:42:55 +0200 Subject: [PATCH 015/105] docs: temporary update toe README.md to test workflow. --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index a99836d2..9cbcf78e 100644 --- a/README.md +++ b/README.md @@ -49,7 +49,7 @@ Add the latest version of the client to your project: com.influxdb influxdb3-java - 1.11.0 + 1.12.0 ``` From 4e5224187f6436db4b6c4a1bfafef2bf831f4801 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Fri, 4 Sep 2026 14:14:30 +0200 Subject: [PATCH 016/105] chore: set correct scm version an update RELEASE.md --- RELEASE.md | 65 +++++++++++++++++++++++++++++++++++++++++++++++------- pom.xml | 2 +- 2 files changed, 58 insertions(+), 9 deletions(-) diff --git a/RELEASE.md b/RELEASE.md index 75259c32..87575867 100644 --- a/RELEASE.md +++ b/RELEASE.md @@ -2,11 +2,64 @@ This document contains a general description and tips for releasing Influxdb3-java using Github Actions with the ultimate goal of pushing the release to Maven Central. -### Generating a new GPG signing key +### Preparing the release. -1. Generate a random password for the key. +1. from `main` create a new release branch, e.g. `git branch chore/release-1.12.0` +2. In the new branch, update the version settings in `pom.xml` -e.g. On a Linux box... +``` +$ mvn versions:set -DremoveSnapshot=true +$ mvn versions:set-scm-tag -DnewTag="v1.12.0" +``` +3. In `README.md` update the `` tag value in the Maven dependency example. +4. Update the date for this release to the current date. +5. Commit and push these changes to Github. + +### Initiating the release + +In Github `influxComunit/influxb3-java`... + +1. In the project home page open the _Releases_ section. +2. Click _Draft a new release_ +3. In the _Target_ drop down check the release branch. +4. In the _Tag_ drop down click `Create new tag`, supply the tag matching the value added in the `set-scm-tag` command above. Note that the tag should be prefixed with the letter _v_. Click _Create_. +5. In the _Release title_ text control set the title to match the `` tag in `pom.xml`. +6. In the _Release notes_ text field copy changes added since the last release from `CHANEGLOG.md`. +7. If this is a pre-release check the radio button. Note that the release workflow will not publish pre-release builds to Maven Central. +8. Click `Publish release`. + +The creation of the new release will trigger the `maven-release.yml` workflow. It will: + +1. Verify required secrets and environment variables are set +2. Check that the `pom.xml` version matches the release tag and that versioning references in documentation are up-to-date and valid. +3. Check and sign the build. +4. Upload the archives and pom files to Maven Central. +5. TODO - Publish documentation to https://github.com/influxcommunity/influxdb3-java/tree/gh-pages +5. TODO - prepare the `pom.xml` and `CHANGELOG.md` files for the next release cycle and push them in a new branch. + +### Preparing the next release cycle + +A new branch with an updated `pom.xml` file will have been created by the Maven Release action. + +1. create a PR to merge the branch into `main`. +2. review the PR and if everything has been generated correctly, squash and merge it. + +## The Release environment + +The release workflow is managed by `.github/workflows/maven-release.yml`. In order for the release workflow to succeed a number of environment secrets need to be set in the project. It may be necessary to update these in the future. + +- `GPG_PASSPHRASE` - password for the key used to sign archives and pom files to be uploaded to Maven Central. See _Generating a new GPG signing key_ below. +- `GPG_PRIVATE_KEY` - private key associate with public key pulled from a GPG repository and used to sign archives and pom files. +- `SONATYPE_PASSWORD` - password for the user account used to upload archives and pom files to Maven Central. +- `SONATYPE_USERNAME` - name of user account used to upload archives and pom files to Maven Central. + +### Addenda + +#### Generating a new GPG signing key + +1. Generate a random password for the key. + +e.g. On a Linux box... ``` $ head -c 6 /dev/urandom | base64 | tr -dc 'a-zA-Z0-9+-' @@ -14,7 +67,7 @@ jEtkLlyG ``` Store this somewhere safe. -2. Generate a key with a passphrase and no expiration. +2. Generate a key with a passphrase and no expiration. ``` $ gpg --batch --passphrase= --quick-generate-key "karel-rehor@users.noreply.github.com" default default never @@ -65,10 +118,6 @@ $ gpg2 --export-secret-keys --armor REDACTED_KEY_ID ...REDACTED... -----END PGP PRIVATE KEY BLOCK----- -``` - - -### Addenda #### Revoking a compromised GPG2 key diff --git a/pom.xml b/pom.xml index 8c873d20..0e4e0843 100644 --- a/pom.xml +++ b/pom.xml @@ -67,7 +67,7 @@ scm:git:https://github.com/karel-rehor/influxdb3-java.git scm:git:git@github.com:karel-rehor/influxdb3-java.git https://github.com/karel-rehor/influxdb3-java/tree/main - HEAD + v1.12.0 From 8dff66dd12031d5b11097fabced50da2bec907d2 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Fri, 4 Sep 2026 14:57:02 +0200 Subject: [PATCH 017/105] chore: add scm/tag value check to on-release.sh --- RELEASE.md | 2 +- scripts/on-release.sh | 10 +++++++++- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/RELEASE.md b/RELEASE.md index 87575867..085d86da 100644 --- a/RELEASE.md +++ b/RELEASE.md @@ -4,7 +4,7 @@ This document contains a general description and tips for releasing Influxdb3-ja ### Preparing the release. -1. from `main` create a new release branch, e.g. `git branch chore/release-1.12.0` +1. from `main` create a new release branch, e.g. `git branch chore/release-1.12.0 git && git switch chore/release-1.12.0` 2. In the new branch, update the version settings in `pom.xml` ``` diff --git a/scripts/on-release.sh b/scripts/on-release.sh index b472eeb0..db370602 100755 --- a/scripts/on-release.sh +++ b/scripts/on-release.sh @@ -181,7 +181,15 @@ verify_version(){ fi printf "pom.xml project version (%s) checks with release tag (%s): OK ✓\n" "${PROJECT_VERSION}" "${RELEASE_TAG_NAME}" - # TODO further checks + + SCM_TAG=$(xmllint --xpath "//*[local-name()='project']/*[local-name()='scm']/*[local-name()='tag']/text()") + + if [ "${SCM_TAG}" != "${RELEASE_TAG_NAME}" ] + then + printf "SCM_TAG %s in pom.xml does not match tag %s" "${SCM_TAG}" "${RELEASE_TAG_NAME}" + prinf "%s\n" "${FAILURE_BOILERPLATE}" + exit 1 + fi } From 1eee6769dd0d218d52287bfe6eef1f376d01ef70 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Fri, 4 Sep 2026 15:05:49 +0200 Subject: [PATCH 018/105] chore: fix dropped variable in on-release.sh --- scripts/on-release.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/on-release.sh b/scripts/on-release.sh index db370602..52584b95 100755 --- a/scripts/on-release.sh +++ b/scripts/on-release.sh @@ -162,7 +162,7 @@ verify_changelog() { verify_version(){ printf "verifying version\n" - PROJECT_VERSION=$(xmllint --xpath "//*[local-name()='project']/*[local-name()='version']/text()" ${POM_XML_PATH}"") + PROJECT_VERSION=$(xmllint --xpath "//*[local-name()='project']/*[local-name()='version']/text()" "${POM_XML_PATH}") printf "Project version from pom.xml is %s\n" "${PROJECT_VERSION}" if [[ "${PROJECT_VERSION}" == *SNAPSHOT ]] @@ -182,7 +182,7 @@ verify_version(){ printf "pom.xml project version (%s) checks with release tag (%s): OK ✓\n" "${PROJECT_VERSION}" "${RELEASE_TAG_NAME}" - SCM_TAG=$(xmllint --xpath "//*[local-name()='project']/*[local-name()='scm']/*[local-name()='tag']/text()") + SCM_TAG=$(xmllint --xpath "//*[local-name()='project']/*[local-name()='scm']/*[local-name()='tag']/text()" "${POM_XML_PATH}") if [ "${SCM_TAG}" != "${RELEASE_TAG_NAME}" ] then From dabbd1f1c4cf1ea3ad308ee0daf1393214f51b00 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Fri, 4 Sep 2026 15:13:23 +0200 Subject: [PATCH 019/105] chore: temporarily change scm tag to test workflow failure. --- pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pom.xml b/pom.xml index 0e4e0843..8c873d20 100644 --- a/pom.xml +++ b/pom.xml @@ -67,7 +67,7 @@ scm:git:https://github.com/karel-rehor/influxdb3-java.git scm:git:git@github.com:karel-rehor/influxdb3-java.git https://github.com/karel-rehor/influxdb3-java/tree/main - v1.12.0 + HEAD From 93a7e9d4c8bae999b16a2cdb341b2e587b4df9b7 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Fri, 4 Sep 2026 15:19:43 +0200 Subject: [PATCH 020/105] chore: revert scm tag in pom.xml after workflow test proven correct. --- pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pom.xml b/pom.xml index 8c873d20..0e4e0843 100644 --- a/pom.xml +++ b/pom.xml @@ -67,7 +67,7 @@ scm:git:https://github.com/karel-rehor/influxdb3-java.git scm:git:git@github.com:karel-rehor/influxdb3-java.git https://github.com/karel-rehor/influxdb3-java/tree/main - HEAD + v1.12.0 From fdce5bc39d611a8e9d4eef3e3884acef33c2fc1e Mon Sep 17 00:00:00 2001 From: karel rehor Date: Fri, 4 Sep 2026 17:07:18 +0200 Subject: [PATCH 021/105] chore: start workflow step Prepare next cycle. --- .github/workflows/maven-release.yml | 22 +++++++++++++++++++++- CHANGELOG.md | 1 + 2 files changed, 22 insertions(+), 1 deletion(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index 296fb3d8..72951739 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -115,4 +115,24 @@ jobs: mvn release:perform \ -Dgoals=deploy \ -s ./deploy-settings.xml \ - -Darguments="-DskipTests -DskipITs -Dlicense.skip -DperformRelease=true" \ No newline at end of file + -Darguments="-DskipTests -DskipITs -Dlicense.skip -DperformRelease=true" + - name: Prepare next cycle + run: | + if [[ "${IS_PRERELEASE}" == "true" ]]; then + echo "This is a prerelease so the next release cycle will not be prepared." + echo "TODO in production exit cleanly here. But for debugging purposes currently continue" + fi + echo "Preparing next release cycle" + + VERSION_CLEAN=${TEST_TAG_NAME:1} + PARTS=(${VERSION_CLEAN//./ }) + NEW_MINOR=$((PARTS[1]+1)) + NEXT_RELEASE="${PARTS[0]}.${NEW_MINOR}.${PARTS[2]}" + echo "DEBUG NEXT_RELEASE %s" "${NEXT_RELEASE}" + gh --version + git branch + mvn versions:set-scm-tag -DnewTag="HEAD" + mvn versions:set -DnextSnapshot=true -DnextSnapshotIndexToIncrement=2 + # DEBUG command below + head -n 72 pom.xml + # gh pr create -B base_branch -H branch_to_merge --title 'Merge branch_to_merge into base_branch' --body 'Created by Github action' \ No newline at end of file diff --git a/CHANGELOG.md b/CHANGELOG.md index dbac6731..f6163c56 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -8,6 +8,7 @@ - `.github/workflows/maven-release.yml` - ~~some tasks defined in `maven-release.yml` are covered by the maven release plugin workflow. This includes automated tag generation, which may cause conflicts. So, the workflow needs a review and some revisions~~. DONE - Workflow successfully revised. But no longer relying on `mvn release:prepare` to create tags and update `pom.xml`. - So need to ensure that support scripts and workflow put everything into place correctly. IN PROGRESS + - add scm:tag check to on-release.sh - 1eee676. N.B. this was still using HEAD in jar and pom pushed to Maven Central. - Look into using `mvn versions:set` for updating pom.xml after successful release IN PROGRESS - Need to implement documentation releasing step. From manual instructions... TODO ``` From d07c44f02256217efc331ba3e825b102ce98e543 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Mon, 7 Sep 2026 09:34:32 +0200 Subject: [PATCH 022/105] chore: get correct TAG_NAME envar in workflow script. --- .github/workflows/maven-release.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index 72951739..ce64ee4f 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -124,7 +124,7 @@ jobs: fi echo "Preparing next release cycle" - VERSION_CLEAN=${TEST_TAG_NAME:1} + VERSION_CLEAN=${RELEASE_TAG_NAME} PARTS=(${VERSION_CLEAN//./ }) NEW_MINOR=$((PARTS[1]+1)) NEXT_RELEASE="${PARTS[0]}.${NEW_MINOR}.${PARTS[2]}" From 8b9409aa90c5e2c1bebaefcf6eab64837caeb95e Mon Sep 17 00:00:00 2001 From: karel rehor Date: Mon, 7 Sep 2026 09:59:01 +0200 Subject: [PATCH 023/105] chore: set next release cycle branch --- .github/workflows/maven-release.yml | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index ce64ee4f..39966732 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -128,9 +128,12 @@ jobs: PARTS=(${VERSION_CLEAN//./ }) NEW_MINOR=$((PARTS[1]+1)) NEXT_RELEASE="${PARTS[0]}.${NEW_MINOR}.${PARTS[2]}" - echo "DEBUG NEXT_RELEASE %s" "${NEXT_RELEASE}" + NEXT_RELEASE_BRANCH="ci/next-cycle-${NEXT_RELEASE} + echo "DEBUG NEXT_RELEASE ${NEXT_RELEASE} ${NEXT_RELEASE_BRANCH}" gh --version - git branch + git branch # FOR DEBUG AND VERIFICATION + git checkout -b ${NEXT_RELEASE_BRANCH} + git branch # FOR DEBUG AND VERIFICATION mvn versions:set-scm-tag -DnewTag="HEAD" mvn versions:set -DnextSnapshot=true -DnextSnapshotIndexToIncrement=2 # DEBUG command below From 933d9d5a3dfadf4ac47ed173a665798be1675136 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Mon, 7 Sep 2026 10:08:42 +0200 Subject: [PATCH 024/105] chore: fix broken variable string in script. --- .github/workflows/maven-release.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index 39966732..747b7c54 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -128,7 +128,7 @@ jobs: PARTS=(${VERSION_CLEAN//./ }) NEW_MINOR=$((PARTS[1]+1)) NEXT_RELEASE="${PARTS[0]}.${NEW_MINOR}.${PARTS[2]}" - NEXT_RELEASE_BRANCH="ci/next-cycle-${NEXT_RELEASE} + NEXT_RELEASE_BRANCH="ci/next-cycle-${NEXT_RELEASE}" echo "DEBUG NEXT_RELEASE ${NEXT_RELEASE} ${NEXT_RELEASE_BRANCH}" gh --version git branch # FOR DEBUG AND VERIFICATION From 602d2cb3b3cb55de83f96923cd6b909c720ef027 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Mon, 7 Sep 2026 10:21:01 +0200 Subject: [PATCH 025/105] chore: temporarily add debugging checks to workflow script. --- .github/workflows/maven-release.yml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index 747b7c54..3b7d3173 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -118,6 +118,8 @@ jobs: -Darguments="-DskipTests -DskipITs -Dlicense.skip -DperformRelease=true" - name: Prepare next cycle run: | + # DEBUG show commands only temporarily + set -x if [[ "${IS_PRERELEASE}" == "true" ]]; then echo "This is a prerelease so the next release cycle will not be prepared." echo "TODO in production exit cleanly here. But for debugging purposes currently continue" @@ -137,5 +139,9 @@ jobs: mvn versions:set-scm-tag -DnewTag="HEAD" mvn versions:set -DnextSnapshot=true -DnextSnapshotIndexToIncrement=2 # DEBUG command below + echo "==== diff start" + git diff + echo "==== diff end" + # DEBUG command below head -n 72 pom.xml # gh pr create -B base_branch -H branch_to_merge --title 'Merge branch_to_merge into base_branch' --body 'Created by Github action' \ No newline at end of file From c8b67a6d28d499c043f0a84a744c576bc818abb7 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Mon, 7 Sep 2026 10:40:00 +0200 Subject: [PATCH 026/105] chore: add automatic update to CHANGELOG.md in workflow. --- .github/workflows/maven-release.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index 3b7d3173..6a20820c 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -138,6 +138,7 @@ jobs: git branch # FOR DEBUG AND VERIFICATION mvn versions:set-scm-tag -DnewTag="HEAD" mvn versions:set -DnextSnapshot=true -DnextSnapshotIndexToIncrement=2 + sed -i "1s/^/### ${TEST_RELEASE_TAG:1} [unreleased]\n/" CHANGELOG.md # DEBUG command below echo "==== diff start" git diff From 29aff53d867de0548277e2a9bfc8024e946526de Mon Sep 17 00:00:00 2001 From: karel rehor Date: Mon, 7 Sep 2026 10:48:56 +0200 Subject: [PATCH 027/105] chore: use correct envar in workflow script. --- .github/workflows/maven-release.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index 6a20820c..e924c876 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -138,7 +138,7 @@ jobs: git branch # FOR DEBUG AND VERIFICATION mvn versions:set-scm-tag -DnewTag="HEAD" mvn versions:set -DnextSnapshot=true -DnextSnapshotIndexToIncrement=2 - sed -i "1s/^/### ${TEST_RELEASE_TAG:1} [unreleased]\n/" CHANGELOG.md + sed -i "1s/^/### ${NEXT_RELEASE:1} [unreleased]\n/" CHANGELOG.md # DEBUG command below echo "==== diff start" git diff From d4dc62238662b0e560ade85362b82707461cdc99 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Mon, 7 Sep 2026 10:56:51 +0200 Subject: [PATCH 028/105] chore: fix formatting of next release CHANGELOG.md header --- .github/workflows/maven-release.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index e924c876..918684c9 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -138,7 +138,7 @@ jobs: git branch # FOR DEBUG AND VERIFICATION mvn versions:set-scm-tag -DnewTag="HEAD" mvn versions:set -DnextSnapshot=true -DnextSnapshotIndexToIncrement=2 - sed -i "1s/^/### ${NEXT_RELEASE:1} [unreleased]\n/" CHANGELOG.md + sed -i "1s/^/## ${NEXT_RELEASE:1} [unreleased]\n\n/" CHANGELOG.md # DEBUG command below echo "==== diff start" git diff From 8098ee933adbeadfcb7776a738d392f920af6b9c Mon Sep 17 00:00:00 2001 From: karel rehor Date: Mon, 7 Sep 2026 13:11:33 +0200 Subject: [PATCH 029/105] chore: setup automated git commands for next release cycle. --- .github/workflows/maven-release.yml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index 918684c9..93d39550 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -143,6 +143,9 @@ jobs: echo "==== diff start" git diff echo "==== diff end" + git add pom.xml CHANGELOG.md + git commit -m "ci: setting up release cycle ${NEXT_RELEASE:1}" # DEBUG command below - head -n 72 pom.xml + git log -1 + git push # gh pr create -B base_branch -H branch_to_merge --title 'Merge branch_to_merge into base_branch' --body 'Created by Github action' \ No newline at end of file From 6c17568efb014b1c109c340b01742cd8f9e20ee7 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Mon, 7 Sep 2026 13:33:10 +0200 Subject: [PATCH 030/105] chore: setup github identity in release workflow prepare next cycle. --- .github/workflows/maven-release.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index 93d39550..f77427c2 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -133,6 +133,8 @@ jobs: NEXT_RELEASE_BRANCH="ci/next-cycle-${NEXT_RELEASE}" echo "DEBUG NEXT_RELEASE ${NEXT_RELEASE} ${NEXT_RELEASE_BRANCH}" gh --version + git config user.email "${GITHUB_ACTOR}@users.noreply.github.com" + git config user.name ${GITHUB_ACTOR} git branch # FOR DEBUG AND VERIFICATION git checkout -b ${NEXT_RELEASE_BRANCH} git branch # FOR DEBUG AND VERIFICATION From 4f69b6028e76c680c1079d792a47b214b4a90a14 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Mon, 7 Sep 2026 13:45:04 +0200 Subject: [PATCH 031/105] chore: fix push to origin in workstream Prepare next cycle. --- .github/workflows/maven-release.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index f77427c2..271c7524 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -149,5 +149,5 @@ jobs: git commit -m "ci: setting up release cycle ${NEXT_RELEASE:1}" # DEBUG command below git log -1 - git push + git push --set-upstream ${NEXT_RELEASE_BRANCH} # gh pr create -B base_branch -H branch_to_merge --title 'Merge branch_to_merge into base_branch' --body 'Created by Github action' \ No newline at end of file From 29d4bae48d01fbea5198b5e56a6925cf93b6b161 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Mon, 7 Sep 2026 14:00:32 +0200 Subject: [PATCH 032/105] chore: fix origin repository in workflow Prepare next release cycle. --- .github/workflows/maven-release.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index 271c7524..838b1d6a 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -149,5 +149,5 @@ jobs: git commit -m "ci: setting up release cycle ${NEXT_RELEASE:1}" # DEBUG command below git log -1 - git push --set-upstream ${NEXT_RELEASE_BRANCH} + git push --set-upstream origin ${NEXT_RELEASE_BRANCH} # gh pr create -B base_branch -H branch_to_merge --title 'Merge branch_to_merge into base_branch' --body 'Created by Github action' \ No newline at end of file From 6410172d4107b647a18f09a467e0fffc96cd3c49 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Mon, 7 Sep 2026 14:17:14 +0200 Subject: [PATCH 033/105] chore: setup automatic PR for new release cycle. --- .github/workflows/maven-release.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index 838b1d6a..353e6bcd 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -150,4 +150,4 @@ jobs: # DEBUG command below git log -1 git push --set-upstream origin ${NEXT_RELEASE_BRANCH} - # gh pr create -B base_branch -H branch_to_merge --title 'Merge branch_to_merge into base_branch' --body 'Created by Github action' \ No newline at end of file + gh pr create -B main -H ${NEXT_RELEASE_BRANCH} --title "Merge ${NEXT_RELEASE_BRANCH} into main" --body 'Created by Github action' From ff9cb5a994206680d3dd209a2df96e74b4567ce1 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Mon, 7 Sep 2026 14:28:59 +0200 Subject: [PATCH 034/105] chore: update permissions to allow creation of PR. --- .github/workflows/maven-release.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index 353e6bcd..feaefdc5 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -9,6 +9,7 @@ jobs: release: permissions: contents: write # may want to update version + pull-requests: write # will need to create PR for next release cycle branch runs-on: ubuntu-latest env: SONATYPE_USERNAME: ${{ secrets.SONATYPE_USERNAME }} @@ -150,4 +151,4 @@ jobs: # DEBUG command below git log -1 git push --set-upstream origin ${NEXT_RELEASE_BRANCH} - gh pr create -B main -H ${NEXT_RELEASE_BRANCH} --title "Merge ${NEXT_RELEASE_BRANCH} into main" --body 'Created by Github action' + gh pr create -B main -H ${NEXT_RELEASE_BRANCH} --title "ci: merge ${NEXT_RELEASE_BRANCH} into main" --body 'Created by Github action' From b0dbac5a53160cf9d874f428dd31369623a73a8d Mon Sep 17 00:00:00 2001 From: karel rehor Date: Mon, 7 Sep 2026 15:02:14 +0200 Subject: [PATCH 035/105] chore: remove automatic PR merge command - requires permission changes at org and project level to work. --- .github/workflows/maven-release.yml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index feaefdc5..354d4b61 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -9,7 +9,6 @@ jobs: release: permissions: contents: write # may want to update version - pull-requests: write # will need to create PR for next release cycle branch runs-on: ubuntu-latest env: SONATYPE_USERNAME: ${{ secrets.SONATYPE_USERNAME }} @@ -151,4 +150,4 @@ jobs: # DEBUG command below git log -1 git push --set-upstream origin ${NEXT_RELEASE_BRANCH} - gh pr create -B main -H ${NEXT_RELEASE_BRANCH} --title "ci: merge ${NEXT_RELEASE_BRANCH} into main" --body 'Created by Github action' + echo "The branch ${NEXT_RELEASE_BRANCH} has been created. You can create and merge a PR manually from it to start the next release cycle." From ee489d066a40901d31b33d9b26d0d40cffce621a Mon Sep 17 00:00:00 2001 From: karel rehor Date: Mon, 7 Sep 2026 16:38:26 +0200 Subject: [PATCH 036/105] chore: add site documentation update step. Update RELEASE.md --- .github/workflows/maven-release.yml | 8 ++++++++ CHANGELOG.md | 4 ++-- RELEASE.md | 22 +++++++++++++++------- 3 files changed, 25 insertions(+), 9 deletions(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index 354d4b61..f884652e 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -116,6 +116,14 @@ jobs: -Dgoals=deploy \ -s ./deploy-settings.xml \ -Darguments="-DskipTests -DskipITs -Dlicense.skip -DperformRelease=true" + - name: Publish documentation + run: | + if [[ "${IS_PRERELEASE}" == "true" ]]; then + echo "This is a pre release, so site documentation will not be updated to Github pages." + exit 0 + fi + mvn clean site site:stage -DskipTests + mvn scm-publish:publish-scm - name: Prepare next cycle run: | # DEBUG show commands only temporarily diff --git a/CHANGELOG.md b/CHANGELOG.md index f6163c56..15a5e9f8 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -9,8 +9,8 @@ - Workflow successfully revised. But no longer relying on `mvn release:prepare` to create tags and update `pom.xml`. - So need to ensure that support scripts and workflow put everything into place correctly. IN PROGRESS - add scm:tag check to on-release.sh - 1eee676. N.B. this was still using HEAD in jar and pom pushed to Maven Central. -- Look into using `mvn versions:set` for updating pom.xml after successful release IN PROGRESS -- Need to implement documentation releasing step. From manual instructions... TODO +- ~~Look into using `mvn versions:set` for updating pom.xml after successful release~~ DONE +- Need to implement documentation releasing step. From manual instructions... IN PROGRESS ``` mvn clean site site:stage -DskipTests mvn scm-publish:publish-scm diff --git a/RELEASE.md b/RELEASE.md index 085d86da..233c56f9 100644 --- a/RELEASE.md +++ b/RELEASE.md @@ -2,9 +2,17 @@ This document contains a general description and tips for releasing Influxdb3-java using Github Actions with the ultimate goal of pushing the release to Maven Central. +### Overview + +Releasing involves three general steps. + +1. Preparing the release in a new release branch +2. Triggering the automatic release by creating a new tag a release in Github. +3. Preparing the next release cycle by merging the next release branch created by the automated release script back into `main`. + ### Preparing the release. -1. from `main` create a new release branch, e.g. `git branch chore/release-1.12.0 git && git switch chore/release-1.12.0` +1. from `main` create a new release branch, e.g. `git checkout -b chore/release-1.12.0` 2. In the new branch, update the version settings in `pom.xml` ``` @@ -12,7 +20,7 @@ $ mvn versions:set -DremoveSnapshot=true $ mvn versions:set-scm-tag -DnewTag="v1.12.0" ``` 3. In `README.md` update the `` tag value in the Maven dependency example. -4. Update the date for this release to the current date. +4. In `CHANGELOG.md` verify all commit information for the current cycle is up-to-date, fix any discrepancies, then update the date for this release to the current date. 5. Commit and push these changes to Github. ### Initiating the release @@ -21,11 +29,11 @@ In Github `influxComunit/influxb3-java`... 1. In the project home page open the _Releases_ section. 2. Click _Draft a new release_ -3. In the _Target_ drop down check the release branch. +3. In the _Target_ drop down check the new release branch. 4. In the _Tag_ drop down click `Create new tag`, supply the tag matching the value added in the `set-scm-tag` command above. Note that the tag should be prefixed with the letter _v_. Click _Create_. 5. In the _Release title_ text control set the title to match the `` tag in `pom.xml`. 6. In the _Release notes_ text field copy changes added since the last release from `CHANEGLOG.md`. -7. If this is a pre-release check the radio button. Note that the release workflow will not publish pre-release builds to Maven Central. +7. If this is a pre-release check the _pre-release_ radio button. Note that the release workflow will not publish pre-release builds to Maven Central. 8. Click `Publish release`. The creation of the new release will trigger the `maven-release.yml` workflow. It will: @@ -35,13 +43,13 @@ The creation of the new release will trigger the `maven-release.yml` workflow. 3. Check and sign the build. 4. Upload the archives and pom files to Maven Central. 5. TODO - Publish documentation to https://github.com/influxcommunity/influxdb3-java/tree/gh-pages -5. TODO - prepare the `pom.xml` and `CHANGELOG.md` files for the next release cycle and push them in a new branch. +6. prepare the `pom.xml` and `CHANGELOG.md` files for the next release cycle and push them to a new branch named `ci/next-cycle-`. ### Preparing the next release cycle -A new branch with an updated `pom.xml` file will have been created by the Maven Release action. +A new branch `ci/next-cycle-` with an updated `pom.xml` file will have been created by the Maven Release action. -1. create a PR to merge the branch into `main`. +1. create a PR from the branch `ci/next-cycle-` to merge it into `main`. 2. review the PR and if everything has been generated correctly, squash and merge it. ## The Release environment From 9bc7007b2c8e183fb4ad172d86aecf782fcd0a7b Mon Sep 17 00:00:00 2001 From: karel rehor Date: Mon, 7 Sep 2026 17:19:21 +0200 Subject: [PATCH 037/105] chore: add checks and updates to examples/pom.xml --- .github/workflows/maven-release.yml | 15 +++++---------- scripts/on-release.sh | 13 +++++++++++++ 2 files changed, 18 insertions(+), 10 deletions(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index f884652e..47d7c71f 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -126,11 +126,12 @@ jobs: mvn scm-publish:publish-scm - name: Prepare next cycle run: | - # DEBUG show commands only temporarily + # DEBUGGING config follows set -x if [[ "${IS_PRERELEASE}" == "true" ]]; then echo "This is a prerelease so the next release cycle will not be prepared." - echo "TODO in production exit cleanly here. But for debugging purposes currently continue" + # exit 0 + echor "Continue for now for debugging and review" fi echo "Preparing next release cycle" @@ -139,23 +140,17 @@ jobs: NEW_MINOR=$((PARTS[1]+1)) NEXT_RELEASE="${PARTS[0]}.${NEW_MINOR}.${PARTS[2]}" NEXT_RELEASE_BRANCH="ci/next-cycle-${NEXT_RELEASE}" - echo "DEBUG NEXT_RELEASE ${NEXT_RELEASE} ${NEXT_RELEASE_BRANCH}" gh --version git config user.email "${GITHUB_ACTOR}@users.noreply.github.com" git config user.name ${GITHUB_ACTOR} - git branch # FOR DEBUG AND VERIFICATION git checkout -b ${NEXT_RELEASE_BRANCH} - git branch # FOR DEBUG AND VERIFICATION mvn versions:set-scm-tag -DnewTag="HEAD" mvn versions:set -DnextSnapshot=true -DnextSnapshotIndexToIncrement=2 sed -i "1s/^/## ${NEXT_RELEASE:1} [unreleased]\n\n/" CHANGELOG.md - # DEBUG command below - echo "==== diff start" + sed -i -e "s/${RELEASE_TAG_NAME:1}<\/version>/${NEXT_RELEASE:1}-SNAPSHOT<\/version>/" examples/pom.xml + # DEBUG step follows git diff - echo "==== diff end" git add pom.xml CHANGELOG.md git commit -m "ci: setting up release cycle ${NEXT_RELEASE:1}" - # DEBUG command below - git log -1 git push --set-upstream origin ${NEXT_RELEASE_BRANCH} echo "The branch ${NEXT_RELEASE_BRANCH} has been created. You can create and merge a PR manually from it to start the next release cycle." diff --git a/scripts/on-release.sh b/scripts/on-release.sh index 52584b95..4d80103f 100755 --- a/scripts/on-release.sh +++ b/scripts/on-release.sh @@ -36,6 +36,7 @@ PROJECT_DIR="${SCRIPT_DIR}/.." CHANGELOG_PATH="${PROJECT_DIR}/CHANGELOG.md" README_PATH="${PROJECT_DIR}/README.md" POM_XML_PATH="${PROJECT_DIR}/pom.xml" +EXAMPLE_POM_XML_PATH="${PROJECT_DIR}/examples/pom.xml" RELEASE_NUM="" NEXT_RELEASE_NUM="" @@ -193,6 +194,17 @@ verify_version(){ } +verify_example_pom(){ + EXAMPLE_DEPENDENCY_VERSION=$(xmllint --xpath "//*[local-name()='dependencies']/*[local-name()='dependency']/*[local-name()='version']/text()" ${EXAMPLE_POM_XML_PATH}) + if [ "${RELEASE_NUM}" != "${EXAMPLE_DEPENDENCY_VERSION}" ] + then + printf "Example dependency version %s does not match the release number %s\n" "${EXAMPLE_DEPENDENCY_VERSION}" "${RELEASE_NUM}" + printf "Please update the project dependency version in %s" "${EXAMPLE_POM_XML_PATH}" + printf "%s\n" "${FAILURE_BOILERPLATE}" + exit 1 + fi +} + verify_readme(){ printf "Verifying README %s\n" "${README_PATH}" README_NODE_RAW="$(sed -n "/.*<\/version>/p" "${README_PATH}")" @@ -229,6 +241,7 @@ verify_rc_or_beta set_release_number verify_changelog +verify_example_pom verify_readme verify_version From 1c8ae70d8f9a9f1fc7159c98937efcd0edffceee Mon Sep 17 00:00:00 2001 From: karel rehor Date: Mon, 7 Sep 2026 17:30:37 +0200 Subject: [PATCH 038/105] chore: temporarily change examples dependency version to verify workflow. --- examples/pom.xml | 2 +- scripts/on-release.sh | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/examples/pom.xml b/examples/pom.xml index 34e105f0..27b88d93 100644 --- a/examples/pom.xml +++ b/examples/pom.xml @@ -39,7 +39,7 @@ com.influxdb influxdb3-java - 1.12.0-SNAPSHOT + 1.12.0 diff --git a/scripts/on-release.sh b/scripts/on-release.sh index 4d80103f..815bc065 100755 --- a/scripts/on-release.sh +++ b/scripts/on-release.sh @@ -199,7 +199,7 @@ verify_example_pom(){ if [ "${RELEASE_NUM}" != "${EXAMPLE_DEPENDENCY_VERSION}" ] then printf "Example dependency version %s does not match the release number %s\n" "${EXAMPLE_DEPENDENCY_VERSION}" "${RELEASE_NUM}" - printf "Please update the project dependency version in %s" "${EXAMPLE_POM_XML_PATH}" + printf "Please update the project dependency version in %s\n" "${EXAMPLE_POM_XML_PATH}" printf "%s\n" "${FAILURE_BOILERPLATE}" exit 1 fi From d7f69a0a8fda91ddec5655201e8c1e6d3e153378 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Mon, 7 Sep 2026 17:36:57 +0200 Subject: [PATCH 039/105] chore: fix typo --- .github/workflows/maven-release.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index 47d7c71f..6a344484 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -131,7 +131,7 @@ jobs: if [[ "${IS_PRERELEASE}" == "true" ]]; then echo "This is a prerelease so the next release cycle will not be prepared." # exit 0 - echor "Continue for now for debugging and review" + echo "Continue for now for debugging and review" fi echo "Preparing next release cycle" From 796fccd9c97ee0ebeb0a6fe428cf33e7fc25795d Mon Sep 17 00:00:00 2001 From: karel rehor Date: Tue, 8 Sep 2026 09:44:38 +0200 Subject: [PATCH 040/105] chore: tidy maven-release.yml --- .github/workflows/maven-release.yml | 26 +++----------------------- 1 file changed, 3 insertions(+), 23 deletions(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index 6a344484..f3c4cf74 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -33,15 +33,11 @@ jobs: run: | sudo apt-get update sudo apt-get install libxml2-utils - - name: Check environment - run: | - # TODO this is a debug step and can be removed before push to production - env - - name: Verify + - name: Verify Env run: | if [[ -n "$SONATYPE_USERNAME" ]] then - echo "DEBUG have SONATYPE_USERNAME" + echo "have SONATYPE_USERNAME" else echo "Release requires SONATYPE_USERNAME, which was not found. exiting" exit 1 @@ -71,12 +67,8 @@ jobs: export GPG_PASSPHRASE="$GPG_PASSPHRASE_PRELIM" fi - echo "DEBUG GPG_PASSPHRASE ${GPG_PASSPHRASE}" - echo "GPG_PASSPHRASE=${GPG_PASSPHRASE}" >> $GITHUB_ENV - echo "ROVER_ACTION=JUMP_THE_FENCE" >> $GITHUB_ENV - # Verify GPG2 environment if ! command -v gpg2 &> /dev/null then @@ -86,20 +78,12 @@ jobs: gpg2 --version export GPG_EXECUTABLE=$(command -v gpg2) - echo "DEBUG GPG_EXECUTABLE ${GPG_EXECUTABLE}" - - echo "DEBUG MAVEN_SETTINGS_EXPERIM ${MAVEN_SETTINGS_EXPERIM}" - echo "DEBUG MAVEN_SETTINGS_FILE ${{ vars.MAVEN_SETTINGS_FILE }}" - - # N.B. this is for debugging only. TODO remove before release - mvn -s ${{ vars.MAVEN_SETTINGS_FILE }} help:effective-settings - # mvn help:effective-settings - name: Script run: | echo "DEBUG IS_PRERELEASE ^^^${IS_PRERELEASE}^^^" echo "DEBUG GITHUB_ACTOR ${GITHUB_ACTOR}" ./scripts/on-release.sh - - name: Model release + - name: Release run: | if [[ "${IS_PRERELEASE}" == "true" ]]; then echo "This is a pre release and will not be deployed to Maven Central." @@ -126,8 +110,6 @@ jobs: mvn scm-publish:publish-scm - name: Prepare next cycle run: | - # DEBUGGING config follows - set -x if [[ "${IS_PRERELEASE}" == "true" ]]; then echo "This is a prerelease so the next release cycle will not be prepared." # exit 0 @@ -148,8 +130,6 @@ jobs: mvn versions:set -DnextSnapshot=true -DnextSnapshotIndexToIncrement=2 sed -i "1s/^/## ${NEXT_RELEASE:1} [unreleased]\n\n/" CHANGELOG.md sed -i -e "s/${RELEASE_TAG_NAME:1}<\/version>/${NEXT_RELEASE:1}-SNAPSHOT<\/version>/" examples/pom.xml - # DEBUG step follows - git diff git add pom.xml CHANGELOG.md git commit -m "ci: setting up release cycle ${NEXT_RELEASE:1}" git push --set-upstream origin ${NEXT_RELEASE_BRANCH} From f70db2a6c6761e5cc7b8976a5f02b1ffaee40fcc Mon Sep 17 00:00:00 2001 From: karel rehor Date: Tue, 8 Sep 2026 10:04:22 +0200 Subject: [PATCH 041/105] chore: add check for remote next release branch. --- .github/workflows/maven-release.yml | 7 +++++++ CHANGELOG.md | 4 ++-- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index f3c4cf74..63e17012 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -125,6 +125,13 @@ jobs: gh --version git config user.email "${GITHUB_ACTOR}@users.noreply.github.com" git config user.name ${GITHUB_ACTOR} + BRANCH_CHECK=$(git ls-remote --heads origin refs/heads/${NEXT_RELEASE_BRANCH}) + if [ -n "${BRANCH_CHECK}" ] + then + echo "${NEXT_RELEASE_BRANCH} already exists in project. Cannot recreate it automatically." + echo "If you wish to use this automatically created branch, please delete the existing branch and start the release again" + exit 1 + fi git checkout -b ${NEXT_RELEASE_BRANCH} mvn versions:set-scm-tag -DnewTag="HEAD" mvn versions:set -DnextSnapshot=true -DnextSnapshotIndexToIncrement=2 diff --git a/CHANGELOG.md b/CHANGELOG.md index 15a5e9f8..2901797f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -8,9 +8,9 @@ - `.github/workflows/maven-release.yml` - ~~some tasks defined in `maven-release.yml` are covered by the maven release plugin workflow. This includes automated tag generation, which may cause conflicts. So, the workflow needs a review and some revisions~~. DONE - Workflow successfully revised. But no longer relying on `mvn release:prepare` to create tags and update `pom.xml`. - So need to ensure that support scripts and workflow put everything into place correctly. IN PROGRESS - - add scm:tag check to on-release.sh - 1eee676. N.B. this was still using HEAD in jar and pom pushed to Maven Central. + - ~~add scm:tag check to on-release.sh - 1eee676. N.B. this was still using HEAD in jar and pom pushed to Maven Central.~~ DONE - ~~Look into using `mvn versions:set` for updating pom.xml after successful release~~ DONE -- Need to implement documentation releasing step. From manual instructions... IN PROGRESS +- ~~Need to implement documentation releasing step. From manual instructions...~~ DONE ``` mvn clean site site:stage -DskipTests mvn scm-publish:publish-scm From bea30596da4639ad638f435f1aab6885784b7da5 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Tue, 8 Sep 2026 10:24:35 +0200 Subject: [PATCH 042/105] docs: updated and proofed RELEASE.md --- RELEASE.md | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) diff --git a/RELEASE.md b/RELEASE.md index 233c56f9..50e3e4f9 100644 --- a/RELEASE.md +++ b/RELEASE.md @@ -7,7 +7,7 @@ This document contains a general description and tips for releasing Influxdb3-ja Releasing involves three general steps. 1. Preparing the release in a new release branch -2. Triggering the automatic release by creating a new tag a release in Github. +2. Triggering the automatic release by creating a new tag and release in Github. 3. Preparing the next release cycle by merging the next release branch created by the automated release script back into `main`. ### Preparing the release. @@ -21,7 +21,8 @@ $ mvn versions:set-scm-tag -DnewTag="v1.12.0" ``` 3. In `README.md` update the `` tag value in the Maven dependency example. 4. In `CHANGELOG.md` verify all commit information for the current cycle is up-to-date, fix any discrepancies, then update the date for this release to the current date. -5. Commit and push these changes to Github. +5. In `examples/pom.xml` update the version of the Influxdb3-java dependency to the version to be released. +6. Commit and push these changes to Github. ### Initiating the release @@ -29,20 +30,20 @@ In Github `influxComunit/influxb3-java`... 1. In the project home page open the _Releases_ section. 2. Click _Draft a new release_ -3. In the _Target_ drop down check the new release branch. -4. In the _Tag_ drop down click `Create new tag`, supply the tag matching the value added in the `set-scm-tag` command above. Note that the tag should be prefixed with the letter _v_. Click _Create_. +3. In the _Target_ dropdown check the new release branch. +4. In the _Tag_ dropdown click `Create new tag`, supply the tag matching the value added in the `set-scm-tag` command above. Note that the tag should be prefixed with the letter _v_. Click _Create_. 5. In the _Release title_ text control set the title to match the `` tag in `pom.xml`. 6. In the _Release notes_ text field copy changes added since the last release from `CHANEGLOG.md`. -7. If this is a pre-release check the _pre-release_ radio button. Note that the release workflow will not publish pre-release builds to Maven Central. +7. If this is a pre-release check the _pre-release_ radio button. Note that for "pre-release" releases the release workflow will not publish builds to Maven Central, will not publish site documentation and will not prepare the next release cycle. This setting can be useful for debugging the workflow. 8. Click `Publish release`. The creation of the new release will trigger the `maven-release.yml` workflow. It will: 1. Verify required secrets and environment variables are set -2. Check that the `pom.xml` version matches the release tag and that versioning references in documentation are up-to-date and valid. +2. Check that the `pom.xml` version matches the release tag and that versioning references in documentation and examples are up-to-date and valid. 3. Check and sign the build. 4. Upload the archives and pom files to Maven Central. -5. TODO - Publish documentation to https://github.com/influxcommunity/influxdb3-java/tree/gh-pages +5. Publish site documentation to https://github.com/influxcommunity/influxdb3-java/tree/gh-pages 6. prepare the `pom.xml` and `CHANGELOG.md` files for the next release cycle and push them to a new branch named `ci/next-cycle-`. ### Preparing the next release cycle @@ -126,9 +127,10 @@ $ gpg2 --export-secret-keys --armor REDACTED_KEY_ID ...REDACTED... -----END PGP PRIVATE KEY BLOCK----- - +``` #### Revoking a compromised GPG2 key + 1. verify that the key is on the local server. ``` From dafc3f30a526ccbc00c3c9c435e80ff4470275ff Mon Sep 17 00:00:00 2001 From: karel rehor Date: Tue, 8 Sep 2026 10:35:19 +0200 Subject: [PATCH 043/105] chore: clarify error message. --- .github/workflows/maven-release.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index 63e17012..a2eab2e4 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -128,7 +128,7 @@ jobs: BRANCH_CHECK=$(git ls-remote --heads origin refs/heads/${NEXT_RELEASE_BRANCH}) if [ -n "${BRANCH_CHECK}" ] then - echo "${NEXT_RELEASE_BRANCH} already exists in project. Cannot recreate it automatically." + echo "branch ${NEXT_RELEASE_BRANCH} already exists in project. Cannot recreate it automatically." echo "If you wish to use this automatically created branch, please delete the existing branch and start the release again" exit 1 fi From 3886aab7ad4485bb1e64dce49b441ad4e30eadc0 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Tue, 8 Sep 2026 11:02:16 +0200 Subject: [PATCH 044/105] docs: add Maven Central step to releasing instructions. --- RELEASE.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/RELEASE.md b/RELEASE.md index 50e3e4f9..3e5ba9bb 100644 --- a/RELEASE.md +++ b/RELEASE.md @@ -46,6 +46,10 @@ The creation of the new release will trigger the `maven-release.yml` workflow. 5. Publish site documentation to https://github.com/influxcommunity/influxdb3-java/tree/gh-pages 6. prepare the `pom.xml` and `CHANGELOG.md` files for the next release cycle and push them to a new branch named `ci/next-cycle-`. +### Publish release in Maven Central. + +On the Maven Central account, review and publish the release to make it available to the public. + ### Preparing the next release cycle A new branch `ci/next-cycle-` with an updated `pom.xml` file will have been created by the Maven Release action. From b799c9a14fcfe6516aa426350503ac6bd1e418c3 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Tue, 8 Sep 2026 12:57:01 +0200 Subject: [PATCH 045/105] chore: remove debug messages from on-release.sh --- RELEASE.md | 2 +- scripts/on-release.sh | 19 ------------------- 2 files changed, 1 insertion(+), 20 deletions(-) diff --git a/RELEASE.md b/RELEASE.md index 3e5ba9bb..60cc35ad 100644 --- a/RELEASE.md +++ b/RELEASE.md @@ -48,7 +48,7 @@ The creation of the new release will trigger the `maven-release.yml` workflow. ### Publish release in Maven Central. -On the Maven Central account, review and publish the release to make it available to the public. +From the Maven Central account, review and publish the release to make it available to the public. ### Preparing the next release cycle diff --git a/scripts/on-release.sh b/scripts/on-release.sh index 815bc065..dd78d351 100755 --- a/scripts/on-release.sh +++ b/scripts/on-release.sh @@ -46,21 +46,6 @@ IS_SNAPSHOT=false FAILURE_BOILERPLATE="Please delete the tag ${CIRCLE_TAG} and the related release, and start again." -# GITHUB_REF_NAME=v0.2.0 - -echo "DEBUG GITHUB_REF_NAME #${GITHUB_REF_NAME}#" - -#if [[ ${IS_PRERELEASE} ]]; then -# "DEBUG detected PRERELEASE" -#else -# "DEBUG PRERELEASE NOT detected" -#fi - -echo "DEBUG IS_PRERELEASE #${IS_PRERELEASE}#" - -echo "DEBUG AUTHOR NAME #${RELEASE_AUTHOR_NAME}#" -echo "DEBUG SONATYPE_USERNAME #${SONATYPE_USERNAME}#" - github_check(){ if [ "${GITHUB_EVENT_NAME}" == "workflow_dispatch" ]; then @@ -246,7 +231,3 @@ verify_readme verify_version setup - -echo "====== DEBUG ENV =====" - -env \ No newline at end of file From 27e95689a282e6e29f820ae9a9072a8465545fb5 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Tue, 8 Sep 2026 13:32:17 +0200 Subject: [PATCH 046/105] chore: remove debug messages from maven-release.yml --- .github/workflows/maven-release.yml | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index a2eab2e4..a8143878 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -80,8 +80,6 @@ jobs: export GPG_EXECUTABLE=$(command -v gpg2) - name: Script run: | - echo "DEBUG IS_PRERELEASE ^^^${IS_PRERELEASE}^^^" - echo "DEBUG GITHUB_ACTOR ${GITHUB_ACTOR}" ./scripts/on-release.sh - name: Release run: | @@ -95,11 +93,10 @@ jobs: EOF cat release.properties ls -al - # TODO fix -Darguments - we don't want to skip everything in production mvn release:perform \ -Dgoals=deploy \ -s ./deploy-settings.xml \ - -Darguments="-DskipTests -DskipITs -Dlicense.skip -DperformRelease=true" + -Darguments="-DskipTests -DskipITs -DperformRelease=true" - name: Publish documentation run: | if [[ "${IS_PRERELEASE}" == "true" ]]; then From 02183e14b58cc92578bd0502ce9871f613435222 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Tue, 8 Sep 2026 14:44:53 +0200 Subject: [PATCH 047/105] chore: troubleshoot document releasing step --- .github/workflows/maven-release.yml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index a8143878..068fbe9c 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -101,8 +101,11 @@ jobs: run: | if [[ "${IS_PRERELEASE}" == "true" ]]; then echo "This is a pre release, so site documentation will not be updated to Github pages." - exit 0 + # exit 0 + echo "DEBUG need to troubleshoot why this stopped working. So continue for now." fi + git config user.email "${GITHUB_ACTOR}@users.noreply.github.com" + git config user.name ${GITHUB_ACTOR} mvn clean site site:stage -DskipTests mvn scm-publish:publish-scm - name: Prepare next cycle From 42877b5158d900c905cf5c63e1f61660ffab2987 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Tue, 8 Sep 2026 15:11:27 +0200 Subject: [PATCH 048/105] chore: troubleshoot site publishing issue 02 --- pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pom.xml b/pom.xml index f7b12705..0c6b3deb 100644 --- a/pom.xml +++ b/pom.xml @@ -639,7 +639,7 @@ 3.3.0 target/staging - scm:git:git@github.com:karel-rehor/influxdb3-java.git + scm:git:https://github.com/karel-rehor/influxdb3-java.git ${project.basedir}/../influxdb3-scmpublish-checkout gh-pages UTF-8 From c90cbaeba41cff44a227eae7580baaef586ae2b2 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Tue, 8 Sep 2026 15:29:11 +0200 Subject: [PATCH 049/105] chore: troubleshoot site publishing - set to global. --- .github/workflows/maven-release.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index 068fbe9c..a6c4f53a 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -104,8 +104,8 @@ jobs: # exit 0 echo "DEBUG need to troubleshoot why this stopped working. So continue for now." fi - git config user.email "${GITHUB_ACTOR}@users.noreply.github.com" - git config user.name ${GITHUB_ACTOR} + git config --global user.email "${GITHUB_ACTOR}@users.noreply.github.com" + git config --global user.name ${GITHUB_ACTOR} mvn clean site site:stage -DskipTests mvn scm-publish:publish-scm - name: Prepare next cycle From 12464a8d6779eac1c42a35b9ba0a6551f023bd1d Mon Sep 17 00:00:00 2001 From: karel rehor Date: Tue, 8 Sep 2026 15:46:51 +0200 Subject: [PATCH 050/105] chore: revert pubScmUrl - troubleshoot site publishing step. --- pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pom.xml b/pom.xml index 0c6b3deb..f7b12705 100644 --- a/pom.xml +++ b/pom.xml @@ -639,7 +639,7 @@ 3.3.0 target/staging - scm:git:https://github.com/karel-rehor/influxdb3-java.git + scm:git:git@github.com:karel-rehor/influxdb3-java.git ${project.basedir}/../influxdb3-scmpublish-checkout gh-pages UTF-8 From aa5aaacb82ba081648eb5c26fca8d9db71963025 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Tue, 8 Sep 2026 16:15:11 +0200 Subject: [PATCH 051/105] chore: troubleshoot sit publishing 03 --- .github/workflows/maven-release.yml | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index a6c4f53a..b0af2d52 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -104,10 +104,16 @@ jobs: # exit 0 echo "DEBUG need to troubleshoot why this stopped working. So continue for now." fi - git config --global user.email "${GITHUB_ACTOR}@users.noreply.github.com" - git config --global user.name ${GITHUB_ACTOR} + # git config --global user.email "${GITHUB_ACTOR}@users.noreply.github.com" + # git config --global user.name ${GITHUB_ACTOR} + git config --global user.name "github-actions[bot]" + git config --global user.email "41898282+github-actions[bot]@users.noreply.github.com" mvn clean site site:stage -DskipTests - mvn scm-publish:publish-scm + mvn --batch-mode scm-publish:publish-scm \ + -DpubScmUrl=scm:git:https://x-access-token:${GITHUB_TOKEN}@github.com/${GITHUB_REPOSITORY}.git \ + -DscmBranch=gh-pages + # mvn clean site site:stage -DskipTests + # mvn scm-publish:publish-scm - name: Prepare next cycle run: | if [[ "${IS_PRERELEASE}" == "true" ]]; then From d21ffceba70446cf68814248fd95fc85cf1805bd Mon Sep 17 00:00:00 2001 From: karel rehor Date: Tue, 8 Sep 2026 16:28:45 +0200 Subject: [PATCH 052/105] chore: modify pubScmUrl to troubleshoot site publishing --- pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pom.xml b/pom.xml index f7b12705..0c6b3deb 100644 --- a/pom.xml +++ b/pom.xml @@ -639,7 +639,7 @@ 3.3.0 target/staging - scm:git:git@github.com:karel-rehor/influxdb3-java.git + scm:git:https://github.com/karel-rehor/influxdb3-java.git ${project.basedir}/../influxdb3-scmpublish-checkout gh-pages UTF-8 From bf81205c04e9602094cd316ce02de9112bd7dc63 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Tue, 8 Sep 2026 16:42:56 +0200 Subject: [PATCH 053/105] chore: troubleshoot site publishing 05 --- .github/workflows/maven-release.yml | 5 +++-- pom.xml | 4 ++-- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index b0af2d52..f2ad63fd 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -108,9 +108,10 @@ jobs: # git config --global user.name ${GITHUB_ACTOR} git config --global user.name "github-actions[bot]" git config --global user.email "41898282+github-actions[bot]@users.noreply.github.com" - mvn clean site site:stage -DskipTests - mvn --batch-mode scm-publish:publish-scm \ + # mvn clean site site:stage -DskipTests + mvn --batch-mode clean site site:stage -DskipTests scm-publish:publish-scm \ -DpubScmUrl=scm:git:https://x-access-token:${GITHUB_TOKEN}@github.com/${GITHUB_REPOSITORY}.git \ + -DcheckoutDirectory=../influxdb3-scmpublish-checkout -DscmBranch=gh-pages # mvn clean site site:stage -DskipTests # mvn scm-publish:publish-scm diff --git a/pom.xml b/pom.xml index 0c6b3deb..c34bda3c 100644 --- a/pom.xml +++ b/pom.xml @@ -639,8 +639,8 @@ 3.3.0 target/staging - scm:git:https://github.com/karel-rehor/influxdb3-java.git - ${project.basedir}/../influxdb3-scmpublish-checkout + gh-pages UTF-8 From d7db961fa1b4e661e74063795af3cc0268354b89 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Tue, 8 Sep 2026 17:05:21 +0200 Subject: [PATCH 054/105] chore: revert troubleshoot changes --- .github/workflows/maven-release.yml | 18 +++++++----------- pom.xml | 4 ++-- 2 files changed, 9 insertions(+), 13 deletions(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index f2ad63fd..7d7aa54f 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -99,22 +99,18 @@ jobs: -Darguments="-DskipTests -DskipITs -DperformRelease=true" - name: Publish documentation run: | + echo "==== DEBUG env" + env + echo "===" if [[ "${IS_PRERELEASE}" == "true" ]]; then echo "This is a pre release, so site documentation will not be updated to Github pages." # exit 0 echo "DEBUG need to troubleshoot why this stopped working. So continue for now." fi - # git config --global user.email "${GITHUB_ACTOR}@users.noreply.github.com" - # git config --global user.name ${GITHUB_ACTOR} - git config --global user.name "github-actions[bot]" - git config --global user.email "41898282+github-actions[bot]@users.noreply.github.com" - # mvn clean site site:stage -DskipTests - mvn --batch-mode clean site site:stage -DskipTests scm-publish:publish-scm \ - -DpubScmUrl=scm:git:https://x-access-token:${GITHUB_TOKEN}@github.com/${GITHUB_REPOSITORY}.git \ - -DcheckoutDirectory=../influxdb3-scmpublish-checkout - -DscmBranch=gh-pages - # mvn clean site site:stage -DskipTests - # mvn scm-publish:publish-scm + git config --global user.email "${GITHUB_ACTOR}@users.noreply.github.com" + git config --global user.name ${GITHUB_ACTOR} + mvn clean site site:stage -DskipTests + mvn scm-publish:publish-scm - name: Prepare next cycle run: | if [[ "${IS_PRERELEASE}" == "true" ]]; then diff --git a/pom.xml b/pom.xml index c34bda3c..f7b12705 100644 --- a/pom.xml +++ b/pom.xml @@ -639,8 +639,8 @@ 3.3.0 target/staging - + scm:git:git@github.com:karel-rehor/influxdb3-java.git + ${project.basedir}/../influxdb3-scmpublish-checkout gh-pages UTF-8 From 34ec4c8c003b14d944482053fc289dbe51be2c6b Mon Sep 17 00:00:00 2001 From: karel rehor Date: Tue, 8 Sep 2026 17:20:05 +0200 Subject: [PATCH 055/105] chore: troubleshoot site publishing 06 --- pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pom.xml b/pom.xml index f7b12705..dba5e73a 100644 --- a/pom.xml +++ b/pom.xml @@ -640,7 +640,7 @@ target/staging scm:git:git@github.com:karel-rehor/influxdb3-java.git - ${project.basedir}/../influxdb3-scmpublish-checkout + ${project.basedir}/target/scm-publish/influxdb3-scmpublish-checkout gh-pages UTF-8 From 49d866607d633d5c6d0364cb30596df3018c3a18 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Wed, 9 Sep 2026 09:53:36 +0200 Subject: [PATCH 056/105] chore: troubleshoot publish site documents. --- .github/workflows/maven-release.yml | 6 ++++-- pom.xml | 6 +++--- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index 7d7aa54f..9f854b91 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -98,6 +98,8 @@ jobs: -s ./deploy-settings.xml \ -Darguments="-DskipTests -DskipITs -DperformRelease=true" - name: Publish documentation + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} run: | echo "==== DEBUG env" env @@ -109,8 +111,8 @@ jobs: fi git config --global user.email "${GITHUB_ACTOR}@users.noreply.github.com" git config --global user.name ${GITHUB_ACTOR} - mvn clean site site:stage -DskipTests - mvn scm-publish:publish-scm + # mvn clean site site:stage -DskipTests + mvn --batch mode scm-publish:publish-scm - name: Prepare next cycle run: | if [[ "${IS_PRERELEASE}" == "true" ]]; then diff --git a/pom.xml b/pom.xml index dba5e73a..3027047a 100644 --- a/pom.xml +++ b/pom.xml @@ -638,11 +638,11 @@ maven-scm-publish-plugin 3.3.0 - target/staging + gh-pages - UTF-8 + From bd772c6c12fd7eafe91967e8c7dea884f1d0ddda Mon Sep 17 00:00:00 2001 From: karel rehor Date: Wed, 9 Sep 2026 10:00:40 +0200 Subject: [PATCH 057/105] chore: fix typo --- .github/workflows/maven-release.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index 9f854b91..24830d8f 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -112,7 +112,7 @@ jobs: git config --global user.email "${GITHUB_ACTOR}@users.noreply.github.com" git config --global user.name ${GITHUB_ACTOR} # mvn clean site site:stage -DskipTests - mvn --batch mode scm-publish:publish-scm + mvn --batch-mode scm-publish:publish-scm - name: Prepare next cycle run: | if [[ "${IS_PRERELEASE}" == "true" ]]; then From 13bc63e40214829c8cc057854f294fdb929a390f Mon Sep 17 00:00:00 2001 From: karel rehor Date: Wed, 9 Sep 2026 10:19:04 +0200 Subject: [PATCH 058/105] chore: troubleshoot site document releasing 07 --- .github/workflows/maven-release.yml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index 24830d8f..79086c78 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -109,8 +109,9 @@ jobs: # exit 0 echo "DEBUG need to troubleshoot why this stopped working. So continue for now." fi - git config --global user.email "${GITHUB_ACTOR}@users.noreply.github.com" - git config --global user.name ${GITHUB_ACTOR} + git config --global user.email "test@example.com" + git config --global user.name "Github Action" + echo "M2_HOME=$(dirname $(dirname `which mvn`))" >> $GITHUB_ENV # mvn clean site site:stage -DskipTests mvn --batch-mode scm-publish:publish-scm - name: Prepare next cycle From ee077b13251a0c87e8b3704a24c83b261ad09ec5 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Wed, 9 Sep 2026 10:35:04 +0200 Subject: [PATCH 059/105] chore: troubleshoot site documentation 08 --- .github/workflows/maven-release.yml | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index 79086c78..7a2b0a54 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -101,9 +101,8 @@ jobs: env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} run: | - echo "==== DEBUG env" - env - echo "===" + # DEBUG following is a debug step + ls -al if [[ "${IS_PRERELEASE}" == "true" ]]; then echo "This is a pre release, so site documentation will not be updated to Github pages." # exit 0 @@ -112,6 +111,9 @@ jobs: git config --global user.email "test@example.com" git config --global user.name "Github Action" echo "M2_HOME=$(dirname $(dirname `which mvn`))" >> $GITHUB_ENV + echo "==== DEBUG env" + env + echo "===" # mvn clean site site:stage -DskipTests mvn --batch-mode scm-publish:publish-scm - name: Prepare next cycle From 7eac1e3f06999dc3cdf2aaec4888e22d057bb25c Mon Sep 17 00:00:00 2001 From: karel rehor Date: Wed, 9 Sep 2026 10:46:28 +0200 Subject: [PATCH 060/105] chore: troubleshoot publish sit documentation 09 --- .github/workflows/maven-release.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index 7a2b0a54..26ce6d02 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -114,6 +114,7 @@ jobs: echo "==== DEBUG env" env echo "===" + git config --list # mvn clean site site:stage -DskipTests mvn --batch-mode scm-publish:publish-scm - name: Prepare next cycle From 0ceeca95ed39927e071233252f4a43e95ed96392 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Wed, 9 Sep 2026 10:55:07 +0200 Subject: [PATCH 061/105] chore: troubleshoot publish sit documentation 10 --- .github/workflows/maven-release.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index 26ce6d02..c6e00dd4 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -114,7 +114,10 @@ jobs: echo "==== DEBUG env" env echo "===" + echo "DEBUG check git config" git config --list + echo "DEBUG check /home/runner m2 settings" + cat /home/runner/.m2/settings.xml # mvn clean site site:stage -DskipTests mvn --batch-mode scm-publish:publish-scm - name: Prepare next cycle From 0d9c017ee2abc03cf9822bc55cba53316687ae06 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Wed, 9 Sep 2026 12:55:11 +0200 Subject: [PATCH 062/105] chore: troubleshoot publish sit documentation 11 --- .github/workflows/maven-release.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index c6e00dd4..719affc6 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -119,7 +119,7 @@ jobs: echo "DEBUG check /home/runner m2 settings" cat /home/runner/.m2/settings.xml # mvn clean site site:stage -DskipTests - mvn --batch-mode scm-publish:publish-scm + mvn --batch-mode scm-publish:publish-scm -X - name: Prepare next cycle run: | if [[ "${IS_PRERELEASE}" == "true" ]]; then From 823c132d3575180afad1ebf04c739529cb6a214a Mon Sep 17 00:00:00 2001 From: karel rehor Date: Wed, 9 Sep 2026 13:23:08 +0200 Subject: [PATCH 063/105] chore: troubleshoot publish sit documentation 12 --- .github/workflows/maven-release.yml | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index 719affc6..439cc39d 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -108,6 +108,15 @@ jobs: # exit 0 echo "DEBUG need to troubleshoot why this stopped working. So continue for now." fi + cat << EOF > scm-settings.xml + + github + x-access-token + ${env.GITHUB_TOKEN} + + EOF + echo "==== DEBUG scm-settings.xml" + cat scm-settings.xml git config --global user.email "test@example.com" git config --global user.name "Github Action" echo "M2_HOME=$(dirname $(dirname `which mvn`))" >> $GITHUB_ENV @@ -119,7 +128,7 @@ jobs: echo "DEBUG check /home/runner m2 settings" cat /home/runner/.m2/settings.xml # mvn clean site site:stage -DskipTests - mvn --batch-mode scm-publish:publish-scm -X + mvn -s scm-settings.xml --batch-mode scm-publish:publish-scm -X - name: Prepare next cycle run: | if [[ "${IS_PRERELEASE}" == "true" ]]; then From d3c750e8870d96a6d6c647dc13ee33883cd44e86 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Wed, 9 Sep 2026 13:30:18 +0200 Subject: [PATCH 064/105] chore: troubleshoot publish sit documentation 13 --- .github/workflows/maven-release.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index 439cc39d..96416b7a 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -112,7 +112,7 @@ jobs: github x-access-token - ${env.GITHUB_TOKEN} + ${GITHUB_TOKEN} EOF echo "==== DEBUG scm-settings.xml" From 396decb217ac9170ff77716c5bcdf2608dec981e Mon Sep 17 00:00:00 2001 From: karel rehor Date: Wed, 9 Sep 2026 13:42:39 +0200 Subject: [PATCH 065/105] chore: troubleshoot publish sit documentation 14 --- .github/workflows/maven-release.yml | 2 +- pom.xml | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index 96416b7a..a2a0d753 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -128,7 +128,7 @@ jobs: echo "DEBUG check /home/runner m2 settings" cat /home/runner/.m2/settings.xml # mvn clean site site:stage -DskipTests - mvn -s scm-settings.xml --batch-mode scm-publish:publish-scm -X + mvn -s scm-settings.xml --batch-mode scm-publish:publish-scm -Dscm-publish.serverId=github -X - name: Prepare next cycle run: | if [[ "${IS_PRERELEASE}" == "true" ]]; then diff --git a/pom.xml b/pom.xml index 3027047a..a471e663 100644 --- a/pom.xml +++ b/pom.xml @@ -65,7 +65,7 @@ scm:git:https://github.com/karel-rehor/influxdb3-java.git - scm:git:git@github.com:karel-rehor/influxdb3-java.git + scm:git:https://github.com/karel-rehor/influxdb3-java.git https://github.com/karel-rehor/influxdb3-java/tree/main v1.12.0 @@ -639,8 +639,8 @@ 3.3.0 + scm:git:git@github.com:karel-rehor/influxdb3-java.git + ${project.build.directory}/scm-publish gh-pages From 702a61044302712dd55210362fca147aedb4a3e1 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Wed, 9 Sep 2026 13:55:13 +0200 Subject: [PATCH 066/105] chore: troubleshoot publish sit documentation 15 --- pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pom.xml b/pom.xml index a471e663..4d94af14 100644 --- a/pom.xml +++ b/pom.xml @@ -81,7 +81,7 @@ GitHubPages - https://github.com/karel-rehor/influxdb3-java + scm:git:https://github.com/karel-rehor/influxdb3-java From 727eb19b0b24fe95fe0feec9cd8de06873a64a3e Mon Sep 17 00:00:00 2001 From: karel rehor Date: Wed, 9 Sep 2026 14:05:22 +0200 Subject: [PATCH 067/105] chore: troubleshoot publish sit documentation 16 --- .github/workflows/maven-release.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index a2a0d753..cac1d00c 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -127,7 +127,7 @@ jobs: git config --list echo "DEBUG check /home/runner m2 settings" cat /home/runner/.m2/settings.xml - # mvn clean site site:stage -DskipTests + mvn clean site site:stage -DskipTests mvn -s scm-settings.xml --batch-mode scm-publish:publish-scm -Dscm-publish.serverId=github -X - name: Prepare next cycle run: | From 28cecc210c35e2e0eef8765e5270a529d6347db6 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Wed, 9 Sep 2026 14:21:19 +0200 Subject: [PATCH 068/105] chore: troubleshoot publish sit documentation 17 --- .github/workflows/maven-release.yml | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index cac1d00c..26a181b0 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -109,11 +109,15 @@ jobs: echo "DEBUG need to troubleshoot why this stopped working. So continue for now." fi cat << EOF > scm-settings.xml - - github - x-access-token - ${GITHUB_TOKEN} - + + + + github + x-access-token + ${GITHUB_TOKEN} + + + EOF echo "==== DEBUG scm-settings.xml" cat scm-settings.xml From 260418aeb2a071289133c03da3bc6aab6a1aafd2 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Wed, 9 Sep 2026 14:44:56 +0200 Subject: [PATCH 069/105] chore: troubleshoot publish sit documentation 18 --- .github/workflows/maven-release.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index 26a181b0..ec3a5929 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -132,7 +132,7 @@ jobs: echo "DEBUG check /home/runner m2 settings" cat /home/runner/.m2/settings.xml mvn clean site site:stage -DskipTests - mvn -s scm-settings.xml --batch-mode scm-publish:publish-scm -Dscm-publish.serverId=github -X + mvn -s scm-settings.xml --batch-mode scm-publish:publish-scm -Dscmpublish.serverId=github -X - name: Prepare next cycle run: | if [[ "${IS_PRERELEASE}" == "true" ]]; then From 992844f0aa44c419be61128294f171c906cf050e Mon Sep 17 00:00:00 2001 From: karel rehor Date: Wed, 9 Sep 2026 16:18:46 +0200 Subject: [PATCH 070/105] chore: remove debug commands from Publish documentation step. --- .github/workflows/maven-release.yml | 14 +------------- 1 file changed, 1 insertion(+), 13 deletions(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index ec3a5929..93136a34 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -101,8 +101,6 @@ jobs: env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} run: | - # DEBUG following is a debug step - ls -al if [[ "${IS_PRERELEASE}" == "true" ]]; then echo "This is a pre release, so site documentation will not be updated to Github pages." # exit 0 @@ -119,20 +117,10 @@ jobs: EOF - echo "==== DEBUG scm-settings.xml" - cat scm-settings.xml git config --global user.email "test@example.com" git config --global user.name "Github Action" - echo "M2_HOME=$(dirname $(dirname `which mvn`))" >> $GITHUB_ENV - echo "==== DEBUG env" - env - echo "===" - echo "DEBUG check git config" - git config --list - echo "DEBUG check /home/runner m2 settings" - cat /home/runner/.m2/settings.xml mvn clean site site:stage -DskipTests - mvn -s scm-settings.xml --batch-mode scm-publish:publish-scm -Dscmpublish.serverId=github -X + mvn -s scm-settings.xml --batch-mode scm-publish:publish-scm -Dscmpublish.serverId=github - name: Prepare next cycle run: | if [[ "${IS_PRERELEASE}" == "true" ]]; then From e54276815c97d5b0915c5efa94833df9862ae030 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Thu, 10 Sep 2026 09:17:44 +0200 Subject: [PATCH 071/105] chore: experim - try automatic PR creation. --- .github/workflows/maven-release.yml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index 93136a34..19aa53ba 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -153,4 +153,7 @@ jobs: git add pom.xml CHANGELOG.md git commit -m "ci: setting up release cycle ${NEXT_RELEASE:1}" git push --set-upstream origin ${NEXT_RELEASE_BRANCH} - echo "The branch ${NEXT_RELEASE_BRANCH} has been created. You can create and merge a PR manually from it to start the next release cycle." + gh pr create -B main -H ${NEXT_RELEASE_BRANCH} --title "Merge ${NEXT_RELEASE_BRANCH} into main" --body 'Created by Github action' + # echo "The branch ${NEXT_RELEASE_BRANCH} has been created. You can create and merge a PR manually from it to start the next release cycle." + env: + GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} From 73dac4a1f3307691693773cdb299149546ff74f2 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Thu, 10 Sep 2026 09:37:31 +0200 Subject: [PATCH 072/105] chore: experim - try to create new PR 02 --- .github/workflows/maven-release.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index 19aa53ba..67fa5232 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -9,6 +9,8 @@ jobs: release: permissions: contents: write # may want to update version + pull-requests: write + repository-projects: write runs-on: ubuntu-latest env: SONATYPE_USERNAME: ${{ secrets.SONATYPE_USERNAME }} From 4c0739a7ab2690a9b3142349d1077557e3471126 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Thu, 10 Sep 2026 10:07:25 +0200 Subject: [PATCH 073/105] chore: switch off automatic PR creation, requires special permissions. --- .github/workflows/maven-release.yml | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index 67fa5232..72bcafa1 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -155,7 +155,9 @@ jobs: git add pom.xml CHANGELOG.md git commit -m "ci: setting up release cycle ${NEXT_RELEASE:1}" git push --set-upstream origin ${NEXT_RELEASE_BRANCH} - gh pr create -B main -H ${NEXT_RELEASE_BRANCH} --title "Merge ${NEXT_RELEASE_BRANCH} into main" --body 'Created by Github action' - # echo "The branch ${NEXT_RELEASE_BRANCH} has been created. You can create and merge a PR manually from it to start the next release cycle." + # The following requires special permissions on the organizational and project level to work. Switching off for now. + # gh pr create -B main -H ${NEXT_RELEASE_BRANCH} --title "Merge ${NEXT_RELEASE_BRANCH} into main" --body 'Created by Github action' + # The alternative is to create the PR by hand + echo "The branch ${NEXT_RELEASE_BRANCH} has been created. You can create and merge a PR manually from it to start the next release cycle." env: GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} From e8e7b7586fc235411bd65b6b52f66e0c6298534a Mon Sep 17 00:00:00 2001 From: karel rehor Date: Thu, 10 Sep 2026 10:23:38 +0200 Subject: [PATCH 074/105] chore: reactivate branch controls for prerelease. --- .github/workflows/maven-release.yml | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index 72bcafa1..33dc1a31 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -37,6 +37,10 @@ jobs: sudo apt-get install libxml2-utils - name: Verify Env run: | + # TODO ensure scm properties match current project + echo "=== DEBUG env" + env + echo "===" if [[ -n "$SONATYPE_USERNAME" ]] then echo "have SONATYPE_USERNAME" @@ -105,8 +109,7 @@ jobs: run: | if [[ "${IS_PRERELEASE}" == "true" ]]; then echo "This is a pre release, so site documentation will not be updated to Github pages." - # exit 0 - echo "DEBUG need to troubleshoot why this stopped working. So continue for now." + exit 0 fi cat << EOF > scm-settings.xml @@ -127,8 +130,7 @@ jobs: run: | if [[ "${IS_PRERELEASE}" == "true" ]]; then echo "This is a prerelease so the next release cycle will not be prepared." - # exit 0 - echo "Continue for now for debugging and review" + exit 0 fi echo "Preparing next release cycle" From 52c96b6de836a8a3c5d42cffc041a25efd926cb7 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Thu, 10 Sep 2026 11:03:26 +0200 Subject: [PATCH 075/105] chore: add env checks for matching scm values. --- .github/workflows/maven-release.yml | 30 ++++++++++++++++++++++++++++- 1 file changed, 29 insertions(+), 1 deletion(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index 33dc1a31..7d39fc37 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -37,7 +37,35 @@ jobs: sudo apt-get install libxml2-utils - name: Verify Env run: | - # TODO ensure scm properties match current project + # ensure scm properties match current project - don't want to modify other repository inadvertently + POM_SITE_URL=$(xmllint --xpath "//*[local-name()='distributionManagement']/*[local-name()='site']/*[local-name()='url']/text()" ../pom.xml) + POM_SCM_CONNECTION=$(xmllint --xpath "//*[local-name()='scm']/*[local-name()='connection']/text()" ../pom.xml) + POM_SCM_DEVELOPER_CONNECTION=$(xmllint --xpath "//*[local-name()='scm']/*[local-name()='developerConnection']/text()" ../pom.xml) + + if [[ ! "${POM_SITE_URL}" =~ .*${GITHUB_REPOSITORY}$ ]] + then + echo "POM_SITE_URL ${POM_SITE_URL} does not match GITHUB_REPOSITORY ${GITHUB_REPOSITORY}" + exit 1 + else + echo "POM_SITE_URL OK ✓." + fi + + if [[ ! "${POM_SCM_CONNECTION}" =~ .*${GITHUB_REPOSITORY}\.git$ ]] + then + echo "POM_SCM_CONNECTION ${POM_SCM_CONNECTION} does not match GITHUB_REPOSITORY ${GITHUB_REPOSITORY}" + exit 1 + else + echo "POM_SCM_CONNECTION OK ✓." + fi + + if [[ ! "${POM_SCM_DEVELOPER_CONNECTION}" =~ .*${GITHUB_REPOSITORY}\.git$ ]] + then + echo "POM_SCM_DEVELOPER_CONNECTION ${POM_SCM_DEVELOPER_CONNECTION} does not match GITHUB_REPOSITORY ${GITHUB_REPOSITORY}" + exit 1 + else + echo "POM_SCM_DEVELOPER_CONNECTION OK ✓." + fi + echo "=== DEBUG env" env echo "===" From d54457c20c675bd64fa94d4aea451e26f0999572 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Thu, 10 Sep 2026 12:39:09 +0200 Subject: [PATCH 076/105] chore: fix path in script. --- .github/workflows/maven-release.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index 7d39fc37..e96a2820 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -38,9 +38,9 @@ jobs: - name: Verify Env run: | # ensure scm properties match current project - don't want to modify other repository inadvertently - POM_SITE_URL=$(xmllint --xpath "//*[local-name()='distributionManagement']/*[local-name()='site']/*[local-name()='url']/text()" ../pom.xml) - POM_SCM_CONNECTION=$(xmllint --xpath "//*[local-name()='scm']/*[local-name()='connection']/text()" ../pom.xml) - POM_SCM_DEVELOPER_CONNECTION=$(xmllint --xpath "//*[local-name()='scm']/*[local-name()='developerConnection']/text()" ../pom.xml) + POM_SITE_URL=$(xmllint --xpath "//*[local-name()='distributionManagement']/*[local-name()='site']/*[local-name()='url']/text()" ./pom.xml) + POM_SCM_CONNECTION=$(xmllint --xpath "//*[local-name()='scm']/*[local-name()='connection']/text()" ./pom.xml) + POM_SCM_DEVELOPER_CONNECTION=$(xmllint --xpath "//*[local-name()='scm']/*[local-name()='developerConnection']/text()" ./pom.xml) if [[ ! "${POM_SITE_URL}" =~ .*${GITHUB_REPOSITORY}$ ]] then From 8f110191347e9f777acc35892d08e33e7e2176ce Mon Sep 17 00:00:00 2001 From: karel rehor Date: Thu, 10 Sep 2026 13:09:36 +0200 Subject: [PATCH 077/105] chore: remove debug of script ENV. --- .github/workflows/maven-release.yml | 3 --- 1 file changed, 3 deletions(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index e96a2820..7ae895a0 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -66,9 +66,6 @@ jobs: echo "POM_SCM_DEVELOPER_CONNECTION OK ✓." fi - echo "=== DEBUG env" - env - echo "===" if [[ -n "$SONATYPE_USERNAME" ]] then echo "have SONATYPE_USERNAME" From 90592084f151b61a00b20da0b087098a5bb31eac Mon Sep 17 00:00:00 2001 From: karel rehor Date: Thu, 10 Sep 2026 13:22:22 +0200 Subject: [PATCH 078/105] chore: remove commented nodes from pom.xml --- pom.xml | 3 --- 1 file changed, 3 deletions(-) diff --git a/pom.xml b/pom.xml index 4d94af14..3ba6a249 100644 --- a/pom.xml +++ b/pom.xml @@ -638,11 +638,8 @@ maven-scm-publish-plugin 3.3.0 - ${project.build.directory}/scm-publish gh-pages - From 1d4a4abb4b075eabe4b76a71e8626d6f6f3a86e3 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Thu, 10 Sep 2026 13:43:43 +0200 Subject: [PATCH 079/105] docs: update RELEASE.md to match current workflow. --- RELEASE.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/RELEASE.md b/RELEASE.md index 60cc35ad..d6069202 100644 --- a/RELEASE.md +++ b/RELEASE.md @@ -34,12 +34,12 @@ In Github `influxComunit/influxb3-java`... 4. In the _Tag_ dropdown click `Create new tag`, supply the tag matching the value added in the `set-scm-tag` command above. Note that the tag should be prefixed with the letter _v_. Click _Create_. 5. In the _Release title_ text control set the title to match the `` tag in `pom.xml`. 6. In the _Release notes_ text field copy changes added since the last release from `CHANEGLOG.md`. -7. If this is a pre-release check the _pre-release_ radio button. Note that for "pre-release" releases the release workflow will not publish builds to Maven Central, will not publish site documentation and will not prepare the next release cycle. This setting can be useful for debugging the workflow. +7. If this is a pre-release check the _pre-release_ radio button. Note that for "pre-release" releases the release workflow will not publish modules to Maven Central, will not publish site documentation and will not prepare the next release cycle. This setting can be useful for debugging the workflow. 8. Click `Publish release`. The creation of the new release will trigger the `maven-release.yml` workflow. It will: -1. Verify required secrets and environment variables are set +1. Verify required secrets and environment variables are set, and that SCM values in `pom.xml` match the repository from which the release is being triggered. 2. Check that the `pom.xml` version matches the release tag and that versioning references in documentation and examples are up-to-date and valid. 3. Check and sign the build. 4. Upload the archives and pom files to Maven Central. @@ -48,11 +48,11 @@ The creation of the new release will trigger the `maven-release.yml` workflow. ### Publish release in Maven Central. -From the Maven Central account, review and publish the release to make it available to the public. +From the Maven Central account, review and publish the release to make it available to the public or drop it if the release workflow failed or if there are discrepancies in the files to be published. ### Preparing the next release cycle -A new branch `ci/next-cycle-` with an updated `pom.xml` file will have been created by the Maven Release action. +A new branch `ci/next-cycle-` with an updated `pom.xml` file will have been created when the Maven Release action completes successfully. 1. create a PR from the branch `ci/next-cycle-` to merge it into `main`. 2. review the PR and if everything has been generated correctly, squash and merge it. From cbefea3a88dba8418d0a8395d2a31522232ff5f1 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Thu, 10 Sep 2026 14:02:34 +0200 Subject: [PATCH 080/105] chore: remove unnecessary commands from workflow. --- .github/workflows/maven-release.yml | 2 -- 1 file changed, 2 deletions(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index 7ae895a0..f17c8af8 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -123,7 +123,6 @@ jobs: scm.tag=${RELEASE_TAG_NAME} EOF cat release.properties - ls -al mvn release:perform \ -Dgoals=deploy \ -s ./deploy-settings.xml \ @@ -164,7 +163,6 @@ jobs: NEW_MINOR=$((PARTS[1]+1)) NEXT_RELEASE="${PARTS[0]}.${NEW_MINOR}.${PARTS[2]}" NEXT_RELEASE_BRANCH="ci/next-cycle-${NEXT_RELEASE}" - gh --version git config user.email "${GITHUB_ACTOR}@users.noreply.github.com" git config user.name ${GITHUB_ACTOR} BRANCH_CHECK=$(git ls-remote --heads origin refs/heads/${NEXT_RELEASE_BRANCH}) From ddeddf393482e7e68f2e3f4d2e9fac7bcad8bc60 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Thu, 10 Sep 2026 15:07:59 +0200 Subject: [PATCH 081/105] chore: prepare automated releasing branch for PR to upstream. --- CHANGELOG.md | 22 +--------------------- pom.xml | 10 +++++----- 2 files changed, 6 insertions(+), 26 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 2901797f..ce56bab6 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,24 +1,4 @@ -## 1.12.0 [2026-09-04] - -### karel-rehor fork TODOs - -- `pom.xml` - 1. ~~cleanup to get stable working release with `central-publishing-maven-plugin`~~. DONE - 2. Once the above is proven to work - revert `scm` and other values to `influxCommunity` before creating PR to production. -- `.github/workflows/maven-release.yml` - ~~some tasks defined in `maven-release.yml` are covered by the maven release plugin workflow. This includes automated tag generation, which may cause conflicts. So, the workflow needs a review and some revisions~~. DONE - - Workflow successfully revised. But no longer relying on `mvn release:prepare` to create tags and update `pom.xml`. - - So need to ensure that support scripts and workflow put everything into place correctly. IN PROGRESS - - ~~add scm:tag check to on-release.sh - 1eee676. N.B. this was still using HEAD in jar and pom pushed to Maven Central.~~ DONE -- ~~Look into using `mvn versions:set` for updating pom.xml after successful release~~ DONE -- ~~Need to implement documentation releasing step. From manual instructions...~~ DONE -``` -mvn clean site site:stage -DskipTests -mvn scm-publish:publish-scm -``` -- Document new releasing procedures in `RELEASE.md` and in bonitoo docs. IN PROGRESS (note RELEASE.md document already started in branch ci/gh-action-maven-releasing) -- Full cycle test with above changes - then drop test release. PARTIALLY DONE - Core workflow validated and results dropped. -- Test hot release (1.11.1?) from maven central using fork. Can it be used in a client app? -- Cleanup, including removing this TODO List, and create PR. +## 1.12.0 [unreleased] ## 1.11.0 [2026-08-27] diff --git a/pom.xml b/pom.xml index 3ba6a249..3e6da6db 100644 --- a/pom.xml +++ b/pom.xml @@ -25,7 +25,7 @@ 4.0.0 - io.github.karel-rehor + com.influxdb influxdb3-java jar 1.12.0 @@ -64,9 +64,9 @@ - scm:git:https://github.com/karel-rehor/influxdb3-java.git - scm:git:https://github.com/karel-rehor/influxdb3-java.git - https://github.com/karel-rehor/influxdb3-java/tree/main + scm:git:https://github.com/InfluxCommunity/influxdb3-java.git + scm:git:https://github.com/InfluxCommunity/influxdb3-java.git + https://github.com/InfluxCommunity/influxdb3-java/tree/main v1.12.0 @@ -81,7 +81,7 @@ GitHubPages - scm:git:https://github.com/karel-rehor/influxdb3-java + scm:git:https://github.com/InfluxCommunity/influxdb3-java From 7c817c4cb8610bdd1cbce7e7fc782b6bc92e46f7 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Thu, 10 Sep 2026 16:25:20 +0200 Subject: [PATCH 082/105] chore: remove experimental permissions from release workflow. --- .github/workflows/maven-release.yml | 2 -- 1 file changed, 2 deletions(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index f17c8af8..6b8e15ca 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -9,8 +9,6 @@ jobs: release: permissions: contents: write # may want to update version - pull-requests: write - repository-projects: write runs-on: ubuntu-latest env: SONATYPE_USERNAME: ${{ secrets.SONATYPE_USERNAME }} From 9130d113fefc692e599a2018f5c8446a0c6031be Mon Sep 17 00:00:00 2001 From: karel rehor Date: Thu, 10 Sep 2026 16:36:22 +0200 Subject: [PATCH 083/105] docs: update CHANGELOG.md --- CHANGELOG.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index ce56bab6..f923d669 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,9 @@ ## 1.12.0 [unreleased] +### CI + +1. [#440](https://github.com/InfluxCommunity/influxdb3-java/pull/440): Sets up automated releasing to Maven Central + ## 1.11.0 [2026-08-27] ### Breaking Changes From 3d958a8c48644b283975a925c31548be54a427f4 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Thu, 10 Sep 2026 17:09:26 +0200 Subject: [PATCH 084/105] docs: lint fixes for RELEASE.md --- RELEASE.md | 299 +++++++++++++++++++++++++++-------------------------- 1 file changed, 150 insertions(+), 149 deletions(-) diff --git a/RELEASE.md b/RELEASE.md index d6069202..004e00b9 100644 --- a/RELEASE.md +++ b/RELEASE.md @@ -10,12 +10,12 @@ Releasing involves three general steps. 2. Triggering the automatic release by creating a new tag and release in Github. 3. Preparing the next release cycle by merging the next release branch created by the automated release script back into `main`. -### Preparing the release. +### Preparing the release 1. from `main` create a new release branch, e.g. `git checkout -b chore/release-1.12.0` 2. In the new branch, update the version settings in `pom.xml` -``` +```bash $ mvn versions:set -DremoveSnapshot=true $ mvn versions:set-scm-tag -DnewTag="v1.12.0" ``` @@ -74,168 +74,169 @@ The release workflow is managed by `.github/workflows/maven-release.yml`. In or e.g. On a Linux box... -``` -$ head -c 6 /dev/urandom | base64 | tr -dc 'a-zA-Z0-9+-' -jEtkLlyG -``` + ```bash + $ head -c 6 /dev/urandom | base64 | tr -dc 'a-zA-Z0-9+-' + jEtkLlyG + ``` Store this somewhere safe. -2. Generate a key with a passphrase and no expiration. +1. Generate a key with a passphrase and no expiration. -``` -$ gpg --batch --passphrase= --quick-generate-key "karel-rehor@users.noreply.github.com" default default never -gpg: revocation certificate stored as '/home/karl/.gnupg/openpgp-revocs.d/REDACTED_KEY_ID.rev' -``` + ```bash + $ gpg --batch --passphrase= --quick-generate-key "karel-rehor@users.noreply.github.com" default default never + gpg: revocation certificate stored as '/home/karl/.gnupg/openpgp-revocs.d/REDACTED_KEY_ID.rev' + ``` -3. Verify key. +1. Verify key. -``` -$ gpg --list-keys -gpg: checking the trustdb -gpg: marginals needed: 3 completes needed: 1 trust model: pgp -gpg: depth: 0 valid: 1 signed: 0 trust: 0-, 0q, 0n, 0m, 0f, 1u -/home/karl/.gnupg/pubring.kbx ------------------------------ -pub ed25519 2026-09-03 [SC] - REDACTED_KEY_ID -uid [ultimate] karel-rehor@users.noreply.github.com -sub cv25519 2026-09-03 [E] -``` + ```bash + $ gpg --list-keys + gpg: checking the trustdb + gpg: marginals needed: 3 completes needed: 1 trust model: pgp + gpg: depth: 0 valid: 1 signed: 0 trust: 0-, 0q, 0n, 0m, 0f, 1u + /home/karl/.gnupg/pubring.kbx + ----------------------------- + pub ed25519 2026-09-03 [SC] + REDACTED_KEY_ID + uid [ultimate] karel-rehor@users.noreply.github.com + sub cv25519 2026-09-03 [E] + ``` -4. Distribute the key. +1. Distribute the key. -``` -$ gpg2 --keyserver keyserver.ubuntu.com --send-keys REDACTED_KEY_ID -gpg: sending key REDACETD to hkp://keyserver.ubuntu.com -``` + ```bash + $ gpg2 --keyserver keyserver.ubuntu.com --send-keys REDACTED_KEY_ID + gpg: sending key REDACETD to hkp://keyserver.ubuntu.com + ``` -5. Verify key is on remote. Note, that it may take a few minutes to be registered. +1. Verify key is on remote. Note, that it may take a few minutes to be registered. -``` -$ gpg2 --keyserver keyserver.ubuntu.com --search-keys REDACTED_KEY_ID -gpg: data source: http://185.125.188.27:11371 -(1) karel-rehor@users.noreply.github.com - 263 bit EDDSA key REDACTED, created: 2026-09-03 -Keys 1-1 of 1 for "REDACTED_KEY_ID". Enter number(s), N)ext, or Q)uit > 1 -gpg: key REDACTED: "karel-rehor@users.noreply.github.com" not changed -gpg: Total number processed: 1 -gpg: unchanged: 1 -``` + ```bash + $ gpg2 --keyserver keyserver.ubuntu.com --search-keys REDACTED_KEY_ID + gpg: data source: http://185.125.188.27:11371 + (1) karel-rehor@users.noreply.github.com + 263 bit EDDSA key REDACTED, created: 2026-09-03 + Keys 1-1 of 1 for "REDACTED_KEY_ID". Enter number(s), N)ext, or Q)uit > 1 + gpg: key REDACTED: "karel-rehor@users.noreply.github.com" not changed + gpg: Total number processed: 1 + gpg: unchanged: 1 + ``` -6. Get the secret key associated with this key. It will need to be copied then pasted to the Github project secret GPG_PRIVATE_KEY. Note you will be prompted for the passphrase. +1. Get the secret key associated with this key. It will need to be copied then pasted to the Github project secret GPG_PRIVATE_KEY. Note you will be prompted for the passphrase. -``` -$ gpg2 --export-secret-keys --armor REDACTED_KEY_ID ------BEGIN PGP PRIVATE KEY BLOCK----- + ```bash + $ gpg2 --export-secret-keys --armor REDACTED_KEY_ID + -----BEGIN PGP PRIVATE KEY BLOCK----- - ...REDACTED... + ...REDACTED... + + -----END PGP PRIVATE KEY BLOCK----- + ``` ------END PGP PRIVATE KEY BLOCK----- -``` #### Revoking a compromised GPG2 key 1. verify that the key is on the local server. -``` -$ gpg2 --list-keys -/home/karl/.gnupg/pubring.kbx ------------------------------ -pub ed25519 2026-07-27 [SC] [expires: 2029-07-26] - KEY_ID_REDACTED -uid [ultimate] karel-rehor@users.noreply.github.com -sub REDACTED 2026-07-27 [E] - -``` - -or... - -``` -$ gpg2 --list-keys KEY_ID_REDACTED -pub ed25519 2026-07-27 [SC] [expires: 2029-07-26] - KEY_ID_REDACTED -uid [ultimate] karel-rehor@users.noreply.github.com -sub REDACTED 2026-07-27 [E] -``` - -2. Verify that the key is on the remote server. - -``` -$ gpg2 --keyserver keyserver.ubuntu.com --search-keys KEY_ID_REDACTED -gpg: data source: http://185.125.188.27:11371 -(1) karel-rehor@users.noreply.github.com - 263 bit EDDSA key REDACTED, created: 2026-07-27 -Keys 1-1 of 1 for "KEY_ID_REDACTED". Enter number(s), N)ext, or Q)uit > 1 -gpg: key REDACTED: "karel-rehor@users.noreply.github.com" not changed -gpg: Total number processed: 1 -gpg: unchanged: 1 -``` - -3. Create a revocation request locally. - -``` -$ gpg2 --output revoke-karel-rehor.asc --gen-revoke KEY_ID_REDACTED -... -``` - -4. Revoke the key locally. - -``` -$ gpg2 --import revoke-karel-rehor.asc -gpg: key REDACTED: "karel-rehor@users.noreply.github.com" revocation certificate imported -gpg: Total number processed: 1 -gpg: new key revocations: 1 -gpg: marginals needed: 3 completes needed: 1 trust model: pgp -gpg: depth: 0 valid: 1 signed: 0 trust: 0-, 0q, 0n, 0m, 0f, 1u -gpg: next trustdb check due at 2029-07-26 -``` - -5. Verify revocation succeeded. - -``` -$ gpg2 --list-keys -/home/karl/.gnupg/pubring.kbx ------------------------------ -pub ed25519 2026-07-27 [SC] [revoked: 2026-09-03] - KEY_ID_REDACTED -uid [ revoked] karel-rehor@users.noreply.github.com -``` - -6. Push change of key state to remote server. - -``` -$ gpg2 --keyserver keyserver.ubuntu.com --send-keys KEY_ID_REDACTED -gpg: sending key REDACTED to hkp://keyserver.ubuntu.com -``` - -7. Verify key state on remote server. - -``` -$ gpg2 --keyserver keyserver.ubuntu.com --search-keys KEY_ID_REDACTED -gpg: data source: http://185.125.188.27:11371 -gpg: key "KEY_ID_REDACTED" not found on keyserver -``` - -8. Delete secret key locally. - -``` -$ gpg2 --delete-secret-key KEY_ID_REDACTED -... -# Confirmation required -``` - -9. Delete key locally - -``` -$ gpg2 --delete-key 01EAECEC736391172C6520F48B5778484117B952 -... -# Confirmation required -``` - -10. Verify key is deleted - -``` -$ gpg2 --list-keys -gpg: checking the trustdb -gpg: no ultimately trusted keys found -``` + ```bash + $ gpg2 --list-keys + /home/karl/.gnupg/pubring.kbx + ----------------------------- + pub ed25519 2026-07-27 [SC] [expires: 2029-07-26] + KEY_ID_REDACTED + uid [ultimate] karel-rehor@users.noreply.github.com + sub REDACTED 2026-07-27 [E] + + ``` + + or... + + ```bash + $ gpg2 --list-keys KEY_ID_REDACTED + pub ed25519 2026-07-27 [SC] [expires: 2029-07-26] + KEY_ID_REDACTED + uid [ultimate] karel-rehor@users.noreply.github.com + sub REDACTED 2026-07-27 [E] + ``` + +1. Verify that the key is on the remote server. + + ```bash + $ gpg2 --keyserver keyserver.ubuntu.com --search-keys KEY_ID_REDACTED + gpg: data source: http://185.125.188.27:11371 + (1) karel-rehor@users.noreply.github.com + 263 bit EDDSA key REDACTED, created: 2026-07-27 + Keys 1-1 of 1 for "KEY_ID_REDACTED". Enter number(s), N)ext, or Q)uit > 1 + gpg: key REDACTED: "karel-rehor@users.noreply.github.com" not changed + gpg: Total number processed: 1 + gpg: unchanged: 1 + ``` + +1. Create a revocation request locally. + + ```bash + $ gpg2 --output revoke-karel-rehor.asc --gen-revoke KEY_ID_REDACTED + ... + ``` + +1. Revoke the key locally. + + ```bash + $ gpg2 --import revoke-karel-rehor.asc + gpg: key REDACTED: "karel-rehor@users.noreply.github.com" revocation certificate imported + gpg: Total number processed: 1 + gpg: new key revocations: 1 + gpg: marginals needed: 3 completes needed: 1 trust model: pgp + gpg: depth: 0 valid: 1 signed: 0 trust: 0-, 0q, 0n, 0m, 0f, 1u + gpg: next trustdb check due at 2029-07-26 + ``` + +1. Verify revocation succeeded. + + ```bash + $ gpg2 --list-keys + /home/karl/.gnupg/pubring.kbx + ----------------------------- + pub ed25519 2026-07-27 [SC] [revoked: 2026-09-03] + KEY_ID_REDACTED + uid [ revoked] karel-rehor@users.noreply.github.com + ``` + +1. Push change of key state to remote server. + + ```bash + $ gpg2 --keyserver keyserver.ubuntu.com --send-keys KEY_ID_REDACTED + gpg: sending key REDACTED to hkp://keyserver.ubuntu.com + ``` + +1. Verify key state on remote server. + + ```bash + $ gpg2 --keyserver keyserver.ubuntu.com --search-keys KEY_ID_REDACTED + gpg: data source: http://185.125.188.27:11371 + gpg: key "KEY_ID_REDACTED" not found on keyserver + ``` + +1. Delete secret key locally. + + ```bash + $ gpg2 --delete-secret-key KEY_ID_REDACTED + ... + # Confirmation required + ``` + +1. Delete key locally + + ```bash + $ gpg2 --delete-key 01EAECEC736391172C6520F48B5778484117B952 + ... + # Confirmation required + ``` + +1. Verify key is deleted + + ```bash + $ gpg2 --list-keys + gpg: checking the trustdb + gpg: no ultimately trusted keys found + ``` From 8afc194eaaed8e2514f69efb1c2de51bd8b6696d Mon Sep 17 00:00:00 2001 From: karel rehor Date: Mon, 14 Sep 2026 10:24:07 +0200 Subject: [PATCH 085/105] docs: fix linting issues in RELEASE.md --- RELEASE.md | 50 +++++++++++++++++++++++++------------------------- 1 file changed, 25 insertions(+), 25 deletions(-) diff --git a/RELEASE.md b/RELEASE.md index 004e00b9..06fc84fc 100644 --- a/RELEASE.md +++ b/RELEASE.md @@ -13,40 +13,41 @@ Releasing involves three general steps. ### Preparing the release 1. from `main` create a new release branch, e.g. `git checkout -b chore/release-1.12.0` -2. In the new branch, update the version settings in `pom.xml` +1. In the new branch, update the version settings in `pom.xml` -```bash -$ mvn versions:set -DremoveSnapshot=true -$ mvn versions:set-scm-tag -DnewTag="v1.12.0" -``` -3. In `README.md` update the `` tag value in the Maven dependency example. -4. In `CHANGELOG.md` verify all commit information for the current cycle is up-to-date, fix any discrepancies, then update the date for this release to the current date. -5. In `examples/pom.xml` update the version of the Influxdb3-java dependency to the version to be released. -6. Commit and push these changes to Github. + ```bash + $ mvn versions:set -DremoveSnapshot=true + $ mvn versions:set-scm-tag -DnewTag="v1.12.0" + ``` + +1. In `README.md` update the `` tag value in the Maven dependency example. +1. In `CHANGELOG.md` verify all commit information for the current cycle is up-to-date, fix any discrepancies, then update the date for this release to the current date. +1. In `examples/pom.xml` update the version of the Influxdb3-java dependency to the version to be released. +1. Commit and push these changes to Github. ### Initiating the release In Github `influxComunit/influxb3-java`... 1. In the project home page open the _Releases_ section. -2. Click _Draft a new release_ -3. In the _Target_ dropdown check the new release branch. -4. In the _Tag_ dropdown click `Create new tag`, supply the tag matching the value added in the `set-scm-tag` command above. Note that the tag should be prefixed with the letter _v_. Click _Create_. -5. In the _Release title_ text control set the title to match the `` tag in `pom.xml`. -6. In the _Release notes_ text field copy changes added since the last release from `CHANEGLOG.md`. -7. If this is a pre-release check the _pre-release_ radio button. Note that for "pre-release" releases the release workflow will not publish modules to Maven Central, will not publish site documentation and will not prepare the next release cycle. This setting can be useful for debugging the workflow. -8. Click `Publish release`. +1. Click _Draft a new release_ +1. In the _Target_ dropdown check the new release branch. +1. In the _Tag_ dropdown click `Create new tag`, supply the tag matching the value added in the `set-scm-tag` command above. Note that the tag should be prefixed with the letter _v_. Click _Create_. +1. In the _Release title_ text control set the title to match the `` tag in `pom.xml`. +1. In the _Release notes_ text field copy changes added since the last release from `CHANEGLOG.md`. +1. If this is a pre-release check the _pre-release_ radio button. Note that for "pre-release" releases the release workflow will not publish modules to Maven Central, will not publish site documentation and will not prepare the next release cycle. This setting can be useful for debugging the workflow. +1. Click `Publish release`. The creation of the new release will trigger the `maven-release.yml` workflow. It will: 1. Verify required secrets and environment variables are set, and that SCM values in `pom.xml` match the repository from which the release is being triggered. -2. Check that the `pom.xml` version matches the release tag and that versioning references in documentation and examples are up-to-date and valid. -3. Check and sign the build. -4. Upload the archives and pom files to Maven Central. -5. Publish site documentation to https://github.com/influxcommunity/influxdb3-java/tree/gh-pages -6. prepare the `pom.xml` and `CHANGELOG.md` files for the next release cycle and push them to a new branch named `ci/next-cycle-`. +1. Check that the `pom.xml` version matches the release tag and that versioning references in documentation and examples are up-to-date and valid. +1. Check and sign the build. +1. Upload the archives and pom files to Maven Central. +1. Publish site documentation to [Github Pages](https://github.com/influxcommunity/influxdb3-java/tree/gh-pages) +1. prepare the `pom.xml` and `CHANGELOG.md` files for the next release cycle and push them to a new branch named `ci/next-cycle-`. -### Publish release in Maven Central. +### Publish release in Maven Central From the Maven Central account, review and publish the release to make it available to the public or drop it if the release workflow failed or if there are discrepancies in the files to be published. @@ -72,7 +73,7 @@ The release workflow is managed by `.github/workflows/maven-release.yml`. In or 1. Generate a random password for the key. -e.g. On a Linux box... + e.g. On a Linux box... ```bash $ head -c 6 /dev/urandom | base64 | tr -dc 'a-zA-Z0-9+-' @@ -114,7 +115,7 @@ Store this somewhere safe. ```bash $ gpg2 --keyserver keyserver.ubuntu.com --search-keys REDACTED_KEY_ID gpg: data source: http://185.125.188.27:11371 - (1) karel-rehor@users.noreply.github.com + (1) karel-rehor@users.noreply.github.com 263 bit EDDSA key REDACTED, created: 2026-09-03 Keys 1-1 of 1 for "REDACTED_KEY_ID". Enter number(s), N)ext, or Q)uit > 1 gpg: key REDACTED: "karel-rehor@users.noreply.github.com" not changed @@ -135,7 +136,6 @@ Store this somewhere safe. #### Revoking a compromised GPG2 key - 1. verify that the key is on the local server. ```bash From 2b58fee8cf5e7f028822f9165681b983a737e2df Mon Sep 17 00:00:00 2001 From: karel rehor Date: Mon, 14 Sep 2026 10:34:22 +0200 Subject: [PATCH 086/105] docs: fixing lint issues in RELEASE.md 02 --- RELEASE.md | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-) diff --git a/RELEASE.md b/RELEASE.md index 06fc84fc..d346aa46 100644 --- a/RELEASE.md +++ b/RELEASE.md @@ -17,7 +17,21 @@ Releasing involves three general steps. ```bash $ mvn versions:set -DremoveSnapshot=true + ... + [INFO] Scanning for projects... + [INFO] + [INFO] --------------------< com.influxdb:influxdb3-java >--------------------- + [INFO] Building InfluxDB 3 Java Client 1.12.0-SNAPSHOT + [INFO] --------------------------------[ jar ]--------------------------------- + ... $ mvn versions:set-scm-tag -DnewTag="v1.12.0" + ... + [INFO] --- versions-maven-plugin:2.21.0:set-scm-tag (default-cli) @ influxdb3-java --- + [INFO] Updating tag: HEAD -> v1.12.0 + [INFO] ------------------------------------------------------------------------ + [INFO] BUILD SUCCESS + [INFO] ------------------------------------------------------------------------ + ... ``` 1. In `README.md` update the `` tag value in the Maven dependency example. @@ -79,7 +93,8 @@ The release workflow is managed by `.github/workflows/maven-release.yml`. In or $ head -c 6 /dev/urandom | base64 | tr -dc 'a-zA-Z0-9+-' jEtkLlyG ``` -Store this somewhere safe. + + Store this somewhere safe. 1. Generate a key with a passphrase and no expiration. From 93ab125e0855f37a977660955f864b92df01dc5f Mon Sep 17 00:00:00 2001 From: karel rehor Date: Mon, 14 Sep 2026 10:39:14 +0200 Subject: [PATCH 087/105] docs: fix typos in RELEASE.md --- RELEASE.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/RELEASE.md b/RELEASE.md index d346aa46..d624780c 100644 --- a/RELEASE.md +++ b/RELEASE.md @@ -41,14 +41,14 @@ Releasing involves three general steps. ### Initiating the release -In Github `influxComunit/influxb3-java`... +In Github `influxComunity/influxb3-java`... 1. In the project home page open the _Releases_ section. 1. Click _Draft a new release_ 1. In the _Target_ dropdown check the new release branch. 1. In the _Tag_ dropdown click `Create new tag`, supply the tag matching the value added in the `set-scm-tag` command above. Note that the tag should be prefixed with the letter _v_. Click _Create_. 1. In the _Release title_ text control set the title to match the `` tag in `pom.xml`. -1. In the _Release notes_ text field copy changes added since the last release from `CHANEGLOG.md`. +1. In the _Release notes_ text field copy changes added since the last release from `CHANGELOG.md`. 1. If this is a pre-release check the _pre-release_ radio button. Note that for "pre-release" releases the release workflow will not publish modules to Maven Central, will not publish site documentation and will not prepare the next release cycle. This setting can be useful for debugging the workflow. 1. Click `Publish release`. From 620b863d96add9549b631d6b802831f720635df9 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Mon, 14 Sep 2026 11:01:20 +0200 Subject: [PATCH 088/105] chore: fixing lint issues in on-release.sh --- scripts/on-release.sh | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/scripts/on-release.sh b/scripts/on-release.sh index dd78d351..2c755b34 100755 --- a/scripts/on-release.sh +++ b/scripts/on-release.sh @@ -39,10 +39,7 @@ POM_XML_PATH="${PROJECT_DIR}/pom.xml" EXAMPLE_POM_XML_PATH="${PROJECT_DIR}/examples/pom.xml" RELEASE_NUM="" -NEXT_RELEASE_NUM="" -NEXT_RELEASE_BRANCH_BASE="chore/prepare-next-release-" RC_OR_BETA=false -IS_SNAPSHOT=false FAILURE_BOILERPLATE="Please delete the tag ${CIRCLE_TAG} and the related release, and start again." @@ -103,11 +100,11 @@ setup(){ } set_release_number(){ - RELEASE_NUM=$(echo ${RELEASE_TAG_NAME} | sed -r "s/-(rc|beta)[0-9]+//" | sed -r "s/^v//") + RELEASE_NUM=$(echo "${RELEASE_TAG_NAME}" | sed -r "s/-(rc|beta)[0-9]+//" | sed -r "s/^v//") } verify_rc_or_beta(){ - if [ -n "$(echo ${RELEASE_TAG_NAME} | grep -E "rc|beta")" ] + if echo "${RELEASE_TAG_NAME}" | grep -q "rc|beta" then RC_OR_BETA=true fi @@ -180,7 +177,7 @@ verify_version(){ } verify_example_pom(){ - EXAMPLE_DEPENDENCY_VERSION=$(xmllint --xpath "//*[local-name()='dependencies']/*[local-name()='dependency']/*[local-name()='version']/text()" ${EXAMPLE_POM_XML_PATH}) + EXAMPLE_DEPENDENCY_VERSION=$(xmllint --xpath "//*[local-name()='dependencies']/*[local-name()='dependency']/*[local-name()='version']/text()" "${EXAMPLE_POM_XML_PATH}") if [ "${RELEASE_NUM}" != "${EXAMPLE_DEPENDENCY_VERSION}" ] then printf "Example dependency version %s does not match the release number %s\n" "${EXAMPLE_DEPENDENCY_VERSION}" "${RELEASE_NUM}" @@ -223,6 +220,7 @@ echo "Running in Github Actions container." github_check verify_rc_or_beta +export RC_OR_BETA set_release_number verify_changelog From 21de1d60c2760138cd6bcfae9048ce1174cc9c38 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Mon, 14 Sep 2026 13:30:26 +0200 Subject: [PATCH 089/105] chore: fix lint issues in maven-release.yml --- .github/workflows/maven-release.yml | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index 6b8e15ca..f4ca08a1 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -106,7 +106,8 @@ jobs: fi gpg2 --version - export GPG_EXECUTABLE=$(command -v gpg2) + GPG_EXECUTABLE=$(command -v gpg2) + export GPG_EXECUTABLE - name: Script run: | ./scripts/on-release.sh @@ -157,27 +158,27 @@ jobs: echo "Preparing next release cycle" VERSION_CLEAN=${RELEASE_TAG_NAME} - PARTS=(${VERSION_CLEAN//./ }) + PARTS=("${VERSION_CLEAN//./ }") NEW_MINOR=$((PARTS[1]+1)) NEXT_RELEASE="${PARTS[0]}.${NEW_MINOR}.${PARTS[2]}" NEXT_RELEASE_BRANCH="ci/next-cycle-${NEXT_RELEASE}" git config user.email "${GITHUB_ACTOR}@users.noreply.github.com" - git config user.name ${GITHUB_ACTOR} - BRANCH_CHECK=$(git ls-remote --heads origin refs/heads/${NEXT_RELEASE_BRANCH}) + git config user.name "${GITHUB_ACTOR}" + BRANCH_CHECK=$(git ls-remote --heads origin "refs/heads/${NEXT_RELEASE_BRANCH}") if [ -n "${BRANCH_CHECK}" ] then echo "branch ${NEXT_RELEASE_BRANCH} already exists in project. Cannot recreate it automatically." echo "If you wish to use this automatically created branch, please delete the existing branch and start the release again" exit 1 fi - git checkout -b ${NEXT_RELEASE_BRANCH} + git checkout -b "${NEXT_RELEASE_BRANCH}" mvn versions:set-scm-tag -DnewTag="HEAD" mvn versions:set -DnextSnapshot=true -DnextSnapshotIndexToIncrement=2 sed -i "1s/^/## ${NEXT_RELEASE:1} [unreleased]\n\n/" CHANGELOG.md sed -i -e "s/${RELEASE_TAG_NAME:1}<\/version>/${NEXT_RELEASE:1}-SNAPSHOT<\/version>/" examples/pom.xml git add pom.xml CHANGELOG.md git commit -m "ci: setting up release cycle ${NEXT_RELEASE:1}" - git push --set-upstream origin ${NEXT_RELEASE_BRANCH} + git push --set-upstream origin "${NEXT_RELEASE_BRANCH}" # The following requires special permissions on the organizational and project level to work. Switching off for now. # gh pr create -B main -H ${NEXT_RELEASE_BRANCH} --title "Merge ${NEXT_RELEASE_BRANCH} into main" --body 'Created by Github action' # The alternative is to create the PR by hand From 4242886d3ac52134ca2c079da42e5c59614690ae Mon Sep 17 00:00:00 2001 From: karel rehor Date: Mon, 14 Sep 2026 13:41:35 +0200 Subject: [PATCH 090/105] chore: fix linter issue in maven-release.yml --- .github/workflows/maven-release.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index f4ca08a1..accca813 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -96,7 +96,7 @@ jobs: export GPG_PASSPHRASE="$GPG_PASSPHRASE_PRELIM" fi - echo "GPG_PASSPHRASE=${GPG_PASSPHRASE}" >> $GITHUB_ENV + echo "GPG_PASSPHRASE=${GPG_PASSPHRASE}" >> "$GITHUB_ENV" # Verify GPG2 environment if ! command -v gpg2 &> /dev/null From 199c93d52b5f2cb8e275cebebd28362b68cb652c Mon Sep 17 00:00:00 2001 From: karel rehor Date: Mon, 14 Sep 2026 16:53:17 +0200 Subject: [PATCH 091/105] chore: revise pom version values to match upstream HEAD. --- README.md | 2 +- examples/pom.xml | 2 +- pom.xml | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 9cbcf78e..a99836d2 100644 --- a/README.md +++ b/README.md @@ -49,7 +49,7 @@ Add the latest version of the client to your project: com.influxdb influxdb3-java - 1.12.0 + 1.11.0 ``` diff --git a/examples/pom.xml b/examples/pom.xml index 27b88d93..34e105f0 100644 --- a/examples/pom.xml +++ b/examples/pom.xml @@ -39,7 +39,7 @@ com.influxdb influxdb3-java - 1.12.0 + 1.12.0-SNAPSHOT diff --git a/pom.xml b/pom.xml index 3e6da6db..d9d91431 100644 --- a/pom.xml +++ b/pom.xml @@ -28,7 +28,7 @@ com.influxdb influxdb3-java jar - 1.12.0 + 1.12.0-SNAPSHOT InfluxDB 3 Java Client @@ -67,7 +67,7 @@ scm:git:https://github.com/InfluxCommunity/influxdb3-java.git scm:git:https://github.com/InfluxCommunity/influxdb3-java.git https://github.com/InfluxCommunity/influxdb3-java/tree/main - v1.12.0 + HEAD From 8325ce4933a4069ce3aecb00814fa65fc71f0646 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Mon, 14 Sep 2026 17:16:12 +0200 Subject: [PATCH 092/105] docs: anonymize commands in RELEASE.md --- RELEASE.md | 32 ++++++++++++++++---------------- 1 file changed, 16 insertions(+), 16 deletions(-) diff --git a/RELEASE.md b/RELEASE.md index d624780c..5ae917ef 100644 --- a/RELEASE.md +++ b/RELEASE.md @@ -99,8 +99,8 @@ The release workflow is managed by `.github/workflows/maven-release.yml`. In or 1. Generate a key with a passphrase and no expiration. ```bash - $ gpg --batch --passphrase= --quick-generate-key "karel-rehor@users.noreply.github.com" default default never - gpg: revocation certificate stored as '/home/karl/.gnupg/openpgp-revocs.d/REDACTED_KEY_ID.rev' + $ gpg --batch --passphrase= --quick-generate-key "your-user-name@users.noreply.github.com" default default never + gpg: revocation certificate stored as '/home//.gnupg/openpgp-revocs.d/REDACTED_KEY_ID.rev' ``` 1. Verify key. @@ -110,11 +110,11 @@ The release workflow is managed by `.github/workflows/maven-release.yml`. In or gpg: checking the trustdb gpg: marginals needed: 3 completes needed: 1 trust model: pgp gpg: depth: 0 valid: 1 signed: 0 trust: 0-, 0q, 0n, 0m, 0f, 1u - /home/karl/.gnupg/pubring.kbx + /home//.gnupg/pubring.kbx ----------------------------- pub ed25519 2026-09-03 [SC] REDACTED_KEY_ID - uid [ultimate] karel-rehor@users.noreply.github.com + uid [ultimate] your-user-name@users.noreply.github.com sub cv25519 2026-09-03 [E] ``` @@ -130,10 +130,10 @@ The release workflow is managed by `.github/workflows/maven-release.yml`. In or ```bash $ gpg2 --keyserver keyserver.ubuntu.com --search-keys REDACTED_KEY_ID gpg: data source: http://185.125.188.27:11371 - (1) karel-rehor@users.noreply.github.com + (1) your-user-name@users.noreply.github.com 263 bit EDDSA key REDACTED, created: 2026-09-03 Keys 1-1 of 1 for "REDACTED_KEY_ID". Enter number(s), N)ext, or Q)uit > 1 - gpg: key REDACTED: "karel-rehor@users.noreply.github.com" not changed + gpg: key REDACTED: "your-user-name@users.noreply.github.com" not changed gpg: Total number processed: 1 gpg: unchanged: 1 ``` @@ -155,11 +155,11 @@ The release workflow is managed by `.github/workflows/maven-release.yml`. In or ```bash $ gpg2 --list-keys - /home/karl/.gnupg/pubring.kbx + /home//.gnupg/pubring.kbx ----------------------------- pub ed25519 2026-07-27 [SC] [expires: 2029-07-26] KEY_ID_REDACTED - uid [ultimate] karel-rehor@users.noreply.github.com + uid [ultimate] your_user_name@users.noreply.github.com sub REDACTED 2026-07-27 [E] ``` @@ -170,7 +170,7 @@ The release workflow is managed by `.github/workflows/maven-release.yml`. In or $ gpg2 --list-keys KEY_ID_REDACTED pub ed25519 2026-07-27 [SC] [expires: 2029-07-26] KEY_ID_REDACTED - uid [ultimate] karel-rehor@users.noreply.github.com + uid [ultimate] your-user-name@users.noreply.github.com sub REDACTED 2026-07-27 [E] ``` @@ -179,10 +179,10 @@ The release workflow is managed by `.github/workflows/maven-release.yml`. In or ```bash $ gpg2 --keyserver keyserver.ubuntu.com --search-keys KEY_ID_REDACTED gpg: data source: http://185.125.188.27:11371 - (1) karel-rehor@users.noreply.github.com + (1) your-user-name@users.noreply.github.com 263 bit EDDSA key REDACTED, created: 2026-07-27 Keys 1-1 of 1 for "KEY_ID_REDACTED". Enter number(s), N)ext, or Q)uit > 1 - gpg: key REDACTED: "karel-rehor@users.noreply.github.com" not changed + gpg: key REDACTED: "your-user-name@users.noreply.github.com" not changed gpg: Total number processed: 1 gpg: unchanged: 1 ``` @@ -190,15 +190,15 @@ The release workflow is managed by `.github/workflows/maven-release.yml`. In or 1. Create a revocation request locally. ```bash - $ gpg2 --output revoke-karel-rehor.asc --gen-revoke KEY_ID_REDACTED + $ gpg2 --output revoke-.asc --gen-revoke KEY_ID_REDACTED ... ``` 1. Revoke the key locally. ```bash - $ gpg2 --import revoke-karel-rehor.asc - gpg: key REDACTED: "karel-rehor@users.noreply.github.com" revocation certificate imported + $ gpg2 --import revoke-.asc + gpg: key REDACTED: "your-user-name@users.noreply.github.com" revocation certificate imported gpg: Total number processed: 1 gpg: new key revocations: 1 gpg: marginals needed: 3 completes needed: 1 trust model: pgp @@ -210,11 +210,11 @@ The release workflow is managed by `.github/workflows/maven-release.yml`. In or ```bash $ gpg2 --list-keys - /home/karl/.gnupg/pubring.kbx + /home//.gnupg/pubring.kbx ----------------------------- pub ed25519 2026-07-27 [SC] [revoked: 2026-09-03] KEY_ID_REDACTED - uid [ revoked] karel-rehor@users.noreply.github.com + uid [ revoked] your-user-name@users.noreply.github.com ``` 1. Push change of key state to remote server. From fb989d958920eecdc70accaec8a247964d6f7a65 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Mon, 14 Sep 2026 17:24:57 +0200 Subject: [PATCH 093/105] chore: fix typo in on-releas.sh, add reminder to check RC_OR_BETA tagged releases. --- .github/workflows/maven-release.yml | 1 + scripts/on-release.sh | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index accca813..4ead2ac1 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -111,6 +111,7 @@ jobs: - name: Script run: | ./scripts/on-release.sh + # TODO after run verify value RC_OR_BETA and then use this to exit release if this is true. - name: Release run: | if [[ "${IS_PRERELEASE}" == "true" ]]; then diff --git a/scripts/on-release.sh b/scripts/on-release.sh index 2c755b34..1a19242a 100755 --- a/scripts/on-release.sh +++ b/scripts/on-release.sh @@ -170,7 +170,7 @@ verify_version(){ if [ "${SCM_TAG}" != "${RELEASE_TAG_NAME}" ] then printf "SCM_TAG %s in pom.xml does not match tag %s" "${SCM_TAG}" "${RELEASE_TAG_NAME}" - prinf "%s\n" "${FAILURE_BOILERPLATE}" + printf "%s\n" "${FAILURE_BOILERPLATE}" exit 1 fi From 4d90a18a6bf8d8e78a8c1a41dfe7f7f434db12a0 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Mon, 14 Sep 2026 17:30:31 +0200 Subject: [PATCH 094/105] chore: fix flaws in workflow and bash scripts. --- .github/workflows/maven-release.yml | 2 +- scripts/on-release.sh | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index 4ead2ac1..bf185b3f 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -177,7 +177,7 @@ jobs: mvn versions:set -DnextSnapshot=true -DnextSnapshotIndexToIncrement=2 sed -i "1s/^/## ${NEXT_RELEASE:1} [unreleased]\n\n/" CHANGELOG.md sed -i -e "s/${RELEASE_TAG_NAME:1}<\/version>/${NEXT_RELEASE:1}-SNAPSHOT<\/version>/" examples/pom.xml - git add pom.xml CHANGELOG.md + git add pom.xml examples/pom.xml CHANGELOG.md git commit -m "ci: setting up release cycle ${NEXT_RELEASE:1}" git push --set-upstream origin "${NEXT_RELEASE_BRANCH}" # The following requires special permissions on the organizational and project level to work. Switching off for now. diff --git a/scripts/on-release.sh b/scripts/on-release.sh index 1a19242a..ce80bedb 100755 --- a/scripts/on-release.sh +++ b/scripts/on-release.sh @@ -41,7 +41,7 @@ EXAMPLE_POM_XML_PATH="${PROJECT_DIR}/examples/pom.xml" RELEASE_NUM="" RC_OR_BETA=false -FAILURE_BOILERPLATE="Please delete the tag ${CIRCLE_TAG} and the related release, and start again." +FAILURE_BOILERPLATE="Please delete the tag ${RELEASE_TAG_NAME} and the related release, and start again." github_check(){ From 335aac56c933668f94878a1d3c2c2670a0928048 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Tue, 15 Sep 2026 10:45:03 +0200 Subject: [PATCH 095/105] chore: use more meaningful user.email in workflow. --- .github/workflows/maven-release.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index bf185b3f..f88d9db4 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -146,7 +146,7 @@ jobs: EOF - git config --global user.email "test@example.com" + git config --global user.email "${GITHUB_TRIGGERING_ACTOR}@noreply.github.com" git config --global user.name "Github Action" mvn clean site site:stage -DskipTests mvn -s scm-settings.xml --batch-mode scm-publish:publish-scm -Dscmpublish.serverId=github From f7dd26c9cf421de88e4f41f9a3ecef14d510a29a Mon Sep 17 00:00:00 2001 From: karel rehor Date: Tue, 15 Sep 2026 10:48:33 +0200 Subject: [PATCH 096/105] chore: use current shell when calling on-release.sh in workflow --- .github/workflows/maven-release.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index f88d9db4..a14f6139 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -110,7 +110,7 @@ jobs: export GPG_EXECUTABLE - name: Script run: | - ./scripts/on-release.sh + . ./scripts/on-release.sh # TODO after run verify value RC_OR_BETA and then use this to exit release if this is true. - name: Release run: | From b4f8422fb3cc4e8a52ac5a6669ff571f3de73d6d Mon Sep 17 00:00:00 2001 From: karel rehor Date: Tue, 15 Sep 2026 14:59:44 +0200 Subject: [PATCH 097/105] chore: fix RC or BETA release tag checks. --- .github/workflows/maven-release.yml | 15 +++++++++++++++ scripts/on-release.sh | 3 ++- 2 files changed, 17 insertions(+), 1 deletion(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index a14f6139..edec1956 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -118,6 +118,11 @@ jobs: echo "This is a pre release and will not be deployed to Maven Central." exit 0 fi + if [[ "${RC_OR_BETA}" == "true" ]] + then + echo "This is an RC or BETA release and will not be deployed to Maven Central." + exit 0 + fi cat << EOF > release.properties scm.url=scm\:git\:https\://github.com/${GITHUB_REPOSITORY}.git scm.tag=${RELEASE_TAG_NAME} @@ -135,6 +140,11 @@ jobs: echo "This is a pre release, so site documentation will not be updated to Github pages." exit 0 fi + if [[ "${RC_OR_BETA}" == "true" ]] + then + echo "This is an RC or BETA release, so site documentation will not be updated to Github pages." + exit 0 + fi cat << EOF > scm-settings.xml @@ -156,6 +166,11 @@ jobs: echo "This is a prerelease so the next release cycle will not be prepared." exit 0 fi + if [[ "${RC_OR_BETA}" == "true" ]] + then + echo "This is an RC or BETA release so next release cycle will not be prepared." + exit 0 + fi echo "Preparing next release cycle" VERSION_CLEAN=${RELEASE_TAG_NAME} diff --git a/scripts/on-release.sh b/scripts/on-release.sh index ce80bedb..30f26b44 100755 --- a/scripts/on-release.sh +++ b/scripts/on-release.sh @@ -104,7 +104,8 @@ set_release_number(){ } verify_rc_or_beta(){ - if echo "${RELEASE_TAG_NAME}" | grep -q "rc|beta" + LOWER_TAG_NAME=$(echo "${RELEASE_TAG_NAME}" | tr '[:upper:]' '[:lower:]') + if echo "${LOWER_TAG_NAME}" | grep -q "[rc|beta]" then RC_OR_BETA=true fi From c9af311a87133ae87c5fb6800d807cc4792a8752 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Tue, 15 Sep 2026 16:50:35 +0200 Subject: [PATCH 098/105] chore: update trigger, fix snapshot credentials, verify workfow envars. --- .github/workflows/maven-release.yml | 8 +++++++- RELEASE.md | 2 +- deploy-settings.xml | 4 ++-- pom.xml | 2 +- 4 files changed, 11 insertions(+), 5 deletions(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index edec1956..8680fad4 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -3,7 +3,7 @@ name: Maven Releasing on: release: - types: [created] + types: [published] jobs: release: @@ -35,6 +35,11 @@ jobs: sudo apt-get install libxml2-utils - name: Verify Env run: | + if [[ -z "${{ secrets.GPG_PRIVATE_KEY }}" ]] + then + echo "ERROR GPG_PRIVATE_KEY is missing." + exit 1 + fi # ensure scm properties match current project - don't want to modify other repository inadvertently POM_SITE_URL=$(xmllint --xpath "//*[local-name()='distributionManagement']/*[local-name()='site']/*[local-name()='url']/text()" ./pom.xml) POM_SCM_CONNECTION=$(xmllint --xpath "//*[local-name()='scm']/*[local-name()='connection']/text()" ./pom.xml) @@ -108,6 +113,7 @@ jobs: gpg2 --version GPG_EXECUTABLE=$(command -v gpg2) export GPG_EXECUTABLE + echo "GPG_EXECUTABLE=${GPG_EXECUTABLE}" >> "$GITHUB_ENV" - name: Script run: | . ./scripts/on-release.sh diff --git a/RELEASE.md b/RELEASE.md index 5ae917ef..72338924 100644 --- a/RELEASE.md +++ b/RELEASE.md @@ -41,7 +41,7 @@ Releasing involves three general steps. ### Initiating the release -In Github `influxComunity/influxb3-java`... +In Github `influxCommunity/influxb3-java`... 1. In the project home page open the _Releases_ section. 1. Click _Draft a new release_ diff --git a/deploy-settings.xml b/deploy-settings.xml index 0acec203..f3761fc5 100644 --- a/deploy-settings.xml +++ b/deploy-settings.xml @@ -25,7 +25,7 @@ xsi:schemaLocation="http://maven.apache.org/SETTINGS/1.1.0 http://maven.apache.org/xsd/settings-1.1.0.xsd"> - central + ossrh ${env.SONATYPE_USERNAME} ${env.SONATYPE_PASSWORD} @@ -33,7 +33,7 @@ - central + ossrh true diff --git a/pom.xml b/pom.xml index 3109255d..f96160b1 100644 --- a/pom.xml +++ b/pom.xml @@ -757,7 +757,7 @@ 0.9.0 true - central + ossrh From d5d68d85cf953801647b2b467b2012163f6f27c8 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Tue, 15 Sep 2026 16:55:06 +0200 Subject: [PATCH 099/105] chore: remove TODO and set RC_OR_BETA envar --- .github/workflows/maven-release.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index 8680fad4..1adb70f8 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -117,7 +117,7 @@ jobs: - name: Script run: | . ./scripts/on-release.sh - # TODO after run verify value RC_OR_BETA and then use this to exit release if this is true. + echo "RC_OR_BETA=${RC_OR_BETA}" >> "$GITHUB_ENV" - name: Release run: | if [[ "${IS_PRERELEASE}" == "true" ]]; then From 8c12cd0e60ae58caf257be46811e658cb19211d6 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Tue, 15 Sep 2026 17:28:03 +0200 Subject: [PATCH 100/105] chore: fix typos add TODOs for fixes in on-release.sh --- .github/workflows/maven-release.yml | 2 +- RELEASE.md | 6 +++--- scripts/on-release.sh | 3 +++ 3 files changed, 7 insertions(+), 4 deletions(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index 1adb70f8..bc96b574 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -32,7 +32,7 @@ jobs: - name: Add dependencies run: | sudo apt-get update - sudo apt-get install libxml2-utils + sudo apt-get -y install libxml2-utils - name: Verify Env run: | if [[ -z "${{ secrets.GPG_PRIVATE_KEY }}" ]] diff --git a/RELEASE.md b/RELEASE.md index 72338924..4a8a53ec 100644 --- a/RELEASE.md +++ b/RELEASE.md @@ -41,7 +41,7 @@ Releasing involves three general steps. ### Initiating the release -In Github `influxCommunity/influxb3-java`... +In Github `influxCommunity/influxdb3-java`... 1. In the project home page open the _Releases_ section. 1. Click _Draft a new release_ @@ -77,7 +77,7 @@ A new branch `ci/next-cycle-` with an updated `pom.xml` fi The release workflow is managed by `.github/workflows/maven-release.yml`. In order for the release workflow to succeed a number of environment secrets need to be set in the project. It may be necessary to update these in the future. - `GPG_PASSPHRASE` - password for the key used to sign archives and pom files to be uploaded to Maven Central. See _Generating a new GPG signing key_ below. -- `GPG_PRIVATE_KEY` - private key associate with public key pulled from a GPG repository and used to sign archives and pom files. +- `GPG_PRIVATE_KEY` - private key associated with public key pulled from a GPG repository and used to sign archives and pom files. - `SONATYPE_PASSWORD` - password for the user account used to upload archives and pom files to Maven Central. - `SONATYPE_USERNAME` - name of user account used to upload archives and pom files to Maven Central. @@ -122,7 +122,7 @@ The release workflow is managed by `.github/workflows/maven-release.yml`. In or ```bash $ gpg2 --keyserver keyserver.ubuntu.com --send-keys REDACTED_KEY_ID - gpg: sending key REDACETD to hkp://keyserver.ubuntu.com + gpg: sending key REDACTED to hkp://keyserver.ubuntu.com ``` 1. Verify key is on remote. Note, that it may take a few minutes to be registered. diff --git a/scripts/on-release.sh b/scripts/on-release.sh index 30f26b44..509f01d1 100755 --- a/scripts/on-release.sh +++ b/scripts/on-release.sh @@ -72,6 +72,7 @@ github_check(){ fi if [ -z "${RELEASE_TAG_NAME}" ]; then + # TODO validate RELEASE_TAG_NAME is acceptable echo "This script requires a release tag, but none was found." exit 1 fi @@ -105,6 +106,7 @@ set_release_number(){ verify_rc_or_beta(){ LOWER_TAG_NAME=$(echo "${RELEASE_TAG_NAME}" | tr '[:upper:]' '[:lower:]') + # TODO fix grep match to match () full tokens rc or beta if echo "${LOWER_TAG_NAME}" | grep -q "[rc|beta]" then RC_OR_BETA=true @@ -135,6 +137,7 @@ verify_changelog() { fi if [[ ! "$HEADER_DATE" =~ ^[0-9]{4}-[0-9]{2}-[0-9]{2}$ ]]; then + # TODO parse value as data and verify that it is legit instead of regex printf "ERROR invalid commit date (%s) in last CHANGELOG.md entry\n" "$HEADER_DATE" printf "Please update the commit date in CHANGELOG.md\n" printf "%s\n" "${FAILURE_BOILERPLATE}" From 714d229b5488fbb8742c8872724180490d3cfdb5 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Wed, 16 Sep 2026 10:46:22 +0200 Subject: [PATCH 101/105] chore: improve checks in on-release.sh --- scripts/on-release.sh | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/scripts/on-release.sh b/scripts/on-release.sh index 509f01d1..8d919201 100755 --- a/scripts/on-release.sh +++ b/scripts/on-release.sh @@ -71,9 +71,9 @@ github_check(){ exit 1 fi - if [ -z "${RELEASE_TAG_NAME}" ]; then - # TODO validate RELEASE_TAG_NAME is acceptable - echo "This script requires a release tag, but none was found." + if ! echo "${RELEASE_TAG_NAME}" | grep -Ei '^v[0-9]+\.[0-9]+\.[0-9]+(-(rc|beta|snapshot)[0-9]*)?$' + then + echo "This script requires a valid release tag (e.g. v1.9.0), but RELEASE_TAG_NAME=${RELEASE_TAG_NAME} was found." exit 1 fi @@ -106,8 +106,7 @@ set_release_number(){ verify_rc_or_beta(){ LOWER_TAG_NAME=$(echo "${RELEASE_TAG_NAME}" | tr '[:upper:]' '[:lower:]') - # TODO fix grep match to match () full tokens rc or beta - if echo "${LOWER_TAG_NAME}" | grep -q "[rc|beta]" + if echo "${LOWER_TAG_NAME}" | grep -q "rc\|beta" then RC_OR_BETA=true fi @@ -136,8 +135,8 @@ verify_changelog() { printf "CHANGELOG.md release number check: OK ✓\n" fi - if [[ ! "$HEADER_DATE" =~ ^[0-9]{4}-[0-9]{2}-[0-9]{2}$ ]]; then - # TODO parse value as data and verify that it is legit instead of regex + if ! date --date="${HEADER_DATE}" + then printf "ERROR invalid commit date (%s) in last CHANGELOG.md entry\n" "$HEADER_DATE" printf "Please update the commit date in CHANGELOG.md\n" printf "%s\n" "${FAILURE_BOILERPLATE}" From c02677c1991f967f61031b9a10a2d39fcbce52ad Mon Sep 17 00:00:00 2001 From: karel rehor Date: Wed, 16 Sep 2026 13:56:32 +0200 Subject: [PATCH 102/105] chore: better control sequencing, better checks in workflow. --- .github/workflows/maven-release.yml | 116 ++++++++++++++++++---------- 1 file changed, 76 insertions(+), 40 deletions(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index bc96b574..c726dbfe 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -114,6 +114,37 @@ jobs: GPG_EXECUTABLE=$(command -v gpg2) export GPG_EXECUTABLE echo "GPG_EXECUTABLE=${GPG_EXECUTABLE}" >> "$GITHUB_ENV" + + # Verify tag and next version + if ! echo "${RELEASE_TAG_NAME}" | grep -Ei '^v[0-9]+\.[0-9]+\.[0-9]+(-(rc|beta|snapshot)[0-9]*)?$' + then + echo "RELEASE_TAG_NAME ${RELEASE_TAG_NAME} does not match expected pattern, e.g. (v1.9.0). Exiting." + exit 1 + fi + VERSION_CLEAN="${RELEASE_TAG_NAME:1}" + # shellcheck disable=SC2206 + PARTS=(${VERSION_CLEAN//./ }) + # TODO Check if PARTS[2] starts with 0 or [1-9] if not 0 then this is hot release and should not trigger publishing + if ! echo "${PARTS[2]}" | grep -q "^0.*" + then + echo "Detected hot fix release ${RELEASE_TAG_NAME}" + echo "IS_HOT_FIX=true" >> "${GITHUB_ENV}" + fi + NEW_MINOR=$((PARTS[1]+1)) + NEXT_RELEASE="${PARTS[0]}.${NEW_MINOR}.0" + echo "NEXT_RELEASE=${NEXT_RELEASE}" >> "${GITHUB_ENV}" + NEXT_RELEASE_BRANCH="ci/next-cycle-${NEXT_RELEASE}" + git config user.email "${GITHUB_ACTOR}@users.noreply.github.com" + git config user.name "${GITHUB_ACTOR}" + BRANCH_CHECK=$(git ls-remote --heads origin "refs/heads/${NEXT_RELEASE_BRANCH}") + if [ -n "${BRANCH_CHECK}" ] + then + echo "branch ${NEXT_RELEASE_BRANCH} already exists in project. Cannot recreate it automatically." + echo "If you wish to use this automatically created branch, please delete the existing branch and start the release again" + exit 1 + fi + echo "NEXT_RELEASE_BRANCH=${NEXT_RELEASE_BRANCH}" >> "$GITHUB_ENV" + - name: Script run: | . ./scripts/on-release.sh @@ -129,6 +160,11 @@ jobs: echo "This is an RC or BETA release and will not be deployed to Maven Central." exit 0 fi + if [[ "${IS_HOT_FIX}" == "true" ]] + then + echo "This is a hot fix release ${RELEASE_TAG_NAME} and will not be deployed to Maven Central." + exit 0 + fi cat << EOF > release.properties scm.url=scm\:git\:https\://github.com/${GITHUB_REPOSITORY}.git scm.tag=${RELEASE_TAG_NAME} @@ -138,34 +174,6 @@ jobs: -Dgoals=deploy \ -s ./deploy-settings.xml \ -Darguments="-DskipTests -DskipITs -DperformRelease=true" - - name: Publish documentation - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - run: | - if [[ "${IS_PRERELEASE}" == "true" ]]; then - echo "This is a pre release, so site documentation will not be updated to Github pages." - exit 0 - fi - if [[ "${RC_OR_BETA}" == "true" ]] - then - echo "This is an RC or BETA release, so site documentation will not be updated to Github pages." - exit 0 - fi - cat << EOF > scm-settings.xml - - - - github - x-access-token - ${GITHUB_TOKEN} - - - - EOF - git config --global user.email "${GITHUB_TRIGGERING_ACTOR}@noreply.github.com" - git config --global user.name "Github Action" - mvn clean site site:stage -DskipTests - mvn -s scm-settings.xml --batch-mode scm-publish:publish-scm -Dscmpublish.serverId=github - name: Prepare next cycle run: | if [[ "${IS_PRERELEASE}" == "true" ]]; then @@ -177,22 +185,17 @@ jobs: echo "This is an RC or BETA release so next release cycle will not be prepared." exit 0 fi + if [[ "${IS_HOT_FIX}" == "true" ]] + then + echo "This is a hot fix release ${RELEASE_TAG_NAME}, so next release cycle will not be prepared." + exit 0 + fi + echo "Preparing next release cycle" - VERSION_CLEAN=${RELEASE_TAG_NAME} - PARTS=("${VERSION_CLEAN//./ }") - NEW_MINOR=$((PARTS[1]+1)) - NEXT_RELEASE="${PARTS[0]}.${NEW_MINOR}.${PARTS[2]}" - NEXT_RELEASE_BRANCH="ci/next-cycle-${NEXT_RELEASE}" git config user.email "${GITHUB_ACTOR}@users.noreply.github.com" git config user.name "${GITHUB_ACTOR}" - BRANCH_CHECK=$(git ls-remote --heads origin "refs/heads/${NEXT_RELEASE_BRANCH}") - if [ -n "${BRANCH_CHECK}" ] - then - echo "branch ${NEXT_RELEASE_BRANCH} already exists in project. Cannot recreate it automatically." - echo "If you wish to use this automatically created branch, please delete the existing branch and start the release again" - exit 1 - fi + echo "checking out next release branch ${NEXT_RELEASE_BRANCH}" git checkout -b "${NEXT_RELEASE_BRANCH}" mvn versions:set-scm-tag -DnewTag="HEAD" mvn versions:set -DnextSnapshot=true -DnextSnapshotIndexToIncrement=2 @@ -207,3 +210,36 @@ jobs: echo "The branch ${NEXT_RELEASE_BRANCH} has been created. You can create and merge a PR manually from it to start the next release cycle." env: GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} + - name: Publish documentation + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + run: | + if [[ "${IS_PRERELEASE}" == "true" ]]; then + echo "This is a pre release, so site documentation will not be updated to Github pages." + exit 0 + fi + if [[ "${RC_OR_BETA}" == "true" ]] + then + echo "This is an RC or BETA release, so site documentation will not be updated to Github pages." + exit 0 + fi + if [[ "${IS_HOT_FIX}" == "true" ]] + then + echo "This is a hot fix release ${RELEASE_TAG_NAME}, so site documentation will not be updated to Github pages." + exit 0 + fi + cat << EOF > scm-settings.xml + + + + github + x-access-token + ${GITHUB_TOKEN} + + + + EOF + git config --global user.email "${GITHUB_TRIGGERING_ACTOR}@noreply.github.com" + git config --global user.name "Github Action" + mvn clean site site:stage -DskipTests + mvn -s scm-settings.xml --batch-mode scm-publish:publish-scm -Dscmpublish.serverId=github From 8537d04d3696bca1747a08d58daaeaed54d47507 Mon Sep 17 00:00:00 2001 From: karel rehor Date: Wed, 16 Sep 2026 14:49:25 +0200 Subject: [PATCH 103/105] chore: fine tune release workflow and script. --- .github/workflows/maven-release.yml | 22 ++++++++++------------ scripts/on-release.sh | 2 +- 2 files changed, 11 insertions(+), 13 deletions(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index c726dbfe..fc22c3e5 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -136,13 +136,7 @@ jobs: NEXT_RELEASE_BRANCH="ci/next-cycle-${NEXT_RELEASE}" git config user.email "${GITHUB_ACTOR}@users.noreply.github.com" git config user.name "${GITHUB_ACTOR}" - BRANCH_CHECK=$(git ls-remote --heads origin "refs/heads/${NEXT_RELEASE_BRANCH}") - if [ -n "${BRANCH_CHECK}" ] - then - echo "branch ${NEXT_RELEASE_BRANCH} already exists in project. Cannot recreate it automatically." - echo "If you wish to use this automatically created branch, please delete the existing branch and start the release again" - exit 1 - fi + echo "NEXT_RELEASE_BRANCH=${NEXT_RELEASE_BRANCH}" >> "$GITHUB_ENV" - name: Script @@ -160,11 +154,6 @@ jobs: echo "This is an RC or BETA release and will not be deployed to Maven Central." exit 0 fi - if [[ "${IS_HOT_FIX}" == "true" ]] - then - echo "This is a hot fix release ${RELEASE_TAG_NAME} and will not be deployed to Maven Central." - exit 0 - fi cat << EOF > release.properties scm.url=scm\:git\:https\://github.com/${GITHUB_REPOSITORY}.git scm.tag=${RELEASE_TAG_NAME} @@ -191,6 +180,14 @@ jobs: exit 0 fi + BRANCH_CHECK=$(git ls-remote --heads origin "refs/heads/${NEXT_RELEASE_BRANCH}") + if [ -n "${BRANCH_CHECK}" ] + then + echo "branch ${NEXT_RELEASE_BRANCH} already exists in project. Cannot recreate it automatically." + echo "If you wish to use this automatically created branch, please delete the existing branch and start the release again" + exit 1 + fi + echo "Preparing next release cycle" git config user.email "${GITHUB_ACTOR}@users.noreply.github.com" @@ -241,5 +238,6 @@ jobs: EOF git config --global user.email "${GITHUB_TRIGGERING_ACTOR}@noreply.github.com" git config --global user.name "Github Action" + git checkout "${RELEASE_TAG_NAME}" mvn clean site site:stage -DskipTests mvn -s scm-settings.xml --batch-mode scm-publish:publish-scm -Dscmpublish.serverId=github diff --git a/scripts/on-release.sh b/scripts/on-release.sh index 8d919201..e45a7773 100755 --- a/scripts/on-release.sh +++ b/scripts/on-release.sh @@ -101,7 +101,7 @@ setup(){ } set_release_number(){ - RELEASE_NUM=$(echo "${RELEASE_TAG_NAME}" | sed -r "s/-(rc|beta)[0-9]+//" | sed -r "s/^v//") + RELEASE_NUM=$(echo "${RELEASE_TAG_NAME}" | sed -r "/-(rc|beta|snapshot)[0-9]+/Is///" | sed -r "s/^v//") } verify_rc_or_beta(){ From a36fec103b477a99aed304a8b91c0f89a0745c1b Mon Sep 17 00:00:00 2001 From: karel rehor Date: Wed, 16 Sep 2026 15:25:05 +0200 Subject: [PATCH 104/105] chore: remove snapshot checks, revert workflow check for next working snapshot branch. --- .github/workflows/maven-release.yml | 17 ++++++++--------- RELEASE.md | 4 ++-- scripts/on-release.sh | 2 +- 3 files changed, 11 insertions(+), 12 deletions(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index fc22c3e5..86e3552e 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -116,7 +116,7 @@ jobs: echo "GPG_EXECUTABLE=${GPG_EXECUTABLE}" >> "$GITHUB_ENV" # Verify tag and next version - if ! echo "${RELEASE_TAG_NAME}" | grep -Ei '^v[0-9]+\.[0-9]+\.[0-9]+(-(rc|beta|snapshot)[0-9]*)?$' + if ! echo "${RELEASE_TAG_NAME}" | grep -Ei '^v[0-9]+\.[0-9]+\.[0-9]+(-(rc|beta)[0-9]*)?$' then echo "RELEASE_TAG_NAME ${RELEASE_TAG_NAME} does not match expected pattern, e.g. (v1.9.0). Exiting." exit 1 @@ -136,6 +136,13 @@ jobs: NEXT_RELEASE_BRANCH="ci/next-cycle-${NEXT_RELEASE}" git config user.email "${GITHUB_ACTOR}@users.noreply.github.com" git config user.name "${GITHUB_ACTOR}" + BRANCH_CHECK=$(git ls-remote --heads origin "refs/heads/${NEXT_RELEASE_BRANCH}") + if [ -n "${BRANCH_CHECK}" ] + then + echo "branch ${NEXT_RELEASE_BRANCH} already exists in project. Cannot recreate it automatically." + echo "If you wish to use this automatically created branch, please delete the existing branch and start the release again" + exit 1 + fi echo "NEXT_RELEASE_BRANCH=${NEXT_RELEASE_BRANCH}" >> "$GITHUB_ENV" @@ -180,14 +187,6 @@ jobs: exit 0 fi - BRANCH_CHECK=$(git ls-remote --heads origin "refs/heads/${NEXT_RELEASE_BRANCH}") - if [ -n "${BRANCH_CHECK}" ] - then - echo "branch ${NEXT_RELEASE_BRANCH} already exists in project. Cannot recreate it automatically." - echo "If you wish to use this automatically created branch, please delete the existing branch and start the release again" - exit 1 - fi - echo "Preparing next release cycle" git config user.email "${GITHUB_ACTOR}@users.noreply.github.com" diff --git a/RELEASE.md b/RELEASE.md index 4a8a53ec..0191f798 100644 --- a/RELEASE.md +++ b/RELEASE.md @@ -96,10 +96,10 @@ The release workflow is managed by `.github/workflows/maven-release.yml`. In or Store this somewhere safe. -1. Generate a key with a passphrase and no expiration. +1. Generate a key with a passphrase and no expiration. Note you will be required to enter the passphrase from above. ```bash - $ gpg --batch --passphrase= --quick-generate-key "your-user-name@users.noreply.github.com" default default never + $ gpg --batch --quick-generate-key "your-user-name@users.noreply.github.com" default default never gpg: revocation certificate stored as '/home//.gnupg/openpgp-revocs.d/REDACTED_KEY_ID.rev' ``` diff --git a/scripts/on-release.sh b/scripts/on-release.sh index e45a7773..47d58233 100755 --- a/scripts/on-release.sh +++ b/scripts/on-release.sh @@ -101,7 +101,7 @@ setup(){ } set_release_number(){ - RELEASE_NUM=$(echo "${RELEASE_TAG_NAME}" | sed -r "/-(rc|beta|snapshot)[0-9]+/Is///" | sed -r "s/^v//") + RELEASE_NUM=$(echo "${RELEASE_TAG_NAME}" | sed -r "/-(rc|beta)[0-9]*/Is///" | sed -r "s/^v//") } verify_rc_or_beta(){ From 8084ad5f3a9b1898fd3d55ce254166cc33f9660e Mon Sep 17 00:00:00 2001 From: karel rehor Date: Wed, 16 Sep 2026 16:59:54 +0200 Subject: [PATCH 105/105] chore: fine tune behavior for patch releases. --- .github/workflows/maven-release.yml | 20 +++++++++++++------- 1 file changed, 13 insertions(+), 7 deletions(-) diff --git a/.github/workflows/maven-release.yml b/.github/workflows/maven-release.yml index 86e3552e..2d69fecf 100644 --- a/.github/workflows/maven-release.yml +++ b/.github/workflows/maven-release.yml @@ -45,7 +45,7 @@ jobs: POM_SCM_CONNECTION=$(xmllint --xpath "//*[local-name()='scm']/*[local-name()='connection']/text()" ./pom.xml) POM_SCM_DEVELOPER_CONNECTION=$(xmllint --xpath "//*[local-name()='scm']/*[local-name()='developerConnection']/text()" ./pom.xml) - if [[ ! "${POM_SITE_URL}" =~ .*${GITHUB_REPOSITORY}$ ]] + if [[ ! "${POM_SITE_URL}" != "scm:git:https://github.com/${GITHUB_REPOSITORY}" ]] then echo "POM_SITE_URL ${POM_SITE_URL} does not match GITHUB_REPOSITORY ${GITHUB_REPOSITORY}" exit 1 @@ -136,12 +136,18 @@ jobs: NEXT_RELEASE_BRANCH="ci/next-cycle-${NEXT_RELEASE}" git config user.email "${GITHUB_ACTOR}@users.noreply.github.com" git config user.name "${GITHUB_ACTOR}" - BRANCH_CHECK=$(git ls-remote --heads origin "refs/heads/${NEXT_RELEASE_BRANCH}") - if [ -n "${BRANCH_CHECK}" ] + + if [[ "${IS_PRERELEASE}" != "true" && "${RELEASE_TAG_NAME,,}" =~ ^v[0-9]+\.[0-9]+\.0$ ]] then - echo "branch ${NEXT_RELEASE_BRANCH} already exists in project. Cannot recreate it automatically." - echo "If you wish to use this automatically created branch, please delete the existing branch and start the release again" - exit 1 + BRANCH_CHECK=$(git ls-remote --heads origin "refs/heads/${NEXT_RELEASE_BRANCH}") + if [ -n "${BRANCH_CHECK}" ] + then + echo "branch ${NEXT_RELEASE_BRANCH} already exists in project. Cannot recreate it automatically." + echo "If you wish to use this automatically created branch, please delete the existing branch and start the release again" + exit 1 + fi + else + echo "Skipping next release cycle branch check because this is either a pre-release or a patch fix." fi echo "NEXT_RELEASE_BRANCH=${NEXT_RELEASE_BRANCH}" >> "$GITHUB_ENV" @@ -194,7 +200,7 @@ jobs: echo "checking out next release branch ${NEXT_RELEASE_BRANCH}" git checkout -b "${NEXT_RELEASE_BRANCH}" mvn versions:set-scm-tag -DnewTag="HEAD" - mvn versions:set -DnextSnapshot=true -DnextSnapshotIndexToIncrement=2 + mvn versions:set -DnextSnapshot=true -DnextSnapshotIndexToIncrement=1 sed -i "1s/^/## ${NEXT_RELEASE:1} [unreleased]\n\n/" CHANGELOG.md sed -i -e "s/${RELEASE_TAG_NAME:1}<\/version>/${NEXT_RELEASE:1}-SNAPSHOT<\/version>/" examples/pom.xml git add pom.xml examples/pom.xml CHANGELOG.md