Amazon MSK Kafka Cluster Sizing and Tuning Prompt
Right-size and tune an Amazon MSK (managed Kafka) cluster for throughput and durability, choosing broker instances, partitions, replication, storage, and client configs without over- or under-provisioning.
- Target user
- Platform and streaming engineers running Amazon MSK
- Difficulty
- Advanced
- Tools
- Claude, ChatGPT, Cursor
The prompt
You are a senior AWS streaming architect who sizes and tunes Amazon MSK clusters. I will provide: - Workload shape: peak/average produce throughput (MB/s and messages/s), message size, number of topics/partitions, consumer group count, and retention needs - Durability/latency requirements (replication factor, min.insync.replicas, acks, acceptable end-to-end latency) - Current cluster: broker type/count, AZs, storage size and type, MSK version, and whether provisioned or serverless - Observed problems: under-replicated partitions, disk filling, high CPU, consumer lag, or cost concerns Your job: 1. **Size brokers** — recommend broker instance type and count (per-AZ, multiples of AZ count) from throughput, connection count, and CPU/network headroom, and say when MSK Serverless is the better fit. 2. **Design topics and partitions** — set partition counts from target throughput and consumer parallelism, avoiding both hot partitions and partition sprawl, and set replication factor / min.insync.replicas for the durability target. 3. **Plan storage** — size per-broker EBS, enable tiered storage where retention is long, turn on storage auto-scaling, and set retention (time/size) to control disk. 4. **Tune broker and client configs** — recommend `acks`, idempotent/transactional producers, `batch.size`/`linger.ms`, compression, `num.replica.fetchers`, and consumer `fetch`/`max.poll` settings for the workload. 5. **Set health signals** — the CloudWatch/Kafka metrics to alarm on (UnderReplicatedPartitions, KafkaDataLogsDiskUsed, CPUUser, consumer lag) with thresholds. 6. **Plan safe changes** — sequence broker scaling, config updates, and any partition/replication changes as rolling, migration-based operations with rollback. Output: (a) a sizing recommendation (broker type/count, storage, RF/min.insync) with the throughput math, (b) the topic/partition design, (c) the broker + client config settings with rationale, and (d) a monitoring + safe-rollout plan. Advise only: produce sizing and configuration recommendations for me to review and apply. Do not assume it is safe to alter a running cluster; call out every step that causes a rolling restart.
Run this prompt with AI
Test it, get an AI-improved version, or compare models — live in the Prompt Workspace. No copy-paste.
Related prompts
-
AWS EFS and FSx File Storage Selection Review Prompt
Choose and tune the right AWS shared file storage — EFS, FSx for Lustre, FSx for NetApp ONTAP, or FSx for Windows — for a workload's throughput, latency, protocol, and cost profile.
-
ElastiCache for Redis Performance and Failover Review Prompt
Diagnose Amazon ElastiCache for Redis latency, evictions, and failover risk by correlating CloudWatch engine metrics with node sizing, cluster mode, eviction policy, and client connection behavior.
-
CloudFront Distribution and Cache Strategy Design Prompt
Design and tune a CloudFront distribution end to end — origins, cache policies, TTLs, origin request policies, and invalidation strategy — for a specific application to raise cache hit ratio and cut origin load and cost.
-
EBS Volume & Snapshot Cost and Performance Review Prompt
Audit EBS volumes and snapshots for wasted spend (idle/unattached volumes, over-provisioned IOPS, stale snapshots) and performance bottlenecks, and recommend right-sized volume types.
More AWS with AI prompts & error guides
Browse every AWS with AI prompt and troubleshooting guide in one place.
Reading prompts? Get all 500 in one free PDF
500 battle-tested, copy-paste AI prompts engineered by a senior systems engineer — every one with fill-in placeholders and safety/back-out notes. Drop your email and it's yours.
- 500 prompts: Linux · Kubernetes · Terraform · OpenStack · GitLab · Docker · Monitoring · Incident Response
- Instant PDF download — yours free, forever
- Plus one practical AI-workflow email a week (no spam)
Single opt-in · unsubscribe anytime · no spam.