1---2name: tech-matrix3description: Reference document for monopoly tech-matrix. 4category: Document Processing5source: antigravity6tags: [node, api, ai, workflow, design, document, docker, kubernetes, aws, gcp]7url: https://github.com/sickn33/antigravity-awesome-skills/tree/main/skills/monopoly/tech-matrix8metadata:9 source: https://skillmd.com/skills/sickn33/tech-matrix10---111213# MONOPOLY — Technology Decision Matrix1415## Table of Contents161. Database Selection172. Cache Selection183. Message Queue / Event Streaming194. API Protocol205. Search Engine216. Object Storage227. Container Orchestration238. Load Balancer249. Observability Stack2510. CDN2627---2829## 1. Database Selection3031### Relational (SQL)3233| Database | Best For | Avoid When | Scale Ceiling |34|----------|----------|------------|---------------|35| **PostgreSQL** | Complex queries, JSONB, GIS, strong consistency, most default use cases | Ultra-high write throughput (>100K writes/s) | ~10TB single node; use Citus for horizontal |36| **MySQL / MariaDB** | Read-heavy apps, legacy systems, WordPress/Drupal ecosystem | Complex queries, full ACID at scale | ~10TB; use Vitess for sharding |37| **CockroachDB** | Global distributed SQL, geo-partitioning, multi-region | Simple single-region apps (overkill) | Petabyte-scale |38| **PlanetScale** | MySQL-compatible, serverless, branch-based workflow | Complex JOINs (foreign keys removed by design) | Very high — Vitess based |39| **Amazon Aurora** | AWS-native apps, managed PostgreSQL/MySQL, high availability | Non-AWS environments | Up to 128TB, 15 replicas |4041### NoSQL4243| Database | Best For | Avoid When | Scale Ceiling |44|----------|----------|------------|---------------|45| **MongoDB** | Flexible schema, document model, prototyping | Financial transactions requiring ACID | Petabyte-scale with sharding |46| **DynamoDB** | Key-value at massive scale, AWS-native, serverless, predictable latency | Complex queries, ad-hoc analytics, JOINs | Unlimited (AWS-managed) |47| **Cassandra** | Write-heavy, time-series, wide-column, geographically distributed | Read-heavy with complex queries | Petabyte-scale; used at Apple, Netflix |48| **Redis** | Cache, sessions, leaderboards, pub/sub, rate limiting | Primary data store for complex models | ~1TB per node; cluster for more |49| **Elasticsearch** | Full-text search, log aggregation, analytics | Primary database (durability risk) | Petabyte-scale with clusters |50| **InfluxDB** | Time-series metrics, IoT, monitoring data | General-purpose data | Very high write throughput |51| **Neo4j** | Graph data, social networks, recommendation engines, fraud detection | Non-graph data (overhead not worth it) | Billions of nodes |5253### Decision Framework5455```56Is your data relational (joins, foreign keys, transactions)?57 YES → Start with PostgreSQL58 NO → Continue below5960Is your primary access pattern key-value?61 YES, need extreme scale → DynamoDB or Cassandra62 YES, need speed/cache → Redis6364Is your data document-shaped (nested, flexible schema)?65 YES → MongoDB6667Is it time-series (metrics, logs, IoT)?68 YES → InfluxDB or TimescaleDB6970Is it graph (relationships are the data)?71 YES → Neo4j7273Is it search?74 YES → Elasticsearch / OpenSearch75```7677---7879## 2. Cache Selection8081| Technology | Best For | Max Single Node | Cluster Support |82|------------|----------|----------------|----------------|83| **Redis** | Sessions, leaderboards, pub/sub, complex data structures, Lua scripting | ~1TB RAM | Yes (Redis Cluster, Redis Sentinel) |84| **Memcached** | Simple key-value, multi-threaded, large object cache | ~64GB RAM | Yes (client-side sharding) |85| **Varnish** | HTTP reverse proxy cache, full-page caching | RAM bound | Limited |86| **CloudFront / CDN** | Static assets, edge caching globally | N/A (distributed) | Built-in global distribution |8788**Default recommendation: Redis** — more features, better ecosystem, active development.8990Use **Memcached** only when: you need multi-threading for CPU-bound caching workloads and don't need data structures beyond string.9192---9394## 3. Message Queue / Event Streaming9596| Technology | Model | Best For | Throughput | Retention |97|------------|-------|----------|------------|-----------|98| **Apache Kafka** | Log-based streaming | Event sourcing, high-throughput pipelines, replay, audit | Millions msg/s | Days to forever |99| **RabbitMQ** | AMQP message broker | Task queues, RPC, routing, fanout | 50K–100K msg/s | Until consumed |100| **AWS SQS** | Managed queue | AWS-native, simple task queue, serverless | Very high (managed) | Up to 14 days |101| **AWS SNS** | Pub/sub notification | Fan-out to many subscribers (email, SMS, Lambda, SQS) | Very high (managed) | No retention |102| **Google Pub/Sub** | Managed streaming | GCP-native, global, serverless | Very high (managed) | Up to 7 days |103| **Redis Pub/Sub** | In-memory pub/sub | Real-time notifications, low latency, fire-and-forget | Very high | None (no retention) |104| **NATS** | Lightweight messaging | IoT, microservices, low latency | Very high | JetStream adds retention |105106### Decision Matrix107108```109Need event replay / audit trail?110 YES → Kafka or Kinesis111112Need simple task queue with retries and DLQ?113 AWS shop → SQS114 Self-hosted → RabbitMQ115116Need real-time pub/sub with no persistence?117 Redis Pub/Sub or NATS118119Need fan-out to multiple consumers?120 Kafka (consumer groups) or SNS → SQS fan-out121122Need < 5 minutes