Skip to content

Add snapshot-only storage for generated data branches - #436

Merged
trask merged 8 commits into
mainfrom
trask-deployment-volume
Oct 13, 2026
Merged

trask merged 8 commits into
mainfrom
trask-deployment-volume

Conversation

@trask

@trask trask commented Oct 2, 2026

Copy link
Copy Markdown
Member

Add opt-in snapshot-only storage for CI queue data and PR dashboard state to reduce clone size without discarding historical CI measurements or delivery acknowledgements. Addresses #434.

After promoting snapshot-capable code to all dashboard writers and completing the documented paused-writer cutover, enable it with:

gh variable set DATA_BRANCH_SNAPSHOTS --body true --repo open-telemetry/shared-workflows

Each generated branch then retains one complete, parentless snapshot. Explicit push leases prevent stale workers from overwriting accepted updates, and snapshot generations prevent stale fetches from rolling state backward.

Activation defaults to disabled. The cutover procedure includes an external backup, tree verification, and recovery guidance. Existing clones do not shrink automatically, and other refs to old data can retain history.

Refresh schedules and the stalled-run watchdog remain unchanged.

Preserve current CI measurements and dashboard delivery state while allowing generated branches to keep a single parentless snapshot. Gate activation until all dashboard writers support snapshot ordering and explicit push leases.

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
@trask
trask requested a balanced review from Copilot October 2, 2026 01:39
@opentelemetry-pr-dashboard

opentelemetry-pr-dashboard Bot commented Oct 2, 2026 •

Copy link
Copy Markdown

Pull request dashboard status

Merged · refreshed 2026-10-13 15:21 UTC

Status above doesn't look right?
  • Anything look wrong? Report it with what you expected; it helps us improve the dashboard.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Copilot review overview

🟡 Changes recommended

Fresh checkouts can accept history-bearing commits after cutover and reset snapshot generations.

Review effort: Balanced
Findings: 1 High severity

Open (1)
What changed in this PR

Adds opt-in parentless snapshots for generated dashboard and queue-data branches to reduce clone size while preserving current state.

Changes:

  • Adds snapshot generation, explicit push leases, and retry handling.
  • Wires activation into workflows and the queue collector.
  • Adds tests and operational cutover/recovery documentation.
File Description
pull-request-dashboard/​README.md Documents dashboard snapshot storage.
github-actions-queue/​README.md Documents queue-data snapshots.
.github/​workflows/​pull-request-dashboard-repo.yml Passes the activation variable.
.github/​workflows/​pull-request-dashboard-refresh-author-nudges.yml Passes the activation variable.
.github/​workflows/​pull-request-dashboard-drain.yml Passes the activation variable.
.github/​workflows/​github-actions-queue-test.yml Expands queue test triggers.
.github/​workflows/​github-actions-queue-collector.yml Uses explicit leases and snapshot commits.
.github/​scripts/​pull-request-dashboard/​WEBHOOK_SETUP.md Documents cutover and recovery.
.github/​scripts/​pull-request-dashboard/​test_state_branch.py Updates state-branch tests.
.github/​scripts/​pull-request-dashboard/​test_rollout.py Tests workflow activation wiring.
.github/​scripts/​pull-request-dashboard/​test_data_snapshots.py Tests snapshot behavior and concurrency.
.github/​scripts/​pull-request-dashboard/​state_branch.py Implements the snapshot protocol.
.github/​scripts/​github-actions-queue/​DATA_BRANCH_README.md Describes generated branch semantics.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
@trask
trask requested a balanced review from Copilot October 3, 2026 00:51

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Copilot review overview

🔵 Needs a closer look

The distributed Git snapshot protocol and irreversible operational cutover warrant final human validation despite comprehensive tests.

Review effort: Balanced
Findings: None

Resolved since last review (1)

@trask
trask requested a balanced review from Copilot October 3, 2026 02:37

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Copilot review overview

🟡 Changes recommended

History appended to a snapshot can reset its generation and undermine stale-state protection.

Review effort: Balanced
Findings: 1 High severity

Open (1)

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
@trask
trask requested a balanced review from Copilot October 3, 2026 17:15

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Copilot review overview

🔵 Needs a closer look

The force-pushed parentless-history protocol and coordinated operational cutover warrant final human validation despite comprehensive safeguards and tests.

Review effort: Balanced
Findings: 1 High severity

Open (1)

@trask
trask requested a balanced review from Copilot October 4, 2026 01:45

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Copilot review overview

🟡 Changes recommended

The collector unnecessarily downloads the entire multi-gigabyte legacy history on every pre-cutover run.

Review effort: Balanced
Findings: 1 Medium severity

Open (1)
Resolved since last review (1)

…pshot mode

Copilot comment:

This deepens the legacy queue-data branch to its entire history on every hourly run even while snapshot mode is intentionally unset during the required rollout. Because that history is the multi-gigabyte data this change is meant to compact, pre-cutover collection can now consume substantial time and disk on every fresh runner. Pass the activation variable to this step and only fetch ancestry when snapshot mode is enabled; ordinary append mode only needs the depth-one head.

Copilot comment:

<!-- ccr-overview-v2 -->

## Copilot review overview

### 🟡 Changes recommended

The collector unnecessarily downloads the entire multi-gigabyte legacy history on every pre-cutover run.

**Review effort:** Balanced  
**Findings:** 1 <picture><source media="(prefers-color-scheme: dark)" srcset="https://github.githubassets.com/static/images/icons/copilot-code-review/medium-v2-dark.svg"><source media="(prefers-color-scheme: light)" srcset="https://github.githubassets.com/static/images/icons/copilot-code-review/medium-v2-light.svg"><img src="https://github.githubassets.com/static/images/icons/copilot-code-review/medium-v2-light.png" alt="Medium severity" width="62" height="18" align="texttop"></picture>

<details open>
<summary><strong>Open (1)</strong></summary>

- <picture><source media="(prefers-color-scheme: dark)" srcset="https://github.githubassets.com/static/images/icons/copilot-code-review/medium-v2-dark.svg"><source media="(prefers-color-scheme: light)" srcset="https://github.githubassets.com/static/images/icons/copilot-code-review/medium-v2-light.svg"><img src="https://github.githubassets.com/static/images/icons/copilot-code-review/medium-v2-light.png" alt="Medium severity" width="62" height="18" align="texttop"></picture> [Avoid fetching full queue history when snapshot mode is disabled](#discussion_r4175743106) · New
</details>

<details>
<summary><strong>Resolved since last review (1)</strong></summary>

- <picture><source media="(prefers-color-scheme: dark)" srcset="https://github.githubassets.com/static/images/icons/copilot-code-review/high-v2-dark.svg"><source media="(prefers-color-scheme: light)" srcset="https://github.githubassets.com/static/images/icons/copilot-code-review/high-v2-light.svg"><img src="https://github.githubassets.com/static/images/icons/copilot-code-review/high-v2-light.png" alt="High severity" width="62" height="18" align="texttop"></picture> [Reject snapshot ancestry to preserve monotonic generations](#discussion_r4171386289)
</details>

Analysis: Pass DATA_BRANCH_SNAPSHOTS to the checkout step and gate the full-depth fetch on it being true, since the ancestry check in commit-data only runs in snapshot mode.

Upsides: Avoids downloading multi-gigabyte history on every pre-cutover hourly run.

Downsides: If snapshot mode is later turned off, no ancestry is available, which commit-data already forbids for snapshot branches.

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
@trask
trask requested a balanced review from Copilot October 4, 2026 02:14

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Copilot review overview

🔵 Needs a closer look

The destructive branch compaction and distributed concurrency protocol require final human validation of the operational cutover.

Review effort: Balanced
Findings: None

Resolved since last review (1)

Co-authored-by: trask <218610+trask@users.noreply.github.com>
Preserve queue-owned live and maintenance execution alongside opt-in data snapshots. Pass the activation variable to the owned drain and guard its propagation. Reconcile deployment guidance so snapshot cutover pauses both lanes and preserves promoted readers, leases, and delivery receipts.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
@trask
trask marked this pull request as ready for review October 12, 2026 22:33
@trask
trask requested a review from a team as a code owner October 12, 2026 22:33
@trask
trask requested a review from mx-psi October 12, 2026 22:33
@trask
trask merged commit 2695653 into main Oct 13, 2026
7 checks passed
@trask
trask deleted the trask-deployment-volume branch October 13, 2026 15:21
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.

4 participants