Skip to content

Refactor release process to support php-windows-builder#1916

Merged
alcaeus merged 1 commit intomongodb:v1.21from
alcaeus:fix-release-process
Jan 28, 2026
Merged

Refactor release process to support php-windows-builder#1916
alcaeus merged 1 commit intomongodb:v1.21from
alcaeus:fix-release-process

Conversation

@alcaeus
Copy link
Member

@alcaeus alcaeus commented Jan 28, 2026

The GitHub action used to build windows packages runs the actions/checkout action without passing any parameters. This causes issues when the ref being built is not the same as the one that triggered the original workflow run. Our release workflow is triggered with a workflow_dispatch event on the branch we want to release, which then creates a tag from this branch before building packages for the newly created tag. This causes issues when building the tag, as the checkout invoked extension build action switches the checked out ref leading to build issues.

This PR splits the release process into two distinct actions:

  1. Preparing the release: as previously, this is triggered by a workflow_dispatch event and creates the release tag and draft release.
  2. Creating release artifacts: this new workflow is triggered when a new tag is pushed and runs the second part of the release process: running static analysis, creating release packages, and uploading SSDLC assets.

With this change, the package build is done in a workflow that uses the correct ref and ref_name in the github context and environment variables, and should thus avoid the issues we've encountered previously.

Note: due to the nature of release tooling, these changes can only be tested as part of an actual release, and only in this canonical repository as other repository don't have access to the necessary credentials and secrets. As a silver lining, we can quickly iterate since we don't need to wait for CI to complete before merging pull requests.

@alcaeus alcaeus requested a review from GromNaN January 28, 2026 07:55
@alcaeus alcaeus requested a review from a team as a code owner January 28, 2026 07:55
Copilot AI review requested due to automatic review settings January 28, 2026 07:55
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR refactors the release workflow to address issues with the php-windows-builder action by splitting the release process into two separate workflows. The original workflow created a tag and then attempted to build packages for that tag within the same workflow run, causing github.ref context mismatches during checkout operations.

Changes:

  • Split release workflow into preparation (tag/draft creation) and artifact creation (building/publishing)
  • New create-release-artifacts.yml workflow triggered on tag push events
  • Updated create-release-packages.yml to accept dynamic ref parameter

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.

File Description
.github/workflows/release.yml Removed artifact creation jobs (static-analysis, package-release, publish-ssdlc-assets) to focus solely on release preparation
.github/workflows/create-release-packages.yml Changed to use dynamic ref input instead of hardcoded tag reference
.github/workflows/create-release-artifacts.yml New workflow containing artifact creation jobs, triggered on tag push with proper github context

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@alcaeus alcaeus merged commit 16ee2bc into mongodb:v1.21 Jan 28, 2026
45 checks passed
@alcaeus alcaeus deleted the fix-release-process branch January 28, 2026 08:26
This was referenced Jan 28, 2026
netbsd-srcmastr pushed a commit to NetBSD/pkgsrc that referenced this pull request Feb 11, 2026
1.21.1 (2025-06-13)

What's Changed

* PHPC-2558: Update to libmongoc 1.30.3 by @alcaeus in mongodb/mongo-php-driver#1806

* Add CODEOWNERS for 1.21+ by @alcaeus in
  mongodb/mongo-php-driver#1810

* PHPC-2537 Update to newer Ubuntu version in GitHub Actions workflows by
  @GromNaN in mongodb/mongo-php-driver#1814

* PHPLIB-1678: Use assume_role command before accessing secrets by @alcaeus
  in mongodb/mongo-php-driver#1832

* Ignore branches that are no longer maintained when merging up by @alcaeus
  in mongodb/mongo-php-driver#1838

* PHPC-2593: Update libmongoc to 1.30.5 by @alcaeus in
  mongodb/mongo-php-driver#1841


1.21.2 (2025-10-07)

 What's Changed

* Fix wrong PHP version constraint for pie by @alcaeus in
  mongodb/mongo-php-driver#1874

* PHPC-2635: Remove serverless URIs from Atlas connectivity tests by
  @jmikola in mongodb/mongo-php-driver#1879

* PHPC-2637: Update to libmongoc 1.30.6 by @alcaeus in
  mongodb/mongo-php-driver#1882


1.21.3 (seems not be released)


1.21.4 (2026-01-28)

What's Changed

* PHPC-2661: Use php-windows-builder for Windows extension builds by
  @alcaeus in mongodb/mongo-php-driver#1907

* Refactor release process to support php-windows-builder by @alcaeus in
  mongodb/mongo-php-driver#1916

* Fix broken release workflow by @alcaeus in
  mongodb/mongo-php-driver#1919

1.21.5 (2026-02-04)

What's Changed

* Fix artifact signing by @alcaeus in
  mongodb/mongo-php-driver#1923

* PHPC-2670: Upgrade libmongoc to 1.30.7 by @alcaeus in
  mongodb/mongo-php-driver#1930

* PHPC-2636: Respect libbson nesting limit when parsing PHP objects by
  @alcaeus in mongodb/mongo-php-driver#1934
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants