chamikaramj commented on a change in pull request #14239:
URL: https://github.com/apache/beam/pull/14239#discussion_r595703196
##########
File path: website/www/site/content/en/contribute/release-guide.md
##########
@@ -253,10 +253,19 @@ Attention: Only committer has permission to create
release branch in apache/beam
Release candidates are built from a release branch.
As a final step in preparation for the release, you should create the release
branch, push it to the Apache code repository, and update version information
on the original branch.
+The final state of the repository should match this diagram:
-There are 2 ways to cut a release branch: either running automation
script(recommended), or running all commands manually.
+<img src="/images/cut-release-branch.png" alt="Increment minor version on
master branch and set Dataflow container version on release branch"
width="100%">
-After following one of these processes you should manually update `CHANGES.md`
on `master` by adding a new section for the next release.
+- The `master` branch has the SNAPSHOT/dev version incremented.
Review comment:
I assume script already handles this information is just to double check
? (probably good to explicitly mention that for clarity).
##########
File path: release/src/main/scripts/build_release_candidate.sh
##########
@@ -90,6 +91,14 @@ if [[ $confirmation != "y" ]]; then
exit
fi
+RC_TAG="v${RELEASE}-RC${RC_NUM}"
+echo "Pushing tagged commit for RC${RC_NUM}"
+sh $SCRIPT_DIR/set_version.sh ${RELEASE} --release"
Review comment:
So we run this for every RC but with the same state ?
##########
File path: release/src/main/scripts/build_release_candidate.sh
##########
@@ -90,6 +91,14 @@ if [[ $confirmation != "y" ]]; then
exit
fi
+RC_TAG="v${RELEASE}-RC${RC_NUM}"
Review comment:
Let's add a new section header (since this is not a part of "Checking
Environment Variables").
##########
File path: release/src/main/scripts/cut_release_branch.sh
##########
@@ -127,10 +124,6 @@ echo "==================Current working
branch======================="
echo ${RELEASE_BRANCH}
echo "==============================================================="
-sed -i -e "s/${DEV}/${RELEASE}/g" gradle.properties
-sed -i -e "s/${DEV}/${RELEASE}/g" sdks/python/apache_beam/version.py
-sed -i -e "s/${DEV}/${RELEASE}/g" sdks/go/pkg/beam/core/core.go
Review comment:
To clarify, these are set when building the RC now ?
##########
File path: website/www/site/content/en/contribute/release-guide.md
##########
@@ -271,76 +280,12 @@ After following one of these processes you should
manually update `CHANGES.md` o
# Show help page
./beam/release/src/main/scripts/cut_release_branch.sh -h
```
+
* **The script will:**
1. Create release-${RELEASE_VERSION} branch locally.
- 1. Change and commit dev versoin number in master branch:
-
-
[BeamModulePlugin.groovy](https://github.com/apache/beam/blob/e8abafe360e126818fe80ae0f6075e71f0fc227d/buildSrc/src/main/groovy/org/apache/beam/gradle/BeamModulePlugin.groovy#L209),
-
[gradle.properties](https://github.com/apache/beam/blob/e8abafe360e126818fe80ae0f6075e71f0fc227d/gradle.properties#L25),
-
[version.py](https://github.com/apache/beam/blob/e8abafe360e126818fe80ae0f6075e71f0fc227d/sdks/python/apache_beam/version.py#L21)
- 1. Change and commit version number in release branch:
-
-
[version.py](https://github.com/apache/beam/blob/release-2.6.0/sdks/python/apache_beam/version.py#L21),
-
[build.gradle](https://github.com/apache/beam/blob/release-2.6.0/runners/google-cloud-dataflow-java/build.gradle#L39),
-
[gradle.properties](https://github.com/apache/beam/blob/release-2.16.0/gradle.properties#L27)
-
-#### (Alternative) Run all steps manually
-* **Checkout working branch**
-
- Check out the version of the codebase from which you start the release.
- For a new minor or major release, this may be `HEAD` of the `master` branch.
- To build a hotfix/incremental release, instead of the `master` branch, use
the release tag of the release being patched.
- (Please make sure your cloned repository is up-to-date before starting.)
-
- git checkout <master branch OR release tag>
-
- **NOTE**: If you are doing an incremental/hotfix release (e.g. 2.5.1),
please check out the previous release tag, rather than the master branch.
-
-* **Set up environment variables**
-
- Set up a few environment variables to simplify Maven commands that follow.
- (We use `bash` Unix syntax in this guide.)
-
- RELEASE=2.5.0
- NEXT_VERSION_IN_BASE_BRANCH=2.6.0
- BRANCH=release-${RELEASE}
-
- Version represents the release currently underway, while next version
specifies the anticipated next version to be released from that branch.
- Normally, 1.2.0 is followed by 1.3.0, while 1.2.3 is followed by 1.2.4.
-
- **NOTE**: Only if you are doing an incremental/hotfix release (e.g. 2.5.1),
please check out the previous release tag, before running the following
instructions:
-
- BASE_RELEASE=2.5.0
- RELEASE=2.5.1
- NEXT_VERSION_IN_BASE_BRANCH=2.6.0
- git checkout tags/${BASE_RELEASE}
-
-* **Create release branch locally**
-
- git branch ${BRANCH}
-
-* **Update version files in the master branch**
-
- # Now change the version in existing gradle files, and Python files
- sed -i -e "s/'${RELEASE}'/'${NEXT_VERSION_IN_BASE_BRANCH}'/g"
build_rules.gradle
- sed -i -e "s/${RELEASE}/${NEXT_VERSION_IN_BASE_BRANCH}/g"
gradle.properties
- sed -i -e "s/${RELEASE}/${NEXT_VERSION_IN_BASE_BRANCH}/g"
sdks/python/apache_beam/version.py
-
- # Save changes in master branch
- git add gradle.properties build_rules.gradle
sdks/python/apache_beam/version.py
- git commit -m "Moving to ${NEXT_VERSION_IN_BASE_BRANCH}-SNAPSHOT on
master branch."
-
-* **Check out the release branch**
-
- git checkout ${BRANCH}
-
-* **Update version files in release branch**
-
- DEV=${RELEASE}.dev
- sed -i -e "s/${DEV}/${RELEASE}/g" sdks/python/apache_beam/version.py
- sed -i -e "s/${DEV}/${RELEASE}/g" gradle.properties
- sed -i -e "s/'beam-master-.*'/'beam-${RELEASE}'/g"
runners/google-cloud-dataflow-java/build.gradle
-
+ 2. Increment the minor version in the master branch.
Review comment:
I don't think we need to repeat the information already mentioned above
but up to you.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]