This is an automated email from the ASF dual-hosted git repository.

voonhous pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/hudi.git


The following commit(s) were added to refs/heads/master by this push:
     new e2e3699988e0 fix(release): bump Trino shim dep.hudi.version (#20048)
e2e3699988e0 is described below

commit e2e3699988e04b37913e5612bb0c810d492004e5
Author: voonhous <[email protected]>
AuthorDate: Fri Sep 25 22:54:31 2026 +0800

    fix(release): bump Trino shim dep.hudi.version (#20048)
    
    mvn versions:set does not reach docker/trino/shim/pom.xml: it is
    outside the reactor and its parent is trino-root. The 1.2.1 finalize
    left the shim default at 1.2.1-rc2 and it was fixed by hand.
    
    cut_release_branch.sh now seds the shim next to both versions:set
    calls. The release guide adds the same step plus a git grep check
    after the bug-fix, RC and finalize version bumps.
    
    Closes #20044
---
 release/release_guide.md              | 8 +++++++-
 scripts/release/cut_release_branch.sh | 9 +++++++++
 2 files changed, 16 insertions(+), 1 deletion(-)

diff --git a/release/release_guide.md b/release/release_guide.md
index 2c4c501b6dbc..0aeb368ce7ce 100644
--- a/release/release_guide.md
+++ b/release/release_guide.md
@@ -283,7 +283,7 @@ Here is how to go about a bug fix release.
 
 - Create a branch in your repo (<user>/hudi).
 - Cherry-pick commits from master that needs to be part of this release. (git 
cherry-pick commit-hash). You need to manually resolve the conflicts. For eg, a 
file might have been moved to a diff class in master where as in your release 
branch, it could be in older place. You need to take a call where to place it. 
Similar things like file addition, file deletion, etc.
-- Update the release version by running `mvn versions:set 
-DnewVersion=${RELEASE_VERSION}-rc${RC_NUM}`, with "RELEASE" as the version and 
"RC_NUM" as the RC number.  Make sure the version changes are intended.  Then 
git commit the changes.
+- Update the release version by running `mvn versions:set 
-DnewVersion=${RELEASE_VERSION}-rc${RC_NUM}`, with "RELEASE" as the version and 
"RC_NUM" as the RC number. `versions:set` does not reach 
`docker/trino/shim/pom.xml` (outside the reactor, parent is `trino-root`), so 
also bump its `dep.hudi.version` with `sed -i.bak 
"s#<dep.hudi.version>[^<]*</dep.hudi.version>#<dep.hudi.version>${RELEASE_VERSION}-rc${RC_NUM}</dep.hudi.version>#"
 docker/trino/shim/pom.xml && rm docker/trino/shim/pom [...]
 - Ensure both compilation and tests are good.
 - If apache/hudi is not set as upstream, then add it as upstream: `git remote 
add upstream https://github.com/apache/hudi.git`
 - Once the branch is ready with all commits, go ahead and push your branch to 
upstream.
@@ -375,6 +375,9 @@ Set up a few environment variables to simplify Maven 
commands that follow. This
 1. git checkout ${RELEASE_BRANCH} 
 2. Run mvn version to set the proper rc number in all artifacts 
    1. mvn versions:set -DnewVersion=${RELEASE_VERSION}-rc${RC_NUM}
+   2. `versions:set` does not reach `docker/trino/shim/pom.xml` (outside the 
reactor, parent is `trino-root`). Bump its `dep.hudi.version` by hand:
+      `sed -i.bak 
"s#<dep.hudi.version>[^<]*</dep.hudi.version>#<dep.hudi.version>${RELEASE_VERSION}-rc${RC_NUM}</dep.hudi.version>#"
 docker/trino/shim/pom.xml && rm docker/trino/shim/pom.xml.bak`
+   3. Check that `git grep -n '<old-version>' -- '*pom.xml'` returns nothing.
 3. Run Unit tests  and ensure they succeed 
    1. mvn test -DskipITs=true 
 4. Run Integration Tests and ensure they succeed
@@ -654,6 +657,9 @@ Once the release candidate has been reviewed and approved 
by the community, the
 
 1. Drop all RC orgapachehudi-XXX in [Apache Nexus Staging 
Repositories](https://repository.apache.org/#stagingRepositories).
 2. change the version from ${RELEASE_VERSION}-rc${RC_NUM} to 
${RELEASE_VERSION} against release branch, use command `mvn versions:set 
-DnewVersion=${RELEASE_VERSION}`, e.g. change 0.5.1-rc1 to 0.5.1.
+   1. `versions:set` does not reach `docker/trino/shim/pom.xml`. Bump its 
`dep.hudi.version` by hand:
+      `sed -i.bak 
"s#<dep.hudi.version>[^<]*</dep.hudi.version>#<dep.hudi.version>${RELEASE_VERSION}</dep.hudi.version>#"
 docker/trino/shim/pom.xml && rm docker/trino/shim/pom.xml.bak`
+   2. Check that `git grep -n "${RELEASE_VERSION}-rc" -- '*pom.xml'` returns 
nothing.
 3. Commit and push the version change to release branch.
     1. git commit -am "chore: Update release version to reflect published 
version  ${RELEASE_VERSION}"
    2. git push origin release-${RELEASE_VERSION}
diff --git a/scripts/release/cut_release_branch.sh 
b/scripts/release/cut_release_branch.sh
index 44ed5d7742b7..8570bf8c432a 100755
--- a/scripts/release/cut_release_branch.sh
+++ b/scripts/release/cut_release_branch.sh
@@ -33,6 +33,13 @@ function clean_up(){
   fi
 }
 
+# mvn versions:set does not reach docker/trino/shim/pom.xml (outside the 
reactor,
+# parent is trino-root), so bump its dep.hudi.version default by hand.
+function set_trino_shim_hudi_version(){
+  sed -i.bak 
"s#<dep.hudi.version>[^<]*</dep.hudi.version>#<dep.hudi.version>$1</dep.hudi.version>#"
 docker/trino/shim/pom.xml
+  rm docker/trino/shim/pom.xml.bak
+}
+
 if [[ $# -eq 1 && $1 = "-h" ]]; then
        echo "This script will update apache hudi master branch with next 
release version and cut release branch for current development version."
        echo "There are 3 params required:"
@@ -100,6 +107,7 @@ echo 
"==============================================================="
 
 # Update master branch
 mvn versions:set -DnewVersion=${NEXT_VERSION_IN_BASE_BRANCH}-SNAPSHOT
+set_trino_shim_hudi_version ${NEXT_VERSION_IN_BASE_BRANCH}-SNAPSHOT
 
 echo "===========Update next-version branch as following============="
 git diff
@@ -122,6 +130,7 @@ read confirmation
 # Checkout and update release branch
 git checkout ${RELEASE_BRANCH}
 mvn versions:set -DnewVersion=${RELEASE}-rc${RC_NUM}
+set_trino_shim_hudi_version ${RELEASE}-rc${RC_NUM}
 
 echo "==================Current working branch======================="
 echo ${RELEASE_BRANCH}

Reply via email to