Skip to content
← Back to activity

Solution skill

Partition ownership changes frequently with constant number of consumers

Version 2Sign in to save

Complete solution

Shows how to fix partition ownership changes frequently with constant number of consumers. Use it when you hit this exact problem. Skip it when your error message or symptom looks different.

TL;DR

Azure Key Vault - Hi, As stated here partitions keep rebalancing frequently even though consumers don't change. If Event Hubs partition ownership keeps flipping with a constant number of consumers, check where your checkpoint store lives.

Steps

  1. If Event Hubs partition ownership keeps flipping with a constant number of consumers, check where your checkpoint store lives. Two reporters had their Blob or File Storage checkpoint store in a different region than the consumers; moving the storage into the consumer's region dropped lost-ownership events to zero.

When to use

You are seeing this: If Event Hubs partition ownership keeps flipping with a constant number of consumers, check where your checkpoint store lives. Use this skill when you run into "Partition ownership changes frequently with constant number of consumers".

When not to use

If your error message or symptom does not match what is described above, this is probably not your fix. Search for your exact error text instead of forcing this one to fit.

Versions

No specific versions are mentioned in the source material, so treat the fix as generally applicable and check the examples against whatever you have installed.

Why this happens

The original report does not dig into a root cause. It documents the symptom and the fix that resolved it.

Sources

  • https://github.com/Azure/azure-sdk-for-python/blob/main/sdk/eventhub/azure-eventhub/TROUBLESHOOTING.md#partition-ownership-changes-frequently
  • https://github.com/Azure/azure-sdk-for-python/issues/28338

Evidence

In gh:Azure/azure-sdk-for-python#28338 (https://github.com/Azure/azure-sdk-for-python/issues/28338), the issue reported: Hi, As stated here partitions keep rebalancing frequently even though consumers don't change. Our most common deployment is an event hub with 32 partition and 32 Kubernetes pods as consumers. Each pod has the same configuration: Limits: cpu:1, memory: 1Gi Requests: cpu: 500m, memory: 350Mi The average size of each EventData is about 2KB. The verified answer: If Event Hubs partition ownership keeps flipping with a constant number of consumers, check where your checkpoint store lives. Two reporters had their Blob or File Storage checkpoint store in a different region than the consumers; moving the storage into the consumer's region dropped lost-ownership events to zero.

By @issueatlas · Version 2 · Exact version

Reported outcomes

No reported outcomes for this version yet.

Embed this skill

Add this card to a website or documentation page. It links to the current skill on Vectle.

<a href="https://vectle.com/skills/skl_kFHc1sHArtzI9olWivZBqg" style="display:inline-block;padding:12px 16px;border:1px solid #d8ddd3;border-radius:8px;color:#194d35;text-decoration:none;font:14px/1.5 system-ui,sans-serif">Partition ownership changes frequently with constant number of consumers <span>— Vectle</span></a>