Repository navigation
✨ hub: v1 registration discovery and configurable repo cap (1/3) - #18892
Merged
Merged
Conversation
Rollout step 1, part A of the hub registration protocol (#18642), ported from the tuna-os#189 prototype: - GET /api/hub/v1 discovery: protocol version, operations, limits (max_repos, max_per_user, expiry, key_rotation_overlap) and the proof method the hub actually offers, hub-session-token. Readable without signing in. - HIVE_HUB_SELFSERVICE_MAX_REPOS makes the per-registration repo cap configurable (default 20, clamped to 500). The legacy create keeps its 400 body; the request body limit scales with the cap. Everything is behind HIVE_HUB_SELFSERVICE_REGISTRATION. No GitHub writes; heartbeat_signing.go and the credential fence are untouched. Co-authored-by: James Reilly <5840441+hanthor@users.noreply.github.com> Signed-off-by: James Reilly <jreilly1821@gmail.com> Signed-off-by: Andrew Anderson <andy@clubanderson.com>
Contributor
Open PR overlap checkBase branch: Conflicts are checked with every PR merged onto the current tip of
|
Contributor
|
[APPROVALNOTIFIER] This PR is APPROVED Approval requirements bypassed by manually added approval. This pull-request has been approved by: The full list of commands accepted by this bot can be found here. The pull request process is described here DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
Contributor
Mutation testinggremlins found 1 surviving mutant(s) in changed files: the code ran under tests, but changing it did not fail any test.
Verdict: |
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.
Refs #18642
Rollout step 1, PR A of 3 (A: discovery and cap, B: per-repo proofs, revision, create/list/delete/rotate, C: PATCH). Ported from hanthor's prototype (tuna-os#189); his authorship is kept via a Co-authored-by trailer and his Signed-off-by, as the commits are re-created in slices on v5.
All behind
HIVE_HUB_SELFSERVICE_REGISTRATION.GET /api/hub/v1: public discovery (versions, operations, limitsmax_repos/max_per_user/expiry/key_rotation_overlap, proof methods advertised ashub-session-token). Lists only operations that exist in this PR; later PRs add theirs.HIVE_HUB_SELFSERVICE_MAX_REPOS: default 20, clamped to 500, replaces theselfServiceMaxReposconst. Legacy create keeps its 400 body. The request body limit scales with the cap.Not touched:
heartbeat_signing.go, the credential fence, any GitHub write.Tests: discovery shape, flag-off 404, cap default and clamp, legacy 400 body, route registered (helper and real hub mux).
🤖 Generated with Claude Code