Scale PostgreSQL - partitioning, connection pooling, high availability
Automates PostgreSQL partitioning, connection pooling, and replication setup. Triggers when optimizing large tables, managing connection limits, or configuring high availability for production databases.
/plugin marketplace add pluginagentmarketplace/custom-plugin-postgresql/plugin install ultrathink@pluginagentmarketplace-postgresqlThis skill inherits all available tools. When active, it can use any tool Claude has access to.
assets/config.yamlassets/schema.jsonreferences/GUIDE.mdreferences/PATTERNS.mdscripts/validate.pyAtomic skill for horizontal and vertical scaling
Production-ready patterns for partitioning, connection pooling, and high availability.
parameters:
operation:
type: string
required: true
enum: [partition, pool, replicate, shard]
partition_type:
type: string
enum: [range, list, hash]
CREATE TABLE events (id BIGINT, data JSONB, created_at TIMESTAMPTZ)
PARTITION BY RANGE (created_at);
CREATE TABLE events_2024_q1 PARTITION OF events
FOR VALUES FROM ('2024-01-01') TO ('2024-04-01');
[pgbouncer]
pool_mode = transaction
default_pool_size = 20
max_client_conn = 1000
CREATE ROLE replicator WITH REPLICATION LOGIN PASSWORD 'secret';
SELECT pg_create_physical_replication_slot('replica1');
SELECT client_addr, pg_size_pretty(pg_wal_lsn_diff(sent_lsn, replay_lsn)) as lag
FROM pg_stat_replication;
| Mode | Use Case |
|---|---|
| session | Long connections |
| transaction | Web apps (recommended) |
| statement | Simple queries |
| Problem | Cause | Solution |
|---|---|---|
| Partition not used | Pruning disabled | SET enable_partition_pruning = on |
| Too many connections | No pooler | Use PgBouncer |
| Replication lag | Slow replica | Check I/O, network |
Skill("postgresql-scaling")
Use when working with Payload CMS projects (payload.config.ts, collections, fields, hooks, access control, Payload API). Use when debugging validation errors, security issues, relationship queries, transactions, or hook behavior.
Applies Anthropic's official brand colors and typography to any sort of artifact that may benefit from having Anthropic's look-and-feel. Use it when brand colors or style guidelines, visual formatting, or company design standards apply.
Creating algorithmic art using p5.js with seeded randomness and interactive parameter exploration. Use this when users request creating art using code, generative art, algorithmic art, flow fields, or particle systems. Create original algorithmic art rather than copying existing artists' work to avoid copyright violations.