2.8 KiB
2.8 KiB
id, title, status, wave, depends_on, plan, spec
| id | title | status | wave | depends_on | plan | spec | |||
|---|---|---|---|---|---|---|---|---|---|
| 05-service-routing | Workspace-aware GitHub service routing | completed | 4 |
|
plan.md | ../../specs/integrations/requirements/github-authentication.md |
Task 05: Workspace-Aware GitHub Service Routing
Inputs
- Spec: Identity And Routing, repository boundary, failure modes, and background/personal scenarios.
- ADR 0047: no process-global operational client and principal-scoped cache/rate state.
- Resolver contract from Tasks 02-04.
Acceptance
- All GitHub domain operations resolve an explicit workspace/purpose; direct production use of the
singleton
Service.clientandService.authMethodis removed. - Task, PR, issue, watch, cleanup, and CI paths derive and verify workspace ownership and fail closed when absent or contradictory; concurrent workspaces cannot share client, cache, rate, or singleflight state.
- Personal reads/mutations follow the specified fallback/attribution rules and enforce the automation-visible plus configured repository intersection before provider calls.
- App-backed review watches use a persisted verified target login rather than
@me; migrated watches without one are disabled without a provider call.
Files Likely Touched
apps/backend/internal/github/service.goapps/backend/internal/github/service_pr.goapps/backend/internal/github/service_pr_status.goapps/backend/internal/github/service_reviews.goapps/backend/internal/github/service_issues.goapps/backend/internal/github/service_accessible_repos.goapps/backend/internal/github/workspace_settings_service.goapps/backend/internal/github/service_pr_watch.goapps/backend/internal/github/service_pr_watch_batched.goapps/backend/internal/github/service_cleanup.goapps/backend/internal/github/poller.goapps/backend/internal/github/service_ci_automation.goapps/backend/internal/github/service_task_issue.goapps/backend/internal/orchestrator/event_handlers_github*.goapps/backend/internal/automation/evaluator.goapps/backend/internal/workflowsync/service.goapps/backend/internal/task/share/GitHub Gist call sites
Verification
cd apps/backend && rtk go test ./internal/github
cd apps/backend && rtk go test ./internal/orchestrator ./internal/automation -run 'Test.*GitHub'
cd apps/backend && rtk rg 's\.client|s\.authMethod' internal/github
The final search may find only constructor/test compatibility code with an explicit justification; it must find no operational service path.
Output Contract
Report migrated call families, ownership derivation, actor routing, cache/rate keys, tests run, files touched, blockers, and remaining compatibility references.