← ClaudeAtlas

postgres-firstlisted

PostgreSQL-First Architecture — evidence-based stack simplification expert. Activate whenever a project mentions a database, cache, queue, search engine, vector store, background jobs, pub/sub, rate limiting, audit trails, or any backend infrastructure. Evaluates when PostgreSQL can replace Redis, MongoDB, Elasticsearch, Pinecone, RabbitMQ, Celery, n8n, or other infrastructure. Trigger phrases: "what cache should I use", "which queue", "I need a search engine", "vector database", "background jobs", "simplify my stack", "audit my architecture", "migrate from Redis/Mongo/n8n", "too many services", "how to do full-text search", "rate limiting", "multi-tenant", "row level security".
Thanane15M/postgres-first · ★ 0 · API & Backend · score 72
Install: claude install-skill Thanane15M/postgres-first
# PostgreSQL-First Architecture > **Every external service adds deployment, cost, failure modes, and operational load. > Add one when measured requirements exceed the PostgreSQL design.** This skill provides PostgreSQL-native patterns and explicit exit criteria. It is not a claim that one database fits every workload. Benchmark the actual access pattern and preserve specialized systems when they provide required semantics. --- ## RULE ZERO — The Evidence Test Before recommending or removing an external service, collect this evidence: | Dimension | Evidence required | |---|---| | **Performance** | Peak throughput, p95/p99 latency, data size, query shape, growth margin | | **Semantics** | Ordering, replay, fan-out, durability, availability and consistency needs | | **Operations** | Blast radius, restore time, staffing, compliance, regional and cost constraints | Prefer PostgreSQL when a load test and failure-mode review show that it meets the service-level objective with headroom. Keep or introduce a specialized service when it provides semantics or isolation PostgreSQL cannot meet economically. The replacement matrix below covers each case. --- ## THE COMPLETE REPLACEMENT MATRIX ### 1. Document Store / NoSQL → `JSONB` ```sql -- Replaces: MongoDB, DynamoDB, Firestore, CouchDB CREATE TABLE entities ( id BIGSERIAL PRIMARY KEY, tenant_id UUID NOT NULL, -- multi-tenant from birth type TEXT NOT NULL, -- your