Skip to content

adds user-billing - #267

Open
bwalsh wants to merge 2 commits into
feature/optimizefrom
feature/user-billing
Open

bwalsh wants to merge 2 commits into
feature/optimizefrom
feature/user-billing

Conversation

@bwalsh

@bwalsh bwalsh commented Oct 14, 2026

Copy link
Copy Markdown
Contributor

Propagate requester billing project to Terra DRS Hub

Description

  • Enable requester-pays GCS downloads through Terra DRS Hub by reading GOOGLE_PROJECT for each resolution request and sending its trimmed, non-empty value as userProject. The returned signed access URL is used unchanged, preserving its billing parameter and signature.

  • Document the configuration and extend resolver and integration coverage for billing-project propagation, omission of empty values, signed-URL integrity, and successful downloads. Also update the Docker Syfon E2E test to verify unknown-checksum add-url objects can be pulled, and make Syfon test-process shutdown detection more reliable.

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 14, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-14T22:47:05.754982Z 93e5607 PR opened
ℹ️ 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" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@bwalsh

bwalsh commented Oct 14, 2026

Copy link
Copy Markdown
Contributor Author

Failure analysis

What was failing

The Syfon Docker E2E (add-url) job failed when pulling an object created with git drs add-url without a known SHA-256. The push registered its metadata, but the subsequent pull could not find a DRS record for the placeholder OID.

Why it failed

The placeholder OID is 64 hexadecimal characters, so Syfon treated it as a SHA-256 lookup. But the record stores it as a git-drs-placeholder checksum, not a real SHA-256. The normal SHA-256 lookup therefore returned no match.

How it was fixed

Placeholder records now use a non-SHA-shaped checksum value (git-drs-placeholder/), keeping synthetic OIDs out of Syfon’s SHA-256 index. When a normal checksum lookup misses, git-drs retries with that placeholder key. The lookup also continues to recognize records using the previous raw-OID representation.
For requester-pays downloads, GOOGLE_PROJECT is sent to Terra DRS Hub as userProject; the returned signed URL is preserved unchanged.

Validation

All three Docker E2E tests passed against the exact Syfon commit pinned by CI, including TestGitDrsDockerAddURLE2E.
go test ./internal/drsobject ./internal/lookup ./internal/transfer passed.

why did the changes made to support requestor pays cause these errors?

The requester-pays code did not cause the lookup failure. The failure came from a separate change in the same branch: the add-url E2E test was changed from expecting an unknown-checksum placeholder pull to fail to expecting it to succeed.
That pull already couldn’t resolve the placeholder: its OID is 64 hex characters, so git-drs queried Syfon as if it were a SHA-256. But the record stored it as a git-drs-placeholder checksum, which Syfon’s SHA-256 lookup doesn’t match. The new test expectation exposed that existing mismatch; it wasn’t a regression from sending userProject.
The fix stores placeholder checksums under a non-SHA-shaped key and retries missed lookups using that key. The incidental git config --global messages in the test log were diagnostic snapshots, not the cause.

This branch has not been deployed

No deployments
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.

1 participant