From dac5c1a6b29dbe17cec533611e95fe6bacd83869 Mon Sep 17 00:00:00 2001 From: Twisha Bansal <58483338+twishabansal@users.noreply.github.com> Date: Fri, 17 Oct 2025 16:28:25 +0530 Subject: [PATCH 1/4] docs: include mirror changelog info in developer docs --- DEVELOPER.md | 35 ++++++++++++++++++++++++++++++++++- 1 file changed, 34 insertions(+), 1 deletion(-) diff --git a/DEVELOPER.md b/DEVELOPER.md index f8b2b98..fed9f04 100644 --- a/DEVELOPER.md +++ b/DEVELOPER.md @@ -98,7 +98,40 @@ The primary maintainers for this repository are defined in the ### Releasing -The release process is automated using `release-please`. +The release process is automated using `release-please`. It consists of an automated changelog preparation step followed by the manual merging of a Release PR. + +#### Automated Changelog Enrichment + +Before a Release PR is even created, a special workflow automatically mirrors relevant changelogs from the core `googleapis/genai-toolbox` dependency. This ensures that the release notes for this extension accurately reflect important upstream changes. + +The process is handled by the [`mirror-changelog.yml`](.github/workflows/mirror-changelog.yml) workflow: + +1. **Trigger:** The workflow runs automatically on pull requests created by + Renovate for `toolbox` version updates. +2. **Parsing:** It reads the detailed release notes that Renovate includes in + the PR body. +3. **Filtering:** A Node.js script located at + [`.github/scripts/mirror-changelog.js`](.github/scripts/mirror-changelog.js) + filters these release notes to include only changes relevant to this + extension. The relevance is determined by a keyword (e.g., `alloydb`), passed + as an environment variable in the workflow file. +4. **Changelog Injection:** The script formats the filtered entries as + conventional commits and injects them into the PR body within a + `BEGIN_COMMIT_OVERRIDE` block. +5. **Release Please:** When the main Release PR is created, `release-please` + reads this override block instead of the standard `chore(deps): ...` commit + message, effectively mirroring the filtered upstream changelog into this + project's release notes. + +> **Note for Maintainers:** The filtering script is an automation aid, but it +> may occasionally produce "false positives" (e.g., an internal logging change +> that happens to contain the keyword). Before merging a `toolbox` dependency +> PR, maintainers must **review the generated `BEGIN_COMMIT_OVERRIDE` block** +> and manually delete any lines that are not relevant to the end-users of this +> extension. The curated override block is the final source of truth for the +> release changelog. + +#### Release Process 1. **Release PR:** When commits with conventional commit headers (e.g., `feat:`, `fix:`) are merged into the `main` branch, `release-please` will From 19d073cdbffaa156d48ebbcd590e33e4f40fab03 Mon Sep 17 00:00:00 2001 From: Twisha Bansal <58483338+twishabansal@users.noreply.github.com> Date: Fri, 17 Oct 2025 16:29:15 +0530 Subject: [PATCH 2/4] Update DEVELOPER.md --- DEVELOPER.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/DEVELOPER.md b/DEVELOPER.md index fed9f04..f5b3506 100644 --- a/DEVELOPER.md +++ b/DEVELOPER.md @@ -113,7 +113,7 @@ The process is handled by the [`mirror-changelog.yml`](.github/workflows/mirror- 3. **Filtering:** A Node.js script located at [`.github/scripts/mirror-changelog.js`](.github/scripts/mirror-changelog.js) filters these release notes to include only changes relevant to this - extension. The relevance is determined by a keyword (e.g., `alloydb`), passed + extension. The relevance is determined by a keyword (e.g., `postgres`), passed as an environment variable in the workflow file. 4. **Changelog Injection:** The script formats the filtered entries as conventional commits and injects them into the PR body within a From d54d95a858c958c7f05070062d8e15bc04151203 Mon Sep 17 00:00:00 2001 From: Averi Kitsch Date: Fri, 17 Oct 2025 10:17:11 -0700 Subject: [PATCH 3/4] Apply suggestion from @averikitsch --- DEVELOPER.md | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/DEVELOPER.md b/DEVELOPER.md index f5b3506..3c82389 100644 --- a/DEVELOPER.md +++ b/DEVELOPER.md @@ -110,10 +110,8 @@ The process is handled by the [`mirror-changelog.yml`](.github/workflows/mirror- Renovate for `toolbox` version updates. 2. **Parsing:** It reads the detailed release notes that Renovate includes in the PR body. -3. **Filtering:** A Node.js script located at - [`.github/scripts/mirror-changelog.js`](.github/scripts/mirror-changelog.js) - filters these release notes to include only changes relevant to this - extension. The relevance is determined by a keyword (e.g., `postgres`), passed +3. **Filtering:** These release notes are filtered to include only changes + relevant to this extension. The relevance is determined by a keyword (e.g., `postgres`), passed as an environment variable in the workflow file. 4. **Changelog Injection:** The script formats the filtered entries as conventional commits and injects them into the PR body within a From ec8a8459e2328884237dd4f7476be366776cc82a Mon Sep 17 00:00:00 2001 From: Twisha Bansal <58483338+twishabansal@users.noreply.github.com> Date: Fri, 17 Oct 2025 22:55:28 +0530 Subject: [PATCH 4/4] Update DEVELOPER.md --- DEVELOPER.md | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/DEVELOPER.md b/DEVELOPER.md index 3c82389..b4ba19a 100644 --- a/DEVELOPER.md +++ b/DEVELOPER.md @@ -102,7 +102,10 @@ The release process is automated using `release-please`. It consists of an autom #### Automated Changelog Enrichment -Before a Release PR is even created, a special workflow automatically mirrors relevant changelogs from the core `googleapis/genai-toolbox` dependency. This ensures that the release notes for this extension accurately reflect important upstream changes. +Before a Release PR is even created, a special workflow automatically mirrors +relevant changelogs from the core `googleapis/genai-toolbox` dependency. This +ensures that the release notes for this extension accurately reflect important +upstream changes. The process is handled by the [`mirror-changelog.yml`](.github/workflows/mirror-changelog.yml) workflow: @@ -111,8 +114,8 @@ The process is handled by the [`mirror-changelog.yml`](.github/workflows/mirror- 2. **Parsing:** It reads the detailed release notes that Renovate includes in the PR body. 3. **Filtering:** These release notes are filtered to include only changes - relevant to this extension. The relevance is determined by a keyword (e.g., `postgres`), passed - as an environment variable in the workflow file. + relevant to this extension. The relevance is determined by a keyword (e.g., + `postgres`), passed as an environment variable in the workflow file. 4. **Changelog Injection:** The script formats the filtered entries as conventional commits and injects them into the PR body within a `BEGIN_COMMIT_OVERRIDE` block.