Skip to Content
OpenPerf

Getting started

Releases

How versions, changelogs, the npm package and the images come from conventional commits.

release-please reads the conventional commits on main and keeps a release pull request open for each component. Merging that pull request bumps the version, writes CHANGELOG.md, tags the commit, creates a GitHub release and publishes the component.

Components

ComponentPathTagPublishes
openperf.v0.1.0The six service images to GHCR and the Compose bundle to the GitHub release.
sdkpackages/sdksdk-v0.1.0@openperf/sdk to npm.

The two components have their own versions. openperf skips commits that only touch packages/sdk, apps/web-corpsite or .github, so a CI or workflow fix does not release the services. release-please rebuilds each release pull request on every push to main, so it never falls behind main. .release-please-manifest.json holds the last released version of each, and release-please-config.json the rules.

Never edit the versions by hand. The SDK reports the version from packages/sdk/package.json in its telemetry and in openperf --version. The release pull request of openperf also sets the image tags in compose.production.yml, on the lines marked x-release-please-version.

Versions

CommitBump before 1.0.0Bump from 1.0.0
fixpatchpatch
featminorminor
feat! or a BREAKING CHANGE: footerminormajor
docs, chore, refactor and testnonenone

Pull requests are squash-merged, so the pull request title becomes the commit and the changelog entry. Write it for the people who read the changelog.

To force a version, add a Release-As: 0.2.0 footer to a commit in that component.

Changes the SDK bundles

The SDK bundles packages/shared and packages/stacktrace, but release-please assigns a commit to a component by the files it touches. A change there that alters what the SDK does must also touch packages/sdk, usually its test, or the SDK gets no release for it.

What a release runs

.github/workflows/release.yml runs release-please on every push to main. When a release pull request is merged, the same run publishes:

  • sdk: builds and packs the SDK, checks that the packed manifest has the release version and no catalog: or workspace: ranges, installs the tarball in an empty project, imports /node and /browser and runs openperf --version. Then it publishes to npm, under the next tag for a prerelease. With trusted publishing, npm adds provenance on its own once the repository is public.
  • openperf: builds each service on native amd64 and arm64 runners with OPENPERF_VERSION set, with provenance and an SBOM. It tags the multi-platform image as 0.1.0, 0.1 and latest at ghcr.io/opeq-dev/openperf-<service>, then uploads openperf-0.1.0.tar.gz with compose.production.yml and config to the GitHub release.

bun.lock records the version of every workspace package, and release-please does not update it. After release-please opens or updates a release pull request, the sync lockfile job runs bun install --lockfile-only on its branch and commits bun.lock, so main stays in sync after the merge.

Releases are immutable once published: GitHub rejects new assets and a moved tag. So release-please creates each release as a draft with its tag, and the workflow publishes it last: the sdk release after npm, the openperf release after the images and the bundle, marked as the latest release. A release whose publishing failed stays a draft.

If publishing the images or the bundle fails, fix the workflow on main and run release from the Actions tab with the tag, such as v0.1.0. It builds and publishes that tag again without touching npm or the changelog. Re-running the failed jobs would reuse the broken workflow of the release commit.

The release pull requests have no CI checks: GitHub does not start workflows for pull requests opened with GITHUB_TOKEN.

npm access

The publish sdk job runs in the npm environment and publishes through trusted publishing: npm trusts release.yml in this repository and needs no token. The trusted publisher on npmjs.com allows npm publish from release.yml in the npm environment. npm 11.5.1 or later exchanges the job's OIDC token for a short-lived publish token and adds provenance.

Changelog

Changelog gets an entry for every release after the first. When a release is created, release.yml calls .github/workflows/changelog.yml:

  1. It collects the feat, fix and perf pull requests between the previous tag of the component and the new one, with their descriptions. For sdk, it also counts commits in packages/shared and packages/stacktrace.
  2. Claude reads them and adds the entry at the top of changelog.mdx. It may read the repository and edit only that file.
  3. The job checks that only changelog.mdx changed, formats it and builds the site, then opens a docs(web-corpsite): changelog for … pull request.

Edit the entry in that pull request before merging; the pull request description is the source, so a clear description gives a clear entry. The job skips a release whose entry already exists and the first release of a component.

To write an entry again, delete it from changelog.mdx on main and run changelog from the Actions tab with the component and the tag. Turn off publish to print the entry in the log instead of opening a pull request.

The job needs the CLAUDE_CODE_OAUTH_TOKEN secret, from claude setup-token.

On this page