简体   繁体   English

耐用 Function 延迟触发

[英]Durable Function triggered with delay

I'm currently facing a weird issue.我目前面临一个奇怪的问题。

Randomly (I guess) my azure durable function invocation is triggered with delay >10min .随机(我猜)我的azure durable function invocation被延迟>10min触发。 My understanding is that there's something wrong with the lease for control queue.我的理解是控制队列的租约有问题。

I'm on Consumption Plan .我在Consumption Plan So i'm wondering if the scale-in/out mechanism is working properly with my durable function .所以我想知道我的durable function scale-in/out可以正常工作。 My feeling is that a host instance takes the lease then goes into drain mode -> recycling etc. and keeps the lease during 10min before releasing.我的感觉是host instance接受租约,然后进入drain mode -> recycling etc. ,并在释放前10min内保持租约。

My feeling is that it's happening after a period of inactivity.我的感觉是,它是在一段时间不活动后发生的。

Have you ever seen such behavior?你见过这样的行为吗?

在此处输入图像描述

I found the similar recent issue # 1148771 reported on January 2023 in MS Q&A Forum of Azure Functions where the user is experiencing delay in durable functions and the hosting model is Consumption Plan during Orchestration start.我在 Azure 的 MS 问答论坛中发现了类似的最新问题 # 1148771 ,其中用户遇到持久功能延迟,托管 model 是编排启动期间的消费计划。

This case still is in investigation by the Microsoft Support team and mentioned some of the reasons such as:此案例仍在由 Microsoft 支持团队进行调查,并提到了一些原因,例如:

The lease for control queue is held by previous function instance which is supposed to be recycled.控制队列的租约由之前的 function 实例持有,该实例应该被回收。

  • For the basic checks, make sure you have the latest versions of all the packages used in the function code.对于基本检查,请确保您拥有 function 代码中使用的所有包的最新版本。

  • Also, in the same Q&A Forum, mentioned the scenario what happened for causing the issue based on the timestamps, orchestration Ids provided.此外,在同一个问答论坛中,提到了根据提供的时间戳和编排 ID 导致问题的情况。 If your scenario is similar, then you can track the discussion for the solution.如果您的场景相似,那么您可以跟踪解决方案的讨论。

  • If it is product issue, then you could raise a ticket in azure-functions-durable-extensions repository of the GitHub.如果是产品问题,那么您可以在 GitHub 的 azure-functions-durable-extensions 存储库中提交工单。

Refer to the GitHub Issue # 606 and this MS Doc troubleshooting steps of Orchestration start delays in Azure Durable Functions.请参阅 GitHub 问题 # 606和 Azure Durable Functions 中编排启动延迟的此MS Doc故障排除步骤。

Today, I've received the update from the product team that the issue is caused by the current Lease Management logic used by Durable Function. It could happen when an instance was shut down.今天,我收到了产品团队的更新,该问题是由 Durable Function 使用的当前租赁管理逻辑引起的。它可能在实例关闭时发生。

This issue is specific to Azure Storage backend.此问题特定于 Azure 存储后端。

This issue has been existing for a while.这个问题已经存在一段时间了。 We're trying to refactor the current Lease Management logic with hope to fix such issue, but no clear ETA yet.我们正在尝试重构当前的租赁管理逻辑,希望能解决此类问题,但尚无明确的预计到达时间。 You can subscribe to Orchestrations freezing mid-execution · Issue #2207 · Azure/azure-functions-durable-extension (github.com) to get the notification when the fix is ready.您可以订阅 Orchestrations freezing mid-execution · Issue #2207 · Azure/azure-functions-durable-extension (github.com) 以在修复准备就绪时收到通知。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM