Repository navigation
feat(dcr): P1-7 RFC 7591 documentation + admin console form (incl. five-scenario perf fixes) - #295
Merged
Merged
Conversation
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
… console (P1-7 #284) POST /oauth2/register existed (admin-gated) but was invisible: no docs, no UI. Two surfaces now make it a first-class capability: Docs — build-an-app.md (EN + zh-CN mirror, llms-full regenerated) gains 'Programmatic registration (RFC 7591)': a curl sequence verified end-to-end against a fresh dev stack (admin access token via the seeded fulla-portal client's json-mode login + PKCE -> code exchange -> Bearer), a request-field table (defaults, F-017 auth-method rules, redirect scheme policy) and the post_logout_redirect_uris authority semantics (non-empty authoritative for end_session, empty falls back to the login redirect list); response fields incl. the shown-once client_secret and the RFC 7592 non-goal pointer. Admin console — a 'Register (RFC 7591)' form on the Applications page distinct from the admin-API create modal (it exercises the standard endpoint itself): client name/type, token_endpoint_auth_method dropdown locked to none for PUBLIC clients (F-017), redirect URIs, the RFC 7591 grant set (authorization_code/refresh_token/client_credentials — no device code, the endpoint rejects it), post-logout array. Deliberately NO logo_uri field — the DCR body does not process it; P1-1's write paths own that field. Success shows the client_secret exactly once (portal display semantics), the list refreshes, audit reuses client_registered. i18n EN/zh-CN. E2e (mock-driven, 4 new, 21/21 applications suites green): modal field shape incl. the absent logo_uri/device-code fields ('logo_uri' not 'logo' — Post-logout contains the substring), the PUBLIC auth-method lock, the full register -> secret-once -> list-appearance chain with request-body contract assertions, and the client-side confidential redirect-URI guard.
…e-scenario gate) The v1.6.0 pre-release five-scenario gate (same-machine back-to-back, v1.5.0 worktree vs this branch, wrk staircase, repeat arms) found two regressions, both 'one extra DB round trip per request' patterns: - S6 userinfo -18%: StorageClaimMappingsProvider::getEnabledMappings hit Postgres on every userinfo/refresh/code issuance. Wrapped in CachedClaimMappingsProvider (process-local, write-path invalidation from the claim-mapping CRUD hook that already refreshes discovery, 60s TTL only bounds cross-process drift). Same-window A/B: 39.7-44.7k QPS vs v1.5.0's 40.0-45.9k (97-112%). - S3 introspect -17%: the P1-4 org-deletion overlay queried oauth2_client_owners per request. Now a plugin-level TTL cache (hot path: lock + map lookup, no allocation before the lock; 60s TTL, precisely invalidated from open-platform suspend/resume and the org soft-delete cascade after commit). A first cut with a 3s TTL was WORSE (-40%, miss storm over the 512 bench clients); the tuned version restores parity: same-window 22.2k vs v1.5.0's 21.5k (103%). Semantics locked by existing e2e (all green): org delete -> introspect inactive stays immediate (invalidation fires post-commit); claim-mapping CRUD -> immediate publication stays immediate (invalidate-then-refetch). Remaining scenarios within noise (S1 91.7% / S2 94.5% / S5 94.9% mean across the staircase; low-concurrency single-level dips are small-N jitter, c16+ levels all 99%+).
voidvec
force-pushed
the
feat/p1-7-dcr-docs-ui
branch
from
October 30, 2026 01:31
879b989 to
a988112
Compare
…api-diff additions - admin total 398.4KB -> 400.4KB base (measured 439.3KB vs 438.2KB cap; the RFC 7591 modal + bilingual catalog added ~2.4KB) — justification per the budget-gate discipline (same as the 2026-09-17 re-baseline); - api-diff baseline ratifies the one additive public header of the perf commit (CachedClaimMappingsProvider.h) — additions only, no removals or signature changes (no version bump required).
This was referenced Oct 30, 2026
Closed
2 tasks
voidvec
added a commit
that referenced
this pull request
Nov 12, 2026
… page + audit export controls (audit wave B) The #159 gate failed on #329 as designed: the new Claim Mappings page (table + create/edit modals, lazy route) and the audit-logs export controls with their bilingual catalogs add ~15.6KB raw to the admin bundle (456.0KB CI-measured vs the 440.5KB cap; main 156.2KB vs 157.3KB stayed inside). Same re-baseline path as v1.6.0 P1-7 (#295 precedent); bases moved to the CI-measured numbers.
voidvec
added a commit
that referenced
this pull request
Nov 12, 2026
… page + audit export controls (audit wave B) The #159 gate failed on #329 as designed: the new Claim Mappings page (table + create/edit modals, lazy route) and the audit-logs export controls with their bilingual catalogs add ~15.6KB raw to the admin bundle (456.0KB CI-measured vs the 440.5KB cap; main 156.2KB vs 157.3KB stayed inside). Same re-baseline path as v1.6.0 P1-7 (#295 precedent); bases moved to the CI-measured numbers.
voidvec
added a commit
that referenced
this pull request
Nov 12, 2026
… page + audit export controls (audit wave B) The #159 gate failed on #329 as designed: the new Claim Mappings page (table + create/edit modals, lazy route) and the audit-logs export controls with their bilingual catalogs add ~15.6KB raw to the admin bundle (456.0KB CI-measured vs the 440.5KB cap; main 156.2KB vs 157.3KB stayed inside). Same re-baseline path as v1.6.0 P1-7 (#295 precedent); bases moved to the CI-measured numbers.
voidvec
added a commit
that referenced
this pull request
Nov 12, 2026
… page + audit export controls (audit wave B) The #159 gate failed on #329 as designed: the new Claim Mappings page (table + create/edit modals, lazy route) and the audit-logs export controls with their bilingual catalogs add ~15.6KB raw to the admin bundle (456.0KB CI-measured vs the 440.5KB cap; main 156.2KB vs 157.3KB stayed inside). Same re-baseline path as v1.6.0 P1-7 (#295 precedent); bases moved to the CI-measured numbers.
voidvec
added a commit
that referenced
this pull request
Nov 12, 2026
voidvec
added a commit
that referenced
this pull request
Nov 12, 2026
voidvec
added a commit
that referenced
this pull request
Nov 12, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
feat: RFC 7591 DCR — documentation + admin console form (P1-7 #284)
What
POST /oauth2/register(RFC 7591, admin-gated) existed but was documented nowhere and had no UI. Two surfaces make it a first-class capability:Docs —
docs/guides/build-an-app.mdgains "Programmatic registration (RFC 7591)":fulla-portalclient's json-mode login + PKCE → code exchange → Bearer → register → 201);post_logout_redirect_urisauthority semantics (non-empty authoritative forend_session, empty falls back to login redirect list);client_secret,client_secret_expires_at: 0, RFC 7592 explicitly a non-goal;Admin console — "Register (RFC 7591)" form on the Applications page (distinct from the admin-API create modal; it exercises the standard endpoint itself):
token_endpoint_auth_methoddropdown locked tononefor PUBLIC (F-017 — server rejects anything else), redirect URIs, RFC 7591 grant checkboxes (no device code — the endpoint rejects it), post-logout array;ClientRegistrationService; P1-1's write paths own that field);client_secretexactly once (portal display semantics), list refreshes; audit reusesclient_registered;Acceptance criteria → evidence
dcr-doc-probe)toMatchObjecton the exact RFC 7591 body)gen-llms-txt.mjsrerunGates (local, all green)
npm run build(tsc + vite) ✓ · unit 4/4 ✓ · eslint 0 errors (3 pre-existinganywarnings untouched) ✓logo_urinotlogo: "Post-logout" contains the substring "logo")Out of scope (unchanged non-goals)
RFC 7592 management; open (non-admin-gated) registration.
Also in this PR: five-scenario performance fixes (gate-critical)
The v1.6.0 pre-release five-scenario gate (same-machine back-to-back vs v1.5.0, wrk staircase, repeat arms) found two regressions - both one-extra-DB-round-trip-per-request patterns introduced by P1-3/P1-4 - fixed and re-measured at parity in this branch:
Same-window re-measurement: S6 97-112%, S3 103% vs v1.5.0. Semantic e2e locked (org delete -> introspect inactive stays immediate; CRUD -> immediate publication).
Known issue carried (same as #294, documented there)
One rotating assertion per full-suite run (this round: OpenPlatform RegisterRotateDeleteFlow:671, 61709/61710; every other leg green — macOS, Windows, ASan, gcov). Same login-family DB-lock window; systemic fix is a tracked follow-up.
Ride-alongs in this final push: admin bundle budget re-baseline (P1-7 modal, +2.4KB, justification in-file), api-diff baseline ratification (one additive header), sdk-smoke job ceiling 30->60min (was cancelled mid-build).