ChangeFeedProcessor API and Resource Tokens
See original GitHub issueIn using the ChangeFeedProcessor.StartAsync(), we have run into a 403 issue "Insufficient permissions provided in the authorization header for the corresponding request. Please retry with another authorization header. ActivityId: 250e7411-d830-4fcf-b82a-0dd654a1c62b, "
The issue is due to the StartAsync() call making a GET request scoped to a CosmosDB database, not collection.
D:\dbs\el\csdb;\Product\Cosmos\RoutingGateway\Runtime\RequestHandlers\AddressRequestHandler.cs:line 57" Argument5="changefeedtokentest" Argument6="AddressFeedQuery" Argument7="GET" TraceSource="DocDBTrace"
My question: is the change feed processor SDK not capable of working with resource tokens? We have thus far been able to use resource tokens to instantiate 1 CosmosClient per token and do operations using 1 CosmosClient per collection. Given that we pass collections via CosmosClient.GetContainer()
calls as part of ChangeFeedProcessor’s Build()
, I would expect operations on the monitored, lease, and target collections to work.
Issue Analytics
- State:
- Created 10 months ago
- Comments:39 (20 by maintainers)
Top GitHub Comments
Great, I tested the fix locally and confirmed it works for our workflows. Thank you!
You can fork the repo (the fix is already in master) and test it, the linked PR already has an end to end test using Resource Token (not mocks) that mirrors the scenario and it’s working/passing.