Skip to content

ci: run the queue-storage prune suite against AlloyDB Omni#446

Open
hardbyte wants to merge 1 commit into
mainfrom
ci/alloydb-omni-regression
Open

ci: run the queue-storage prune suite against AlloyDB Omni#446
hardbyte wants to merge 1 commit into
mainfrom
ci/alloydb-omni-regression

Conversation

@hardbyte

@hardbyte hardbyte commented Jul 22, 2026

Copy link
Copy Markdown
Owner

Adds a rust-test-alloydb-omni CI job that runs the queue-storage prune suite (including test_maintenance_idle_prune_replaces_child_filenode_once) against AlloyDB Omni 18.3, so the idle-prune behaviour is guarded on a disaggregated-storage engine and not only on vanilla Postgres.

Context: awa reclaims ring slots via ACCESS EXCLUSIVE + TRUNCATE, whose relfilenode churn is ~2–6× costlier on AlloyDB's storage engine than on stock PG (single-container Omni reproduces the engine cost; managed adds regional-storage round-trips on top). A regression where an idle ring re-truncated empty slots every maintenance tick saturated AlloyDB IO in production. This forward-ports the Omni CI coverage that shipped with the v0.6.4 hotfix so future versions keep it.

Omni runs as a plain Postgres service (no columnar preload needed — the tests assert logical prune behaviour, not columnar performance). Gated behind the full-ci label like the other heavy Rust test jobs.

Summary by CodeRabbit

  • Tests
    • Expanded automated validation for Rust-based queue storage functionality.
    • Added coverage against AlloyDB Omni running PostgreSQL 18 to help detect compatibility and pruning issues earlier.
    • Extended full CI checks while keeping standard pull request runs efficient.

awa reclaims ring slots with ACCESS EXCLUSIVE + TRUNCATE, whose relfilenode churn is far costlier on AlloyDB's storage engine than on stock Postgres. A regression there (an idle ring re-truncating empty slots every maintenance tick) saturated AlloyDB IO in production. Add a CI job that runs the prune suite on AlloyDB Omni 18.3 so the idle-skip behaviour is guarded on the engine where it bit, not only on vanilla Postgres.
@hardbyte hardbyte added the full-ci Run the full CI matrix (Python build+test, E2E) on this PR label Jul 22, 2026
@coderabbitai

coderabbitai Bot commented Jul 22, 2026

Copy link
Copy Markdown

Review Change Stack

📝 Walkthrough

Walkthrough

Adds a gated rust-test-alloydb-omni CI job that provisions AlloyDB Omni PG 18, waits for readiness, and runs queue storage prune tests with AlloyDB-specific environment variables.

Changes

AlloyDB Omni CI coverage

Layer / File(s) Summary
AlloyDB Omni prune test job
.github/workflows/ci.yml
Adds the AlloyDB Omni service, readiness checks, rust-build dependency, conditional full-ci gating, and the configured Rust prune test command.

Estimated code review effort: 2 (Simple) | ~10 minutes

Poem

I’m a bunny in CI, hopping with care,
AlloyDB Omni is waiting there.
PG 18 wakes, the prune tests run,
With queue storage joining the fun.
Green little checks through the pipeline race—
A carrot for every passing case!

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately summarizes the new CI job running the queue-storage prune suite against AlloyDB Omni.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

Warning

There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure.

🔧 Checkov (3.3.8)
.github/workflows/ci.yml

Traceback (most recent call last):
File "/usr/local/bin/checkov", line 2, in
from checkov.main import Checkov
ModuleNotFoundError: No module named 'checkov'


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: eef35c8cd4

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread .github/workflows/ci.yml
timeout-minutes: 30
services:
alloydb:
image: gcr.io/alloydb-omni/alloydbomni:18.3

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P1 Badge Authenticate the AlloyDB Omni image

This service image is pulled anonymously by GitHub before any job steps run, but AlloyDB Omni's PostgreSQL 18 images are access-gated (Google's Docker Hub page says PG18 access requires registration: https://hub.docker.com/r/google/alloydbomni, and the 18.3 install docs say to use the image URI provided after requesting access). Since this workflow has no service-container credentials or prior registry login, main/full-ci runs will fail while starting the service instead of running the prune suite; use a public tag or add authenticated registry credentials for the provided image URI.

Useful? React with 👍 / 👎.

@hardbyte hardbyte closed this Jul 22, 2026
@hardbyte hardbyte reopened this Jul 22, 2026

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🧹 Nitpick comments (1)
.github/workflows/ci.yml (1)

160-160: 🔒 Security & Privacy | 🔵 Trivial | ⚡ Quick win

Pin the AlloyDB Omni image to an immutable release.

Line [160] uses the floating 18.3 tag. Pin the verified 18.3.0 image digest so future registry changes cannot silently alter what this CI job validates. Google’s container documentation uses the complete 18.3.0 version. (docs.cloud.google.com)

Suggested change
-        image: gcr.io/alloydb-omni/alloydbomni:18.3
+        image: gcr.io/alloydb-omni/alloydbomni@sha256:<verified-18.3.0-digest>
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In @.github/workflows/ci.yml at line 160, Update the AlloyDB Omni image
reference in the workflow service configuration from the floating 18.3 tag to
the verified immutable 18.3.0 image digest, preserving the existing image and CI
job setup.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In @.github/workflows/ci.yml:
- Line 172: Update the actions/checkout@v6 step to set persist-credentials to
false, ensuring checkout credentials are not retained for subsequent workflow
steps.

---

Nitpick comments:
In @.github/workflows/ci.yml:
- Line 160: Update the AlloyDB Omni image reference in the workflow service
configuration from the floating 18.3 tag to the verified immutable 18.3.0 image
digest, preserving the existing image and CI job setup.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 5bf1f94d-e234-4a3c-938d-9c6ebf37fa2d

📥 Commits

Reviewing files that changed from the base of the PR and between 02ce599 and eef35c8.

📒 Files selected for processing (1)
  • .github/workflows/ci.yml

Comment thread .github/workflows/ci.yml
--health-timeout 5s
--health-retries 40
steps:
- uses: actions/checkout@v6

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🔒 Security & Privacy | 🟠 Major | ⚡ Quick win

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
set -euo pipefail

echo "== workflow files =="
git ls-files .github/workflows || true

echo "== ci.yml around checkout area =="
if [ -f .github/workflows/ci.yml ]; then
  nl -ba .github/workflows/ci.yml | sed -n '130,210p'
fi

echo "== occurrences of checkout in workflows =="
rg -n "actions/checkout|persist-credentials|cargo test|cargo|push|url|fetch" .github/workflows || true

Repository: hardbyte/awa

Length of output: 142


🌐 Web query:

actions/checkout persist-credentials default true README

💡 Result:

In the actions/checkout GitHub Action, the persist-credentials input parameter defaults to true [1][2]. This setting configures the local git configuration with the authentication token or SSH key used for the checkout [3][2]. When enabled, this allows subsequent steps in the workflow job to execute authenticated git commands (e.g., git push) automatically [3][4]. The token is removed by the action during post-job cleanup [3][5]. Security context and updates: - While the default remains true, security improvements have been implemented. In v6.0.0 and later, the action was updated to store these credentials in a separate file located in $RUNNER_TEMP rather than writing them directly into the.git/config file, which enhances security [6][7]. - Users concerned about this behavior can opt out by explicitly setting persist-credentials: false in their workflow configuration [3][2]. - There has been community discussion regarding whether the default should be false due to security concerns, but the default value has remained true across major versions [8][9].

Citations:


🏁 Script executed:

#!/bin/bash
set -euo pipefail

echo "== workflow files =="
git ls-files .github/workflows

echo "== ci.yml around checkout area =="
if [ -f .github/workflows/ci.yml ]; then
  nl -ba .github/workflows/ci.yml | sed -n '130,215p'
fi

echo "== occurrences of checkout and related commands in workflows =="
rg -n "actions/checkout|persist-credentials|cargo test|cargo|git push|git fetch|git fetch-pack|git clone|url|fetch" .github/workflows || true

Repository: hardbyte/awa

Length of output: 142


🌐 Web query:

actions/checkout v6 persist-credentials default true action.yml

💡 Result:

In actions/checkout v6, the persist-credentials input defaults to true [1][2][3]. This input controls whether the authentication token (or SSH key) used for the checkout is configured in the local git configuration [1][3]. When set to true (the default), this enables subsequent scripts and commands in the workflow to run authenticated git operations (such as git fetch or git push) [1][2]. The credentials are removed during post-job cleanup [1][4]. Starting with v6, the implementation was updated to improve credential security by storing these credentials in a separate file under $RUNNER_TEMP instead of directly in.git/config, though this does not change the default behavior or the requirement for users to explicitly set persist-credentials: false if they wish to opt out [1][2][5].

Citations:


🌐 Web query:

github actions checkout persist-credentials false security

💡 Result:

The persist-credentials input in the actions/checkout GitHub Action controls whether the action configures the local Git environment with the repository's access token or SSH key [1][2]. By default, this value is set to true [1][3]. When enabled, the action stores credentials so that subsequent scripts in the workflow can execute authenticated Git commands (such as git push or git fetch) without needing additional configuration [1][2]. Security Considerations: 1. Risk of Exposure: Historically, enabling persist-credentials caused the authentication token to be written directly into the local.git/config file [1][4]. This created risks, as the token could potentially be leaked if the repository contents were archived, uploaded as artifacts, or accessed by other third-party actions/steps running in the same job [5][6][4]. 2. Improved Security Mechanisms: In more recent versions of actions/checkout, the implementation has been updated to store credentials in a separate, more secure location under $RUNNER_TEMP rather than directly in.git/config [1][2]. This mitigates some risks related to accidental leakage, such as via artifact uploads [7][2]. 3. Recommended Practice: For workflows that do not require the action to push or perform authenticated Git operations, it is considered a security best practice to set persist-credentials: false [6][4]. This follows the principle of least privilege by ensuring that credentials are not unnecessarily available to other steps or processes in the runner [6]. Usage Example: To disable the persistence of credentials, use the following configuration in your workflow file [6][4]: - uses: actions/checkout@v4 with: persist-credentials: false If you use this setting, any subsequent step that requires authentication (e.g., git push) will fail unless you provide alternative authentication methods [1][2].

Citations:


Disable checkout credential persistence.

Line 172 uses actions/checkout@v6 without persist-credentials; that input defaults to true, leaving credentials available to later steps in the workflow. Since this checkout does not need authenticated Git operations afterwards, set it to false.

Suggested change
       - uses: actions/checkout@v6
+        with:
+          persist-credentials: false
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
- uses: actions/checkout@v6
- uses: actions/checkout@v6
with:
persist-credentials: false
🧰 Tools
🪛 zizmor (1.26.1)

[warning] 172-172: credential persistence through GitHub Actions artifacts (artipacked): does not set persist-credentials: false

(artipacked)

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In @.github/workflows/ci.yml at line 172, Update the actions/checkout@v6 step to
set persist-credentials to false, ensuring checkout credentials are not retained
for subsequent workflow steps.

Source: Linters/SAST tools

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

full-ci Run the full CI matrix (Python build+test, E2E) on this PR

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant