Skip to content

Commit f967b73

Browse files
authored
Merge pull request #6120 from IntersectMBO/nm/releasing-improvements
Improve `RELEASE.md`
2 parents d0dcd9b + ec2a582 commit f967b73

File tree

2 files changed

+55
-30
lines changed

2 files changed

+55
-30
lines changed

RELEASE.md

+47-24
Original file line numberDiff line numberDiff line change
@@ -2,30 +2,39 @@
22

33
The release team is made up of the following:
44

5-
* Rotating release engineer from one of the development teams
6-
* SRE team supporting deployment and CI/CD
7-
* Test Engineers that focus on integration tests
8-
* Performance Engineers running benchmarking tests
5+
* *Release Squad Lead* (usually Cardano Head of Product)
6+
* *Rotating Release Engineer* from one of the development teams
7+
* *SRE Team* supporting deployment and CI/CD
8+
* *Test Engineers* that focus on integration tests
9+
* *Performance Engineers* running benchmarking tests
10+
* *Dev Leads* for each of the components of the node
911

1012
# Release Process
1113

1214
This is the release process for node releases
1315

14-
1. Release Squad Lead will work with rotating engineer and dev leads to determine where to cut the releases from ledger, network and node. These will be published via CHaP and will follow the defined process of the team for versioning, etc...
16+
1. Release Squad Lead will work with Release Engineer and Dev Leads to determine where to cut the releases from ledger,
17+
network and node. These will be published via CHaP and will follow the defined process of the team for versioning, etc...
1518
2. These will be integrated up the stack to the node to produce a release branch
16-
3. Release Squad Lead will work with Test/Performance sub-teams to initiate a testing round. This may be a tagged release, a commit based off of master, or a commit
17-
based off of a previously released version as a hotfix
19+
3. Release Engineer will work with Test/Performance sub-teams to initiate a testing round.
20+
This may use a tagged release, a commit taken from master,
21+
or a hotfix branch based on a previously released version.
1822
4. A release candidate will be deployed to preview/preprod by SRE
1923
5. Community will be notified of release candidate and given a few days to provide feedback
20-
6. Release Squad Lead will draft Release notes
21-
7. Head of Engineering will meet with release team and identify if release should be published as stable or beta (pre-release) in GitHub. Stable releases can go all the way to mainnet, beta should only go to preprod and wait for that release to be relabeled as stable or a new stable release to be cut.
22-
8. Release is published
24+
6. Release Engineer will create a draft GitHub Release containing an empty template for the notes
25+
7. Release Engineer will ask Dev Leads to fill out their section of the high-level changelog in the release notes
26+
8. Release Squad Lead will finalize the Release notes
27+
9. Head of Engineering will meet with release team and identify if release should be published as stable or beta (pre-release)
28+
in GitHub.
29+
Stable releases can go all the way to mainnet, beta should only go to preprod and wait for that release to be relabeled as stable or a new stable release to be cut.
30+
10. GitHub release is published
2331

2432
# Rotating Release Engineer Role
2533

26-
All sprints are aligned across the node and it's components. At the end of a sprint cycle the new rotating release engineer is decided on by the leadership team.
34+
All sprints are aligned across the node and it's components. At the end of a sprint cycle the new rotating Release Engineer is decided on by the leadership team.
2735
This person's primary duties are integration of new releases of dependencies up the stack to the node. They serve this role until the release is finalized
2836
according to the above release process (ideally 1 sprint cycle).
37+
The Release Engineer works with the Dev Leads to decide which changes should be included in their component, including any in-flight PRs that haven't been merged yet.
2938

3039
## Sub-Teams
3140

@@ -36,7 +45,7 @@ testnets, public testnets and production systems. They are responsible for updat
3645

3746
### DevX (Developer Experience)
3847

39-
The DevX team is responsible for CI/CD, the building process (using nix and compiling manually), OCI images (e.g. docker containers), systemd services
48+
The DevX team is responsible for CI/CD, the building process (using nix and compiling manually), OCI images (e.g. docker containers), systemd services,
4049
and helper scripts associated in running the node for local development and remote deployment purposes.
4150

4251
### Test Engineers
@@ -61,6 +70,8 @@ Not all releases are declared stable. Releases that aren't stable will be releas
6170
for running on production networks. The same version can be re-released without the pre tag without making any code changes by submitting a new tag without the
6271
`pre` suffix. This means stable could jump from `8.0.0 -> 8.3.0` without ever releasing `8.1.0`, `8.1.1`, `8.2.0`, etc...
6372

73+
Note that the version always has three parts, so a major release has a trailing `.0`.
74+
6475
# Collaboration
6576

6677
The release team meets for a quick touch-point weekly where all team leads are invited. Currently these calls are closed to the public, but in the future we expect
@@ -72,25 +83,37 @@ The release notes are drafted and published via the GitHub releases UI.
7283
Our current template contains the following sections.
7384

7485
- (no header) A very-high level summary of the release.
75-
For larger release, it may be best for the Cardano Head of Product to draft this summary instead of the release engineer, since they have more context.
86+
For a larger release, it may be best for the Cardano Head of Product to draft this summary instead of the Release Engineer, since they have more context.
7687
- Known Issues
7788
- Technical Specification (usually unchanged)
7889
- Links to `cardano-node` documentation
7990
It seems to be a judgement call whether each of these should specify the upstream version.
8091
- Changelogs
81-
- Summaries of the major dependencies' changelogs.
82-
These are written as a few sentences that an interested user and/or dev would find helpful.
83-
It may be best for the individual teams to draft these summaries instead of the release engineer, since they have more context.
84-
- Links to the individual changelog of each upstream package that IOG maintains.
85-
See the script explained below.
92+
+ Summaries of the major dependencies' changelogs.
93+
These are written as a few sentences that an interested user and/or dev would find helpful.
94+
It may be best for the individual teams to draft these summaries instead of the Release Engineer, since they have more context.
95+
+ Links to the individual changelog of each upstream package that IOG maintains.
96+
See the script explained below.
97+
98+
Usually the release notes from the previous release are copied and used as a template.
8699

87100
## Detailed changelog table
88101

89102
There's a script (`scripts/generate-release-changelog-links.hs`) that generates a table of changelogs for each of the package versions included in a given `cardano-node` release. The script takes a cabal-generated `plan.json` and a GitHub API access token, and outputs a large table which contains links to the `CHANGELOG.md` file (if one exists) for each of the package versions contained in the build plan.
90103

91-
> example usage (be sure to run `cabal build all` at least once beforehand):
92-
> ```
93-
> $ nix build .#project.x86_64-linux.plan-nix.json
94-
> $ ./scripts/generate-release-changelog-links.hs result-json $GITHUB_API_TOKEN
95-
> ```
96-
> for more information, including how to generate / retrieve a GitHub API token, use `./scripts/generate-release-changelog-links.hs --help`
104+
Example usage:
105+
106+
```shellsession
107+
$ nix build .#project.x86_64-linux.plan-nix.json
108+
...
109+
$ scripts/generate-release-changelog-links.hs -- -o links.md result-json $GITHUB_API_TOKEN
110+
...
111+
```
112+
113+
For more information, including how to generate / retrieve a GitHub API token, use
114+
115+
```
116+
scripts/generate-release-changelog-links.hs -- --help
117+
```
118+
119+
Note that this is a cabal script and may take a while to build all the dependencies. You will need to have the `zlib` native library available, either installed via your OS package manager or by using `nix-shell -p zlib`.

scripts/generate-release-changelog-links.hs

+8-6
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
#!/usr/bin/env -S cabal run --verbose=1 --index-state=2024-04-09T14:49:48Z
1+
#!/usr/bin/env -S cabal --verbose=1 --index-state=2024-04-09T14:49:48Z run --
22
{- cabal:
33
build-depends:
44
base,
@@ -47,6 +47,7 @@ import Data.Map.Strict (Map)
4747
import qualified Data.Map.Strict as Map
4848
import Data.Maybe
4949
import qualified Data.Text as Text
50+
import qualified Data.Text.IO as Text
5051
import qualified Data.Text.Encoding as Text
5152
import Data.Version
5253
import qualified GitHub
@@ -65,10 +66,11 @@ import Turtle
6566
main :: IO ()
6667
main = sh do
6768

68-
(planJsonFilePath, gitHubAccessToken) <-
69-
options generateReleaseChangelogLinksDescription do
70-
(,) <$> argPath "plan_json_path" "Path of the plan.json file"
71-
<*> fmap (GitHubAccessToken . Text.encodeUtf8) (argText "github_access_token" "GitHub personal access token")
69+
(outputPath, planJsonFilePath, gitHubAccessToken) <-
70+
options generateReleaseChangelogLinksDescription $
71+
(,,) <$> optPath "output" 'o' "Write the generated links to OUTPUT"
72+
<*> argPath "plan_json_path" "Path of the plan.json file"
73+
<*> fmap (GitHubAccessToken . Text.encodeUtf8) (argText "github_access_token" "GitHub personal access token")
7274

7375
packagesMap <- getCHaPPackagesMap
7476

@@ -97,7 +99,7 @@ main = sh do
9799
case pandocOutput of
98100
Left pandocError -> die $
99101
"Failed to render markdown with error " <> Pandoc.renderError pandocError
100-
Right res -> printf (s%"\n") res
102+
Right res -> liftIO . Text.writeFile outputPath $ format (s%"\n") res
101103

102104
generateReleaseChangelogLinksDescription :: Description
103105
generateReleaseChangelogLinksDescription = Description $

0 commit comments

Comments
 (0)