# SDLC Orchestration **Last Updated:** 2026-02 **Confidence:** High (Steps 1-5 implemented, Step 6 pending) ## Summary Deterministic feature lifecycle management. Classifier engine evaluates priority-ordered rules to determine the next required action. State lives in `.sdlc/` directory (git-tracked). Used by Claude agents in pods (CLI) and by rdev API (Go library + kubectl exec). **Key Facts:** - 10 phases: draft → specified → planned → ready → implementation → review → audit → qa → merge → released - 24 classifier rules, first match wins, returns Classification with action + guidance - 7 artifact types: spec, design, tasks, qa_plan, review, audit, qa_results - rdev drives transitions on behalf of users (approve, reject, unblock, transition) - Multi-project: scoped by projectID (pod name), each pod has its own `.sdlc/` **File Pointers:** - Library: `internal/sdlc/` (types, state, feature, classifier, rules, config) - CLI: `cmd/sdlc/` (cobra commands, --json output for API consumption) - Port (planned): `internal/port/sdlc_executor.go` - Adapter (planned): `internal/adapter/kubernetes/sdlc_adapter.go` - Handler (planned): `internal/handlers/sdlc.go` - Spec: `docs/specs/sdlc-orchestration-system.md` - Guide: `.claude/guides/services/sdlc.md` ## Library Types ```go // internal/sdlc/classifier.go type Classification struct { Feature string `json:"feature"` CurrentPhase FeaturePhase `json:"current_phase"` RuleMatched string `json:"rule_matched"` Action ActionType `json:"action"` Message string `json:"message"` NextCommand string `json:"next_command,omitempty"` OutputPath string `json:"output_path,omitempty"` TransitionTo FeaturePhase `json:"transition_to,omitempty"` TaskID string `json:"task_id,omitempty"` } ``` ## CLI Commands ``` sdlc init # Create .sdlc/ structure sdlc state [--json] # Full state dump sdlc feature create # New feature sdlc feature transition <slug> <phase> # Phase transition sdlc feature block/unblock <slug> # Blocker management sdlc artifact create/approve/reject # Artifact lifecycle sdlc task add/start/complete/block # Task lifecycle sdlc next [--for <feature>] [--json] # Classifier output sdlc query blocked/ready/needs-approval # Queries ``` ## rdev API Endpoints (Planned - Step 6) ``` GET /projects/{id}/sdlc/state GET /projects/{id}/sdlc/next GET /projects/{id}/sdlc/features GET /projects/{id}/sdlc/features/{slug} POST /projects/{id}/sdlc/features/{slug}/transition POST /projects/{id}/sdlc/features/{slug}/artifacts/{type}/approve POST /projects/{id}/sdlc/features/{slug}/artifacts/{type}/reject POST /projects/{id}/sdlc/features/{slug}/unblock GET /projects/{id}/sdlc/query/blocked GET /projects/{id}/sdlc/query/ready GET /projects/{id}/sdlc/query/needs-approval ``` ## Feature Gaps (Step 6) | Gap | Description | Effort | |-----|-------------|--------| | Port interface | `SDLCExecutor` port for pod operations | Small | | Pod adapter | kubectl exec wrapper for sdlc commands | Medium | | Service layer | Business logic, validation, error mapping | Medium | | HTTP handlers | REST endpoints under `/projects/{id}/sdlc/` | Medium | | Cross-project view | Dashboard of all project SDLC states | Small | | Webhook events | SDLC phase transitions as webhook events | Small | ## Related Topics - [Kubernetes Adapter](./kubernetes.md) - Pod execution pattern (PodGitOperations) - [Work Queue](./work-queue.md) - Task execution for agents - [Worker Pool](./worker-pool.md) - Agent pool management