Comments (11)
Thank you for your feedback. Tagging and routing to the team member best able to assist.
from azure-sdk-for-net.
I think this instance also needs updating - https://github.com/JoshLove-msft/azure-sdk-for-net/blob/4a51f3567f5da030a964494807aa25e1aba888aa/sdk/eventhub/Microsoft.Azure.WebJobs.Extensions.EventHubs/src/Listeners/EventHubListener.PartitionProcessor.cs#L289
from azure-sdk-for-net.
@JoshLove-msft: Would you please advise on whether this is related to the ask on the Functions team to expose whether an execution would be retried if the host is not shutting down? If so, please transfer to the Functions host repo.
from azure-sdk-for-net.
@yfujiwara-sansan, I couldn't reproduce having _functionExecutionToken be canceled with linkedCts still not being cancelled. That said, it looks like you are correct that cancellation is not atomic when it comes to linked token sources, so it is possible that one of the sources can be canceled while the linked source is still not canceled. I will make a fix to explicitly check each of the token sources when making the checkpointing decision.
from azure-sdk-for-net.
@JoshLove-msft Thank you for your work! I guess that the repro code sometimes fails to repro due to scheduling of continuations.
By the way, as far as I read #38067 again, it looks that lInkedCts
now can be passed to TryExecute
bacause it is not lInked to the token which is cancelled In drain mode. I think there is a better option to pass linkedCts
to TryExecute
, because the app should be cancelled when the load balancer detects ownership lost.
from azure-sdk-for-net.
I think there is a better option to pass
linkedCts
toTryExecute
, because the app should be cancelled when the load balancer detects ownership lost.
The semantics of the token passed to the function are that it is signaled only when shutting down in a way that is not guaranteed to allow the function to complete execution. In terms of whether it makes sense to also cancel this token when partition ownership is lost, I would have to defer to @jsquire on that.
from azure-sdk-for-net.
I understand the semantics of the token passeed to the app. The cancellation behavior for ownership lost should be discussed as a different issue because it is intentional behavior.
Thank you for your answer! I and my colleagues are waiting for fixking the race condition.
from azure-sdk-for-net.
I think there is a better option to pass
linkedCts
toTryExecute
, because the app should be cancelled when the load balancer detects ownership lost.The semantics of the token passed to the function are that it is signaled only when shutting down in a way that is not guaranteed to allow the function to complete execution. In terms of whether it makes sense to also cancel this token when partition ownership is lost, I would have to defer to @jsquire on that.
@JoshLove-msft : The token that the processor passes to OnProcessingEventBatch
will get canceled when partition ownership is lost. I would assume that we're flowing that token into the Executor so that the Function is notified. Looking over the implementation, it seems that we're not passing that along, for some reason. Any idea why?
from azure-sdk-for-net.
I don't think there was a good reason - it may have just been an oversight. Updated the PR to pass linkedCts token to TryExecute.
from azure-sdk-for-net.
Thank you for fix, but let me confirm just in case.
Is it intentional to fix only single dispatch path? It looks following arguments should be fixed, too:
- https://github.com/JoshLove-msft/azure-sdk-for-net/blob/4a51f3567f5da030a964494807aa25e1aba888aa/sdk/eventhub/Microsoft.Azure.WebJobs.Extensions.EventHubs/src/Listeners/EventHubListener.PartitionProcessor.cs#L176C78-L176C101
- https://github.com/JoshLove-msft/azure-sdk-for-net/blob/4a51f3567f5da030a964494807aa25e1aba888aa/sdk/eventhub/Microsoft.Azure.WebJobs.Extensions.EventHubs/src/Listeners/EventHubListener.PartitionProcessor.cs#L210C63-L210C86
from azure-sdk-for-net.
You are right again. Apologies for the oversight. I will add these updates in.
from azure-sdk-for-net.
Related Issues (20)
- [BUG] Recent commit introduced NullReferenceException in LogsQueryClient constructor HOT 6
- [BUG] SubscriptionResource.GetLocationsAsync fails with System.FormatException HOT 6
- [Schema Registry] Bump Apach.Avro dependency version
- What does MaxConcurrentCallsPerSession do? HOT 3
- Check and adjust timeouts for OpenAI HOT 1
- Validate MSAL MI API Integration (look for adoption blockers, breaking changes)
- STG 94 release prep
- Contradicting info with UploadAsync. HOT 1
- [QUERY] How to force to delete a CosmosDBSqlDatabaseResource? HOT 2
- [BUG] Azure.Provisioning KeyVault resource .. cannot set firewall rules. HOT 2
- Missing commas in the Communication Services Email SDK samples for .NET C# HOT 1
- Restore Key Vault Functionality Missing Azure SDK .NET C# HOT 2
- [BUG] TenantId may be empty string in Monitor GetActivityLogs response
- [BUG] ADLS SDK does not add Content-Length = 0 for flush requests explicitly HOT 2
- Move all provisioning libraries into respective service directories
- Decide whether to collapse Auth/ManagedIdentities into Azure.Provisioning
- [OpenAI] Update CodeGen to version 3.0.0-beta.20240329.2
- Any blocks not specified in the block list... HOT 1
- [FEATURE REQ] Support extensions in Postgres flexible HOT 1
- [FEATURE REQ] Add Method to Retrieve Analyzed Documents in DocumentIntelligence SDK HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from azure-sdk-for-net.