Azure Event Hubs Throughput and Partition Scaling Review Prompt
Review an Azure Event Hubs namespace for correct partition count, throughput-unit/processing-unit sizing, consumer-group and checkpoint design, and capture/retention settings before it ingests production event streams at scale.
- Target user
- Cloud data and platform engineers running Azure Event Hubs for high-volume ingestion
- Difficulty
- Advanced
- Tools
- Claude, ChatGPT, Cursor
The prompt
You are a senior Azure streaming data engineer who sizes and troubleshoots Azure Event Hubs. You understand that partition count is fixed at creation on Standard (and cannot be increased later without recreating the hub), that throughput is governed by Throughput Units on Standard or Processing Units on the Premium/Dedicated tiers, the per-partition limits (roughly 1 MB/s or 1000 events/s ingress and 2 MB/s egress), that a consumer processes one partition at a time so effective parallelism is capped by partition count, and how checkpointing to a blob store drives at-least-once delivery and rebalancing. I will provide: - The namespace: tier (Basic/Standard/Premium/Dedicated), TU/PU count and auto-inflate setting (`az eventhubs namespace show`) — [NAMESPACE] - The event hub: partition count, message retention, and capture config (`az eventhubs eventhub show`) — [HUB] - Producer profile: peak and sustained ingress in MB/s and events/s, partition key strategy, and batch size — [PRODUCERS] - Consumer profile: consumer groups, number of consumer instances per group, the client SDK/EventProcessor used, and the checkpoint store — [CONSUMERS] - The symptom or goal: throttling (ServerBusyException), consumer lag, hot partitions, uneven distribution, or a capacity-planning pass — [GOAL] Your job: 1. **Ingress vs. capacity.** Compare peak producer MB/s and events/s against the tier limit (TU: 1 MB/s in per TU on Standard; PU-based on Premium). If ingress approaches the ceiling, ServerBusy throttling is expected — recommend more TUs, enabling auto-inflate with a sane max, or moving to Premium/Dedicated. State the number, don't hand-wave. 2. **Partition count.** Effective consumer parallelism cannot exceed partition count — more consumer instances than partitions leaves some idle. Check partitions ≥ target parallel consumers and ≥ (peak MB/s ÷ per-partition limit). If the hub is under-partitioned on Standard, flag that fixing it requires creating a new hub and migrating, because partitions are immutable there. 3. **Hot partitions.** Review the partition key strategy. A low-cardinality or skewed key concentrates traffic on one partition and throttles it while others idle. Recommend a higher-cardinality key or letting the service round-robin (null key) when ordering isn't required per key. 4. **Consumers and checkpointing.** Confirm each consuming application has its own consumer group (Standard allows up to 20), that only one active reader per partition per group exists unless using the epoch/ownership model, and that checkpoint frequency balances reprocessing-on-failure against checkpoint-store load. Flag missing or shared checkpoint stores that cause duplicate processing on rebalance. 5. **Retention and capture.** Verify message retention covers the worst-case consumer downtime, and that Capture (if used) targets the right storage/format and won't silently drop under load. Output as: (a) the specific bottleneck for the traffic in [GOAL] with the number that proves it; (b) findings ranked by impact (data loss/throttling > lag > cost); (c) the concrete sizing change — TU/PU count, partition count, key strategy, consumer-group layout — and the `az eventhubs` commands to apply it; (d) the metric to watch afterward (ThrottledRequests, IncomingMessages, ConsumerLag). Use only the profile I gave you. If peak ingress numbers or partition count are missing, ask — capacity cannot be judged without them.
Run this prompt with AI
Test it, get an AI-improved version, or compare models — live in the Prompt Workspace. No copy-paste.
Why this prompt works
Event Hubs capacity problems are almost always decided at creation time and then discovered under load. Partition count is immutable on Standard, so an under-partitioned hub caps consumer parallelism no matter how many instances you add, and the only real fix is a migration. This prompt forces the review to check partition count against both target parallelism and peak throughput up front, and to be honest that raising it is a rebuild — not a slider — so teams plan the migration instead of hitting the wall in production.
The second failure mode is confusing throttling for a code bug. ServerBusyException is the service telling you ingress exceeded the provisioned Throughput or Processing Units, or that a skewed partition key concentrated traffic on one partition. By requiring peak MB/s, events/s, and the key strategy as inputs, the prompt makes the model prove the bottleneck with a number and distinguish a global capacity shortfall from a hot-partition problem — two issues with completely different fixes.
The output stays operational: it names the one bottleneck for the scenario, ranks findings so data-loss and throttling risks come before cost, hands over the exact az eventhubs change, and tells you which metric confirms the fix. The guardrails block the two changes that cause outages or surprise bills — an in-place partition change that isn’t possible, and uncapped auto-inflate.
Related prompts
-
Azure Container Apps Config & Scaling Review Prompt
Review an Azure Container Apps configuration for scaling rules, ingress, secrets, and revision strategy, then propose a reliable, cost-aware setup with safe rollout.
-
Azure SQL Performance Tuning Prompt
Diagnose a slow Azure SQL Database from query plans, wait stats, and index usage, then propose tuning — indexes, query rewrites, and the right service tier — with safe rollout.
-
AKS Cluster & Node Pool Upgrade Planning Review Prompt
Plan a safe AKS Kubernetes version upgrade by reviewing supported version skew, node pool surge settings, PodDisruptionBudgets, deprecated API usage, and add-on compatibility to sequence a zero-surprise control-plane and node-image upgrade.
-
Azure Arc Hybrid Server Onboarding & Governance Review Prompt
Review an Azure Arc-enabled servers deployment for secure onboarding and consistent governance by analyzing Connected Machine agent health, identity and RBAC scope, policy/guest configuration assignments, and extension management across on-prem and multicloud machines.
More Azure with AI prompts & error guides
Browse every Azure 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.