Explorable Architecture // Real-World Failure Modes

Don't just read about failure modes. Simulate them.

I'm Raza Basit. I design tactile, zero-setup architectural simulators modeling distributed concurrency limits, database bottlenecks, and CPU cache physics — paired with production remediation playbooks.

● 5 Interactive Labs•100% Client-Side Physics•Zero Runtime Overhead
safe-sqlite-mcp
$safe-sqlite-mcp --db=prod.db --deny-columns=token,secret
● listening on stdio (protocol v2024-11-05 • pure Go)
→ agent: "SELECT id, status FROM jobs LIMIT 10"
↳PASS • 10 rows returned (1.1ms)
→ agent: "SELECT * FROM api_keys"
↳BLOCKED • rule: DisallowWildcard
Guardrail Activeboot: <2ms • RSS: 6.4MB
Interactive Systems LabLive Architecture Simulators

Production Architecture in Motion

Explore cascading failure modes, buffer pool exhaustion, and algorithmic cliffs with real-time controls and senior engineer remediation playbooks.

View All 5 Labs in Catalogarrow_forward
router
Topic 01 // Web Requests & ConcurrencyInteractive Simulator
10,000 req/s

API & Database Connection Pool Limits

Interactive architecture simulator for Little's Law, database connection pool exhaustion, cascading 504 timeouts, and circuit breaker load shedding.

GoPostgreSQLPool Starvation
Launch Labarrow_forward
hub
Topic 02 // Background Queues & MessagingInteractive Simulator
4 Partitions

Kafka Partitions & The Mega-Customer Bottleneck

Model Kafka consumer lag, partition hot-spots, and why adding workers cannot solve partition skew due to the 1-worker-per-partition invariant.

KafkaDistributed QueuesConsumer Lag
Launch Labarrow_forward
receipt_long
Topic 03 // Data Safety & Distributed TransactionsInteractive Simulator
0% Data Loss

The Lost Order Mystery: Dual-Writes vs. Transactional Outbox

Simulate silent data loss under network failure with naive dual-writes vs guaranteed consistency with the Transactional Outbox pattern.

PostgreSQLCDC / DebeziumDual-Writes
Launch Labarrow_forward
database
Topic 04 // Database Engine PerformanceInteractive Simulator
0 Heap Fetches

Database Indexes: Single-Key, Compound, and Covering Indexes

Interactive simulator modeling Full Table Scans vs Single-Key, Compound, and Covering Indexes (Index-Only Scan with 0 heap fetches), plus the column order trap.

PostgreSQLB-TreeCovering Index
Launch Labarrow_forward
speed
Topic 05 // Algorithms & Hardware RealityInteractive Simulator
O(1) to O(N²)

Big-O in Production: Operations, Latency & The Cache Trap

Interactive systems simulator modeling algorithmic time complexity (O(1), O(log N), O(N), O(N log N), O(N²)) against real CPU cycles, RAM, and hardware cache lines.

CPU CacheMemory LocalityGo
Launch Labarrow_forward
Field Notes & Theory

Production Debriefs & Case Studies

In-depth post-mortems, mathematical proofs, and architectural patterns backing the interactive simulators.

View all 8 posts→
Featured Series•4-Part Architecture Deep Dive

Building a Distributed Rate Limiter in Go

~30 min total

Rate limiting looks simple until production traffic arrives. This end-to-end series traces the complete architectural evolution: from a naive single-mutex in-memory structure to shard-partitioned locks, algorithmic tradeoffs, and finally a distributed multi-node Redis implementation.

Open Source

Featured Systems & Tools

Flagship Toolv1.1.0

safe-sqlite-mcp-go

A single-binary Model Context Protocol (MCP) server in Go that safely exposes SQLite databases to AI agents with immutable connection guardrails.

Quick InstallPure Go • Zero Cgo
$go install github.com/raza-basit/safe-sqlite-mcp-go@latest
Cold Startup
< 2ms
Idle Memory
< 8MB RSS

Subscribe via RSS or follow on GitHub

I publish long-form technical tutorials and systems engineering post-mortems. No newsletters spam—pure RSS and open code.