This repository has been archived by the owner on Jan 24, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 138
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
ff23b57
commit 469314c
Showing
6 changed files
with
72 additions
and
13 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -21,14 +21,16 @@ There has two type of the tags, one is stable `vX.Y.Z(.M)`, and another is unsta | |
3. Update the project version and tag | ||
4. Build the artifacts | ||
5. Verify the artifacts | ||
6. Move master branch to the next version | ||
6. Release the artifacts using streamnative-ci | ||
7. Write release notes | ||
8. Overwrite the branch | ||
9. Move master branch to the next version | ||
|
||
## Steps in detail | ||
|
||
1. Prepare for a release | ||
|
||
Create a new milestone and move the pull requests that can not be published in this release to the new milestone. | ||
Create a new milestone and move the pull requests that can not be published in this release to the new milestone. | ||
|
||
2. Create the release branch | ||
|
||
|
@@ -40,10 +42,9 @@ There has two type of the tags, one is stable `vX.Y.Z(.M)`, and another is unsta | |
|
||
3. Update the project version and tag | ||
|
||
> If the dependency of Apache Pulsar needs to change, i.e. the project version was from `X1.Y1.Z1.M` to `X2.Y2.Z2.0`, you should change the dependency of Apache Pulsar first. | ||
```bash | ||
$ ./scripts/set-project-version.sh X.Y.Z.M | ||
$ ./scripts/set-pulsar-version.sh X.Y.Z.M | ||
$ git commit -m "Release X.Y.Z.M" -a | ||
$ git push origin branch-X.Y.Z | ||
$ git tag vX.Y.Z.M | ||
|
@@ -71,12 +72,19 @@ There has two type of the tags, one is stable `vX.Y.Z(.M)`, and another is unsta | |
|
||
Then you should push a PR to merge `branch-X.Y.Z` to `master` for running CI tests using Github Actions. | ||
|
||
6. Move master branch to the next version | ||
If the verification failed, which may be caused by the incompatibility with new Pulsar version, we need to add more commits to fix it. | ||
|
||
6. Release the artifacts using streamnative-ci | ||
|
||
After the PR being merged to `master`, you can use streamnative-ci to release the artifacts. | ||
|
||
```bash | ||
$ git checkout master | ||
$ ./scripts/set-project-version.sh X.Y.Z-SNAPSHOT | ||
$ git commit -m 'Bumped version to X.Y.Z-SNAPSHOT' -a | ||
$ git clone https://github.com/streamnative/streamnative-ci.git | ||
$ cd streamnative-ci | ||
$ git checkout release | ||
$ git commit --allow-empty -m "/snbot release kop X.Y.Z.M" | ||
$ git push origin release | ||
# Then, you can see the release process: https://github.com/streamnative/streamnative-ci/actions | ||
``` | ||
|
||
7. Write release notes | ||
|
@@ -87,3 +95,24 @@ There has two type of the tags, one is stable `vX.Y.Z(.M)`, and another is unsta | |
|
||
- Feature | ||
- Bug fixed | ||
|
||
8. Overwrite the branch | ||
|
||
Because the PR may contain multiple commits that will be squashed to a single commit, we need to overwrite the branch after the release. | ||
|
||
```bash | ||
$ git clone [email protected]:streamnative/kop.git | ||
$ cd kop | ||
$ git checkout -b branch-X.Y.Z | ||
$ git push origin branch-X.Y.Z -f | ||
``` | ||
|
||
9. Move master branch to the next version | ||
|
||
```bash | ||
$ git checkout -b bump-master | ||
$ ./scripts/set-project-version.sh X.Y.Z-SNAPSHOT | ||
$ git commit -m 'Bumped version to X.Y.Z-SNAPSHOT' -a | ||
$ git push origin bump-master | ||
# create a PR for this change | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
#!/bin/bash | ||
# | ||
# Licensed under the Apache License, Version 2.0 (the "License"); | ||
# you may not use this file except in compliance with the License. | ||
# You may obtain a copy of the License at | ||
# | ||
# http://www.apache.org/licenses/LICENSE-2.0 | ||
# | ||
# Unless required by applicable law or agreed to in writing, software | ||
# distributed under the License is distributed on an "AS IS" BASIS, | ||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
# See the License for the specific language governing permissions and | ||
# limitations under the License. | ||
# | ||
|
||
set -e | ||
|
||
if [ $# -eq 0 ]; then | ||
echo "Required argument with new pulsar version" | ||
exit 1 | ||
fi | ||
|
||
NEW_VERSION=$1 | ||
|
||
# Go to top level project directory | ||
pushd $(dirname "$0")/.. | ||
|
||
mvn versions:set-property -Dproperty=pulsar.version -DnewVersion=$NEW_VERSION | ||
|
||
popd |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters