Sangeetha-Grantha

Metadata Value
Status Not Started
Version 1.0.0
Last Updated 2026-06-06
Author Principal Data & AI Engineering review (for Seshadri)
Type Epic — umbrella track; each workstream spawns its own TRACK-XXX when scheduled
Priority P2 (strategic) — runs in parallel; gates first production launch

TRACK-109: Production Readiness Roadmap

Goal

Define the path from “works on make dev” to “runs in production, safely, observably, and affordably.” Today the application is a well-factored dev-stage system (Docker Compose, local Makefile workflows, manual imports). This epic enumerates the workstreams that must close before — and shortly after — a first production deployment, sequenced so the highest-risk gaps (secrets, backups, deploy) are addressed first. This is the long-term vision the other new tracks (105–108) feed into.

Context — current state vs production bar

What already exists and is genuinely good (build on it, don’t rebuild):

What’s missing for production (the gaps this epic closes):

Workstream Gap today Production bar
W1 — Secrets management API keys / JWT secret / DB creds via plaintext .env (SG_GEMINI_API_KEY etc.) Managed secrets (GCP Secret Manager / Vault); no secrets in repo or image; rotation policy
W2 — CI/CD 🟡 CI partially landed (TRACK-111): .github/workflows/ci.yml builds all 3 layers + runs tests + Flyway migrate/validate. Remaining: dependency scanning, branch-protection enforcement, and the CD half (promotion gates + rollback). CI builds all 3 layers, runs tests + migrations, scans deps; CD with promotion gates + rollback
W3 — Deployment & runtime Docker Compose (dev only) Prod orchestration (Cloud Run / GKE per GCP affinity); health/readiness probes; horizontal scale for API + worker
W4 — Observability Micrometer wired but no backend; logs local Prometheus + Grafana dashboards; alerting; distributed tracing; SLOs (latency, extraction success rate, queue depth)
W5 — Data durability & DR Local Postgres volume Automated backups + PITR; tested restore; retention policy; RPO/RTO targets
W6 — Security hardening Basic Rate limiting, input validation, dependency/CVE scanning, secret scanning, least-privilege DB roles, TLS everywhere, security review (see security-review skill)
W7 — Extraction pipeline reliability extraction_queue with retries Dead-letter queue, idempotency guarantees, poison-message handling, backpressure, worker autoscale
W8 — Data quality gates Manual review + quality scoring (TRACK-011) Automated DQ checks (Great Expectations / Deequ-style) in CI/import; block bad payloads before persist
W9 — Cost governance (FinOps) None explicit Gemini spend tracking (Batch from TRACK-107), per-import cost visibility, budget alerts
W10 — Content licensing & compliance Provenance captured, policy implicit Explicit source licensing/attribution policy for scraped krithis; takedown process; PII review (low — public texts)
W11 — Mobile release pipeline KMP app builds locally Signing, store provisioning (iOS/Android), staged rollout, crash reporting

Approach

Treat each workstream as an independently schedulable track. Do not attempt all of W1–W11 before launch; sequence by risk:

Each workstream, when scheduled, gets a TRACK-XXX with its own HLD, NFRs, failure modes, and rollback plan (use the engineering:system-design, engineering:deploy-checklist, and security-review skills).

Implementation Plan (epic-level milestones)

Milestone A — Deployability (W1, W2, W3)

Milestone B — Survivability (W5, W6)

Milestone C — Operability (W4, W7, W8)

Milestone D — Sustainability (W9, W10, W11)

Acceptance Criteria (launch gate)

Risks

Dependencies

Progress Log

Ref: application_documentation/sangeetha-grantha-uplift-tasks.md