Skip to content

Commit e0d85a2

Browse files
committed
[docs] Update release process documentation for version bump, upgrade notes, and docker images
1 parent def364b commit e0d85a2

File tree

1 file changed

+125
-35
lines changed

1 file changed

+125
-35
lines changed

website/community/how-to-release/creating-a-fluss-release.mdx

Lines changed: 125 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -162,10 +162,12 @@ $ git push origin release-${SHORT_RELEASE_VERSION}
162162

163163

164164

165-
### 8. Bump version for the main branch
165+
### 8. Updates for the main branch
166166

167167
<Tabs groupId="release-tabs">
168168
<TabItem value="major" label="Major release" default>
169+
**(1) Bump version for the main branch**
170+
169171
After creating the release branch, you should bump the version of the main branch to the next version. This is important to ensure that the next development cycle starts with the correct version.
170172

171173
```bash
@@ -175,6 +177,8 @@ tools $ OLD_VERSION=$CURRENT_SNAPSHOT_VERSION NEW_VERSION=$NEXT_SNAPSHOT_VERSION
175177
tools $ git push origin main
176178
```
177179

180+
**(2) Create Upgrade Notes for the next version**
181+
178182
Besides, in the `main` branch, create a new "Upgrade Notes" markdown file for the next version. The file name should be `upgrade-notes-x.y.md` (replace the `x.y` to the next version number, e.g., `0.9`) under path `website/docs/maintenance/operations/` with following initial content.
179183

180184
```
@@ -193,6 +197,29 @@ Commit the documentation changes, and push to the official repository.
193197
```bash
194198
$ git commit -m "[docs] Create upgrade notes for $NEXT_SHORT_VERSION" .
195199
$ git push origin main
200+
```
201+
202+
**(3) Add version item in fluss-versions.json**
203+
204+
Next, add a new version item for the current release version in the `website/fluss-versions.json` file on the `main` branch. The new version item should have the following fields and values (releasing `0.8.0` as an example):
205+
206+
```json
207+
{
208+
"versionName": "version-0.8",
209+
"fullVersion": "0.8.0-incubating",
210+
"shortVersion": "0.8",
211+
"dockerVersion": "0.8.0-incubating-rc1",
212+
"released": false
213+
}
214+
```
215+
216+
Additionally, update the `fullVersion`, `shortVersion`, and `dockerVersion` fields for the `next` version entry to reflect the next release version.
217+
218+
Commit the documentation changes, and push to the official repository.
219+
220+
```bash
221+
$ git commit -m "[docs] Add version item for $RELEASE_VERSION in fluss-versions.json
222+
$ git push origin main
196223
```
197224
</TabItem>
198225
@@ -208,8 +235,27 @@ If you're creating a new bugfix release, you can skip this step.
208235
209236
Create a pull request for the release announcement blog for this version, see the [previous release blogs](https://fluss.apache.org/blog/tags/releases/).
210237
238+
We usually include the commit number and the names of all contributors in the announcement blog post. Use the following command to get the commit number and the list of contributors:
239+
240+
241+
```bash
242+
# first line is required to make sort first with uppercase and then lower
243+
export LC_ALL=C
244+
export FLUSS_PREVIOUS_RELEASE_BRANCH={previousReleaseBranch}
245+
export FLUSS_CURRENT_RELEASE_BRANCH={currentReleaseBranch}
246+
# e.g.
247+
# export FLUSS_PREVIOUS_RELEASE_BRANCH=release-0.7
248+
# export FLUSS_CURRENT_RELEASE_BRANCH=release-0.8
249+
250+
# get contributor list
251+
git log $FLUSS_PREVIOUS_RELEASE_BRANCH..$FLUSS_CURRENT_RELEASE_BRANCH --pretty=format:"%an" | sort -u | paste -sd "," - | sed 's/,/, /g'
252+
# get total number of commits
253+
git log $FLUSS_PREVIOUS_RELEASE_BRANCH...$FLUSS_CURRENT_RELEASE_BRANCH --pretty=oneline | wc -l
254+
```
255+
211256
Besides, Create a pull request to add download links for the release on the Download page `website/src/pages/downloads.md`.
212257
258+
213259
</TabItem>
214260
215261
<TabItem value="bugfix" label="Bugfix release">
@@ -295,21 +341,31 @@ Then, we create the Helm Chart packages:
295341
tools $ RELEASE_VERSION=$RELEASE_VERSION RELEASE_CANDIDATE=$RC_NUM releasing/create_helm_packages.sh
296342
```
297343
298-
This command creates a helm tgz and prov files under `tools/releasing/release/helm-chart` directory like following:
344+
Now, we should already created the source distribution, binary distribution, and Helm Chart packages for the release candidate.
345+
Run the `tree releasing/release/` command under the `tools` directory to verify the created files.
299346
300-
```bash
301-
tools $ tree releasing/release/helm-chart
302-
releasing/release/helm-chart
303-
├── 0.8.0-incubating-rc1
304-
│ ├── fluss-0.8.0-incubating.tgz
305-
│ ├── fluss-0.8.0-incubating.tgz.asc
306-
│ ├── fluss-0.8.0-incubating.tgz.prov
307-
│ ├── fluss-0.8.0-incubating.tgz.prov.asc
308-
│ ├── fluss-0.8.0-incubating.tgz.prov.sha512
309-
│ └── fluss-0.8.0-incubating.tgz.sha512
310-
└── index.yaml
347+
Example output for release version `0.8.0-incubating` and RC number `1`:
311348
312-
2 directories, 7 files
349+
```bash
350+
tools $ tree releasing/release
351+
releasing/release
352+
├── fluss-0.8.0-incubating-bin.tgz
353+
├── fluss-0.8.0-incubating-bin.tgz.asc
354+
├── fluss-0.8.0-incubating-bin.tgz.sha512
355+
├── fluss-0.8.0-incubating-src.tgz
356+
├── fluss-0.8.0-incubating-src.tgz.asc
357+
├── fluss-0.8.0-incubating-src.tgz.sha512
358+
└── helm-chart
359+
├── 0.8.0-incubating-rc1
360+
│ ├── fluss-0.8.0-incubating.tgz
361+
│ ├── fluss-0.8.0-incubating.tgz.asc
362+
│ ├── fluss-0.8.0-incubating.tgz.prov
363+
│ ├── fluss-0.8.0-incubating.tgz.prov.asc
364+
│ ├── fluss-0.8.0-incubating.tgz.prov.sha512
365+
│ └── fluss-0.8.0-incubating.tgz.sha512
366+
└── index.yaml
367+
368+
3 directories, 13 files
313369
```
314370
315371
@@ -335,7 +391,7 @@ tools/target $ mkdir fluss/fluss-${RELEASE_VERSION}-rc${RC_NUM}
335391
(3) Copy fluss source and binary distributions, hashes, and GPG signature:
336392
337393
```bash
338-
tools/target $ mv ../release/fluss-* fluss/fluss-${RELEASE_VERSION}-rc${RC_NUM}
394+
tools/target $ mv ../releasing/release/fluss-* fluss/fluss-${RELEASE_VERSION}-rc${RC_NUM}
339395
```
340396
341397
(4) Make a directory for the new helm packages:
@@ -347,24 +403,42 @@ tools/target $ mkdir -p fluss/helm-chart
347403
(5) Copy fluss helm packages, hashes, and GPG signature:
348404
349405
```bash
350-
tools/target $ mv ../release/helm-chart/* fluss/helm-chart
406+
tools/target $ mv ../releasing/release/helm-chart/* fluss/helm-chart
351407
```
352408
353409
(6) Add and commit all the files.
354410
355411
```bash
356412
tools/target $ cd fluss
357413
tools/target/fluss $ svn add fluss-${RELEASE_VERSION}-rc${RC_NUM}
414+
tools/target/fluss $ svn add helm-chart
358415
tools/target/fluss $ svn commit -m "Add fluss-${RELEASE_VERSION}-rc${RC_NUM}"
359416
```
360417
361418
(7) Verify the files are present: https://dist.apache.org/repos/dist/dev/incubator/fluss/
362419
363420
364-
### 6. Stage Docker images
421+
### 6. Stage maven artifacts
422+
423+
424+
Next, we stage the maven artifacts:
425+
426+
```bash
427+
tools $ releasing/deploy_staging_jars.sh
428+
```
429+
430+
Review all staged artifacts in the staging repositories(https://repository.apache.org/#stagingRepositories). They should contain all relevant parts for each module, including pom.xml, jar, test jar, source, test source, javadoc, etc. Carefully review any new artifacts.
431+
432+
Close the staging repository on Apache Nexus. When prompted for a description, enter `Apache Fluss (Incubating), version X, release candidate Y`. You can find the staging repository URL (`https://repository.apache.org/content/repositories/orgapachefluss-[STAGING_ID]/`) once the staging repository is closed successfully.
433+
434+
![](../assets/nexus-staging.png)
435+
436+
### 7. Stage Docker images
365437
366438
:::note
367439
Make sure that you are authenticated with your Docker ID, and that your Docker ID has access to `apache/fluss`: `docker login -u <username>`. If you do not have access, you should seek help via the dev mailing list.
440+
441+
If you can't login Docker ID in your region because of network issues, you can find a cloud machine that can access Docker Hub, and perform the following steps there.
368442
:::
369443
370444
Next, we need to build and push Docker images for the release candidates. This will enable users to easily test the new functionality using the Quickstart guide in the [Fluss documentation](https://fluss.apache.org/docs/quickstart/flink/) improving accessibility and feedback during the release validation phase.
@@ -373,7 +447,7 @@ From the root directory of the source code, run the following commands to build
373447
374448
```bash
375449
$ rm -rf docker/fluss/build-target/
376-
$ mkdir docker/fluss/build-target/
450+
$ mkdir docker/fluss/build-target/
377451
$ cp -r build-target/* docker/fluss/build-target
378452
379453
$ cd docker/fluss
@@ -388,27 +462,18 @@ docker/quickstart-flink $ ./prepare_build.sh
388462
docker/quickstart-flink $ docker buildx build --push --platform linux/arm64/v8,linux/amd64 --tag apache/fluss-quickstart-flink:1.20-${RELEASE_VERSION}-rc${RC_NUM} .
389463
```
390464
391-
Verify the RC images are present: https://hub.docker.com/r/apache/fluss/tags
392-
393-
### 7. Stage maven artifacts
394-
465+
Verify the RC images are present:
466+
- https://hub.docker.com/r/apache/fluss/tags
467+
- https://hub.docker.com/r/apache/fluss-quickstart-flink/tags
395468
396-
Next, we stage the maven artifacts:
397-
398-
```bash
399-
tools $ releasing/deploy_staging_jars.sh
400-
```
401-
402-
Review all staged artifacts in the staging repositories(https://repository.apache.org/#stagingRepositories). They should contain all relevant parts for each module, including pom.xml, jar, test jar, source, test source, javadoc, etc. Carefully review any new artifacts.
469+
Then, update the `dockerVersion` field for the current release RC version in the `website/fluss-versions.json` file on the `main` branch to the value of `${RELEASE_VERSION}_RC${RC_NUM}` (which includes the RC suffix, e.g., `0.8.0-incubating-rc1`). This update should be committed and pushed to the `main` branch.
403470
404-
Close the staging repository on Apache Nexus. When prompted for a description, enter `Apache Fluss (Incubating), version X, release candidate Y`. You can find the staging repository URL (`https://repository.apache.org/content/repositories/orgapachefluss-[STAGING_ID]/`) once the staging repository is closed successfully.
405-
406-
![](../assets/nexus-staging.png)
471+
This ensures that the **Quickstart guide** in the documentation references the correct Docker image for the release candidate. This will help developers to easily test the new release candidate using the Quickstart guide.
407472
408473
### 8. Push the RC tag
409474
410475
```bash
411-
git push origin refs/tags/{$TAG}
476+
git push origin $TAG
412477
```
413478
414479
-------------
@@ -419,7 +484,7 @@ git push origin refs/tags/{$TAG}
419484
- Maven artifacts deployed to the staging repository of [repository.apache.org](https://repository.apache.org/content/repositories/)
420485
- RC Docker images pushed to [DockerHub](https://hub.docker.com/r/apache/fluss/tags)
421486
- RC tag pushed to the [official repository](https://github.com/apache/fluss/tags)
422-
- TODO: update version.txt in release branch for the RC docker image
487+
- Updated `dockerVersion` in `fluss-versions.json` on `main` branch
423488
424489
425490
## Vote on the release candidate
@@ -617,6 +682,16 @@ Code changes should be proposed as standard pull requests to the `main` branch a
617682
618683
Once all issues have been resolved, you should go back and build a new release candidate with these changes.
619684
685+
Before build a new release candidate, remove the old release candidates from https://dist.apache.org/repos/dist/dev/incubator/fluss using Subversion.
686+
687+
```bash
688+
svn checkout https://dist.apache.org/repos/dist/dev/incubator/fluss --depth=immediates
689+
cd fluss
690+
svn remove fluss-${RELEASE_VERSION}-rc*
691+
svn remove helm-chart
692+
svn commit -m "Remove old release candidates for Apache Fluss ${RELEASE_VERSION}"
693+
```
694+
620695
**Checklist to proceed to the next step**
621696
- Issues identified during vote have been resolved, with fixes committed to the release branch.
622697
@@ -680,7 +755,22 @@ docker tag apache/fluss:${RELEASE_VERSION}_RC${RC_NUM} apache/fluss:${RELEASE_VE
680755
docker push apache/fluss:${RELEASE_VERSION}
681756
```
682757
683-
### 6. Mark the Milestone as released in GitHub
758+
### 6. Update `fluss-versions.json`
759+
760+
Update the `released` field to `true` and `dockerVersion` to `$RELEASE_VERSION` (without the RC number) for the current release version in the `website/fluss-versions.json` file on the `main` branch. This update should be committed and pushed to the `main` branch.
761+
This will refresh the documentation website to reflect that the new version has been officially released.
762+
763+
```json
764+
{
765+
"versionName": "version-0.8",
766+
"fullVersion": "0.8.0-incubating",
767+
"shortVersion": "0.8",
768+
"dockerVersion": "0.8.0-incubating-rc1", // ==> "0.8.0-incubating"
769+
"released": false // ==> true
770+
}
771+
```
772+
773+
### 7. Mark the Milestone as released in GitHub
684774
685775
In [GitHub Milestones](https://github.com/apache/fluss/milestones), mark the current release milestone as close.
686776

0 commit comments

Comments
 (0)