Skip to content

Add bounded repository-verified runtime mirror failover - #151

Merged
soulteary merged 4 commits into
mainfrom
codex/runtime-mirror-health-20261013
Oct 12, 2026
Merged

soulteary merged 4 commits into
mainfrom
codex/runtime-mirror-health-20261013

Conversation

@soulteary

@soulteary soulteary commented Oct 12, 2026 •

Copy link
Copy Markdown
Owner

An opt-in mirror-health controller observes complete public Release/InRelease responses and switches away from repeated transport, incomplete-body or 5xx failures only after a candidate matches the learned SHA256 snapshot. Candidate probes and response headers use a shared deadline, resource admission, byte limits and cooldown; accepted response bodies retain their normal request lifetime. Unknown, expired or inconsistent suites stay pinned, and pool requests require a consistent view of all observed suites.

Explicit repository IDs, approved public query parameters and a conservative header policy prevent credential or tenant data from crossing mirrors. Routing epochs and active-source checks reject stale probe/body callbacks. Add authenticated read-only /api/mirrors/status, configuration validation and operational documentation.

Depends on #154. Validation: integrated full short race suite, vet and lint pass (83.3% coverage). Focused race regressions cover concurrent selection, refresh during probes, truncated fixed/chunked responses, body read timeouts, bounded candidate headers and accepted bodies surviving the probe window.

Copy link
Copy Markdown
Owner Author

@codex review

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 12, 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-12T20:04:43.278835Z aea960e Manual request
ℹ️ 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.

Base automatically changed from codex/reviewed-cache-ci-20261013 to main October 12, 2026 19:18

@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: e24be5e477

ℹ️ 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 internal/mirrorhealth/controller.go
Comment thread internal/mirrorhealth/failover.go Outdated
@soulteary
soulteary changed the base branch from main to codex/resource-admission-20261013 October 12, 2026 19:42

Copy link
Copy Markdown
Owner Author

Implemented both review findings and integrated the resource-admission/checksum/offline baseline. Body failures count once and only complete EOF clears failures; stale callbacks cannot alter a newer routing epoch. Candidate replay response headers share the selection deadline, while accepted response bodies retain their ordinary request lifetime. Full race tests, vet and lint pass; coverage is 83.3%.

@codex review

@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: 8e183f4c01

ℹ️ 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 internal/mirrorhealth/failover.go

Copy link
Copy Markdown
Owner Author

Integrated the reviewed public integrity/staging dependency and the filesystem-capacity/security-scan fixes from #154. The complete combined race suite passes with the updated module graph; the exact Linux gosec scan has no additional mirror-health findings.

@codex review

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. 🚀

Reviewed commit: 9ef27d0c4a

ℹ️ 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".

Copy link
Copy Markdown
Owner Author

Fixed recovered-mirror health for successful bodyless replays without clearing body-bearing failures early. Full and repeated focused race tests, vet and lint pass. Security Scan now also runs on PRs targeting feature branches, matching the existing CI trigger and keeping stacked PRs covered.

@codex review

Base automatically changed from codex/resource-admission-20261013 to main October 12, 2026 20:02
@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Delightful!

Reviewed commit: aea960e36a

ℹ️ 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".

@soulteary
soulteary merged commit 71951c9 into main Oct 12, 2026
8 checks passed
@soulteary
soulteary deleted the codex/runtime-mirror-health-20261013 branch October 12, 2026 20:29
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