Skip to content

Add scoped Crawl and Mercure subscription services - #8

Merged
xormania merged 4 commits into
devfrom
foundation/archive-services
Oct 5, 2026
Merged

xormania merged 4 commits into
devfrom
foundation/archive-services

Conversation

@xormania

@xormania xormania commented Oct 4, 2026

Copy link
Copy Markdown
Owner

Chess Dog needs a trusted service boundary to Chess-Crawl before its player workflows and Live/Turbo components are designed. This adds server-side archive reads, scoped run/job reads, and explicitly budgeted collection submissions with stable idempotency keys. Rich archive reads verify the configured token-to-workspace binding before fetching private observations.

Mercure Bundle supplies five-minute, subscriber-only JWTs for exact authorized run/job topics. Browser-safe connection options exclude credentials; cookies are HttpOnly, host-only, same-origin and HTTPS Secure. Validated JSON event identities feed snapshot-authoritative revision/reconnect decisions. Documentation explains local configuration and the authenticated app-user-to-workspace resolver needed for SaaS. UX design and browser/component wiring remain open; no templates, controllers, routes, styles or navigation change.

Validation: 29 unit/existing functional tests, 136 assertions; Symfony YAML/container lint; Composer strict validation and dependency audit; native Mate confirms PHP 8.5.11 and service wiring with secrets redacted. Independent scope/security review fixes are included, including rich-player credential binding and nullable retry timestamps in normal job events.

Integration limits: targets the companion workspace-scoped Crawl API. The local configured authority is not app-user authentication. Subscriber signing uses the hub's separate HMAC subscriber key and a same-origin proxy. No application subscriber route or arbitrary HTML publication is introduced. Live Components and Turbo are already installed; the Flowbite subscription can support the later UX work.

xormania commented Oct 4, 2026

Copy link
Copy Markdown
Owner Author

@codex review

xormania commented Oct 4, 2026

Copy link
Copy Markdown
Owner Author

@codex security review

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 4, 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-04T22:21:48.071498Z 7a13316 Manual request
🔒 Security Review ✅ Completed 2026-10-04T22:22:11.600657Z 7a13316 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.

@chatgpt-codex-connector

Copy link
Copy Markdown

🛡️ Codex Security Review

Security review completed. No security issues were found in this pull request.

Reviewed commit: c3a65bfd5c

View security finding report

Only the user who started this review can view the report in Codex.

ℹ️ About Codex security reviews in GitHub

This is an experimental Codex feature. Security reviews are triggered when:

  • You comment "@codex security review"
  • A regular code review gets triggered (for example, "@codex review" or when a PR is opened), and you’re opted in so security review runs alongside code review

Once complete, Codex will leave suggestions, or a comment if no findings are found.

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

ℹ️ 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 config/packages/mercure.yaml

xormania commented Oct 4, 2026

Copy link
Copy Markdown
Owner Author

@codex review

xormania commented Oct 4, 2026

Copy link
Copy Markdown
Owner Author

@codex security 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: 2f14d557bd

ℹ️ 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 src/Archive/CrawlSubscriptions.php Outdated
@chatgpt-codex-connector

Copy link
Copy Markdown

🛡️ Codex Security Review

Security review completed. No security issues were found in this pull request.

Reviewed commit: 2f14d557bd

View security finding report

Only the user who started this review can view the report in Codex.

ℹ️ About Codex security reviews in GitHub

This is an experimental Codex feature. Security reviews are triggered when:

  • You comment "@codex security review"
  • A regular code review gets triggered (for example, "@codex review" or when a PR is opened), and you’re opted in so security review runs alongside code review

Once complete, Codex will leave suggestions, or a comment if no findings are found.

xormania commented Oct 4, 2026

Copy link
Copy Markdown
Owner Author

@codex review

xormania commented Oct 4, 2026

Copy link
Copy Markdown
Owner Author

@codex security review

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Can't wait for the next one!

Reviewed commit: 7a13316808

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

@chatgpt-codex-connector

Copy link
Copy Markdown

🛡️ Codex Security Review

Security review completed. No security issues were found in this pull request.

Reviewed commit: 7a13316808

View security finding report

Only the user who started this review can view the report in Codex.

ℹ️ About Codex security reviews in GitHub

This is an experimental Codex feature. Security reviews are triggered when:

  • You comment "@codex security review"
  • A regular code review gets triggered (for example, "@codex review" or when a PR is opened), and you’re opted in so security review runs alongside code review

Once complete, Codex will leave suggestions, or a comment if no findings are found.

@xormania
xormania marked this pull request as ready for review October 5, 2026 01:11
@xormania
xormania merged commit 3c90aa2 into dev Oct 5, 2026
7 checks passed
@xormania
xormania deleted the foundation/archive-services branch October 5, 2026 01:11
xormania added a commit that referenced this pull request Oct 5, 2026
Promote the archive and Mercure service foundation from `dev` into
`master`, the repository's default branch.

Included work from #8:

- Add scoped Chess-Crawl archive, run and job reads, plus budgeted
collection submissions with stable idempotency keys.
- Add short-lived Mercure subscriber grants for exact authorized topics,
event validation, and revision/reconnect handling based on authoritative
API snapshots.
- Document local credentials, workspace authorization and integration
requirements; update Mercure runtime configuration and CI coverage.

UX design and browser/Live Component/Turbo wiring remain open. The
existing preview does not call the new services. SaaS exposure requires
an authenticated app-user-to-workspace resolver.

Validation:

- [CI passed on the current dev
commit](https://github.com/xormania/chess-dog/actions/runs/37250429470)
(`3c90aa2e81bd77b9cdb060eb5255f7f4525b837a`).
- Source PR #8 records 29 unit/existing functional tests with 136
assertions, Symfony YAML/container lint, Composer strict validation and
dependency audit, and native Mate service checks.
- At preparation, `dev` is 5 commits ahead of `master`, with no commits
behind, across 30 changed files.

Draft for maintainer review; PR CI runs through the existing workflow.
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