docs: finalize documentation to the production state
CI / changes (pull_request) Successful in 2s
CI / unit (pull_request) Successful in 10s
CI / integration (pull_request) Successful in 16s
CI / ui (pull_request) Successful in 57s
CI / gate (pull_request) Successful in 0s
CI / deploy (pull_request) Successful in 1m21s

The project is live in production, so the staged-development scaffolding is removed.

- Delete the staged trackers PLAN.md and PRERELEASE.md.
- Rewrite CLAUDE.md: drop the per-stage workflow; codify the ongoing development
  principles (How we work) and the production model (Branching, CI & production):
  manual prod-deploy / prod-rollback, semver release tags, Ansible provisioning,
  expand-contract migrations.
- De-stage the living docs (README, ARCHITECTURE, TESTING, deploy/ansible, loadtest,
  platform/telegram READMEs) and the docker-compose tuning comments: drop the
  Stage N / R1-R7 / pre-release labels, keep every number and rationale, and fix the
  now-dangling PLAN.md / PRERELEASE.md references to describe the current state.
- Reword stale 'later stage' Go doc comments for subsystems that have shipped.
This commit is contained in:
Ilia Denisov
2026-06-22 08:33:30 +02:00
parent 40d8f06588
commit 48b06f4594
23 changed files with 136 additions and 2387 deletions
+2 -2
View File
@@ -3,8 +3,8 @@
// loads the dictionaries into the engine registry, warms the session cache,
// constructs the game domain and starts its turn-timeout sweeper, constructs the
// lobby and social domains, then serves the HTTP listener with the infrastructure
// probes and the /api/v1 route-group skeleton. Domain HTTP endpoints are added
// with the gateway in a later stage described in PLAN.md.
// probes and the /api/v1 route group, behind which the domains expose their HTTP
// endpoints to the gateway.
package main
import (
+1 -1
View File
@@ -21,7 +21,7 @@ const (
// ActionResign abandons the game.
ActionResign
// ActionTimeout is the auto-resignation a missed turn becomes; recorded by
// the game domain in a later stage, never produced by the engine itself.
// the game domain, never produced by the engine itself.
ActionTimeout
)
+1 -1
View File
@@ -10,7 +10,7 @@
// characters (see decode.go and docs/ARCHITECTURE.md §9.1), so archived games
// replay independently of any dictionary. Second, the engine owns rules and
// scoring only: turn scheduling, the 24-hour timeout, persistence and transport
// belong to the game domain in a later stage.
// belong to the game domain.
package engine
import (
+1 -1
View File
@@ -31,7 +31,7 @@ type entry struct {
// Registry holds the dictionaries resident in memory, addressed by variant and
// dictionary version, and the solvers built over them. Several versions of a
// variant may be resident at once; a game pins the version it started on. The
// admin reload flow (a later stage) registers a new version through Load.
// admin reload flow registers a new version through Load.
// Registry is safe for concurrent use.
type Registry struct {
mu sync.RWMutex
+1 -1
View File
@@ -16,5 +16,5 @@
// word-check tool with complaint capture, per-player game state, history and GCG
// export, and the per-game turn-timeout sweeper that auto-resigns an overdue
// player (honouring their daily away window). The HTTP surface that fronts these
// operations is added with the gateway in a later stage.
// operations is exposed to the gateway.
package game
+1 -1
View File
@@ -105,7 +105,7 @@ const MaxActiveQuickGames = 10
const aiPlayerName = "AI"
// CreateParams describes a new game. Seats lists the seated accounts in turn
// order (seat 0 moves first); lobby/matchmaking assembles it in a later stage.
// order (seat 0 moves first); lobby/matchmaking assembles it.
type CreateParams struct {
Variant engine.Variant
Seats []uuid.UUID
+1 -1
View File
@@ -62,7 +62,7 @@ func TestEmailConfirmFlow(t *testing.T) {
}
// TestEmailAlreadyTakenByAnotherAccount refuses to bind an email confirmed by a
// different account (merge is a later stage).
// different account (combining two accounts is the separate link/merge flow).
func TestEmailAlreadyTakenByAnotherAccount(t *testing.T) {
ctx := context.Background()
store := account.NewStore(testDB)
+5 -5
View File
@@ -1,10 +1,10 @@
// Package server wires the backend's HTTP listener: the gin engine, its route
// groups, the per-request telemetry middleware and the start/stop lifecycle.
//
// The /api/v1 route groups (public, user, internal, admin) are created here so
// later stages attach their endpoints to a stable structure; the /user group
// requires the X-User-ID identity header. The probes /healthz (liveness) and
// /readyz (database + session-cache readiness) are unauthenticated.
// The /api/v1 route groups (public, user, internal, admin) attach their endpoints
// to a stable structure; the /user group requires the X-User-ID identity header.
// The probes /healthz (liveness) and /readyz (database + session-cache readiness)
// are unauthenticated.
package server
import (
@@ -245,7 +245,7 @@ func (s *Server) Invitations() *lobby.InvitationService { return s.invitations }
func (s *Server) Emails() *account.EmailService { return s.emails }
// Handler returns the underlying HTTP handler. It lets tests drive the server
// without binding a socket and lets later stages compose the backend behind
// without binding a socket and lets callers compose the backend behind
// another listener.
func (s *Server) Handler() http.Handler { return s.http.Handler }
+1 -2
View File
@@ -8,8 +8,7 @@ import (
)
// Service mints, resolves, and revokes sessions over the store and the
// write-through cache. The gateway is its only caller (from a later stage); the
// HTTP surface is wired then.
// write-through cache. The gateway is its only caller.
type Service struct {
store *Store
cache *Cache
+2 -2
View File
@@ -3,8 +3,8 @@
// in as a message kind. It owns the friendships, blocks and chat_messages tables,
// reads the account-level block toggles through account.Store, and gates chat and
// nudge on game state through a GameReader so it never imports the engine. The
// live delivery of chat and nudges (push / in-app stream) belongs to the gateway
// in a later stage; this package only persists and reads them.
// live delivery of chat and nudges (push / in-app stream) belongs to the gateway;
// this package only persists and reads them.
package social
import (