microsoft / microsoft/durabletask-netherite
Entities become unresponsive under load
Nobody has claimed this yet.
- Dominant language
- C#
- Stars
- 239
- Forks
- 37
- Avg merge
- 1d 10h
- Merged PRs (30d)
- 2
Description
We are using durable functions in Azure with Netherite and an elastic premium plan (EP2).
We are using a setup with only entity functions and no orchestrators. Each entity has a list of work items it needs to process and an operation to trigger the processing of one task in the list. If the list is not empty after the operation has finished, the entity signals itself to run the operation again.
Pseudocode:
class Worker {
private List<WorkItem> workItems
public AddWork(items) {
workItems.append(items)
}
public Calculate {
if(!workItems.Empty) {
var wo = workItems.dequeue()
doWork(wo) // side effect: write to db
if(!workItems.Empty) {
ctx.Signal(myself, "Calculate")
}
}
The workers are created and initially signaled by another function:
Pseudocode
for(i = 1 to n) {
client.Signal(worker+i, "AddWork", getWorkForI(i))
client.Signal(worker+i, "Calculate")
}
The problem we are facing is that this setup runs ok for some time and then entities start becoming "stuck" somehow (they aren't doing the calculations) and a query to ListEntitiesAsync times out. The only method to revive the durable functions is to restart the durable function in Azure. We see some storage exceptions in the logs, but nothing really meaningful (to us). We don't see this problem without netherite (although it should be noted that we don't have the exact same system deployed with durable functions backed by Azure storage).
Is there a good way to debug these kind of problems when the durable runtime becomes unresponsive, or does someone see an obvious problem with the setup we are using?
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Begin with the entity-only workload and the storage exceptions in the logs, then inspect the ListEntitiesAsync timeout when entities become unresponsive. Compare behavior with and without Netherite as described and capture a reproducible failure. Done means identifying the runtime or setup cause and documenting actionable diagnostics or a confirmed fix.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- azure, csharp
- Domain
- backend, cloud, distributed-systems
- Issue type
- Bug
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 15/100