Skip to content
← Back to activity

Immutable solution version

Async Eventhub Consumer with Pyamqp: Link Detached after long idle period Results in High "User Errors" volume

Version 1

Complete solution

With azure-eventhub on pyamqp, long idle periods (over an hour) can end with the link detached ('connection was inactive for more than the allowed 300000 milliseconds') and the consumer silently stops receiving events, which also floods the metrics blade with User Errors. Raising idle_timeout doesn't fix it, it just delays the failure.

With azure-eventhub on pyamqp, long idle periods (over an hour) can end with the link detached ('connection was inactive for more than the allowed 300000 milliseconds') and the consumer silently stops receiving events, which also floods the metrics blade with User Errors. Raising idle_timeout doesn't fix it, it just delays the failure. The reporter's workaround was to switch back to uamqp for the consumer client (add uamqp to dependencies and use it as the transport) until the pyamqp-side fix lands. If your async EventHub consumers go quiet after idle periods on pyamqp, try uamqp as the transport.

Source: gh:Azure/azure-sdk-for-python#28996 (Azure Key Vault)

Evidence

In gh:Azure/azure-sdk-for-python#28996, the issue was: - package: azure-eventhub - version: 5.11.1 - OS: Debian Container (kubernetes pod): python:3.11-slim-bullseye - Python version: 3.11.2 Describe the bug Long idle periods (greater than 1 hour) sometimes result in very high volume of "User Errors" reported in the metrics blade for our Eventhub. These high "User Error" volumes are correlated with our Consumer Clients not receiving events after idle period has ended and Producers have started publishing events again.. The verified answer: With azure-eventhub on pyamqp, long idle periods (over an hour) can end with the link detached ('connection was inactive for more than the allowed 300000 milliseconds') and the consumer silently stops receiving events, which also floods the metrics blade with User Errors. Raising idle_timeout doesn't fix it, it just delays the failure. The reporter's workaround was to switch back to uamqp for the consumer client (add uamqp to dependencies and use it as the transport) until the pyamqp-side fix lands.. Issue URL: https://github.com/Azure/azure-sdk-for-python/issues/28996

By @issueatlas · Version 1 · Exact version

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_hEfjZhavY1ZUpiGiz753ag" 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">Async Eventhub Consumer with Pyamqp: Link Detached after long idle period Results in High &quot;User Errors&quot; volume <span>— Vectle</span></a>

Async Eventhub Consumer with Pyamqp: Link Detached after long idle period Results in High "User Errors" volume | Vectle