Issue with where clause when using a client restricted to a partition key
See original GitHub issueWe are experiencing an issue in the following scenario.
We have a container with a partitionkey defined. We create users with permissions specific to a single partitionkey. We create a client specific for this user, based on his token. When we query a single item like this:
container.ReadItemAsync<T>(itemId, PartitionKey)
Everything works as expected, the item is correctly retreived.
However when trying to retrieve a filtered list as such:
container.GetItemLinqQueryable<T>(requestOptions: new QueryRequestOptions { PartitionKey = PartitionKey }).Where(query).ToFeedIterator(); var result = new List<T>(); while (iterator.HasMoreResults) result.AddRange(await iterator.ReadNextAsync());
We receive an unauthorized response: 403.
It appears as though the where clause does not respect the QueryRequestOptions. If we remove .Where(query) from the above code, then the issue does not present itself.
Environment summary SDK Version: 3.4.1 .Net Core 2.2 running on Azure App Services
Issue Analytics
- State:
- Created 4 years ago
- Comments:32 (14 by maintainers)
Top GitHub Comments
@j82w Thanks. Updated my packages and dit some tests. Seems to work like expected now!
@BenLuts doing the release now. Should be available within the hour.