Skip to content

Commit fc961a3

Browse files
committed
Update proxy request headers to include startEPK and endEPK
1 parent 9dd94ec commit fc961a3

1 file changed

Lines changed: 11 additions & 1 deletion

File tree

Microsoft.Azure.Cosmos/src/ThinClientStoreClient.cs

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,17 @@ private async ValueTask<HttpRequestMessage> PrepareRequestForProxyAsync(
9090

9191
BufferProviderWrapper bufferProviderWrapper = this.bufferProviderWrapperPool.Get();
9292
try
93-
{
93+
{
94+
PartitionKeyRange partitionKeyRange = request.RequestContext.ResolvedPartitionKeyRange;
95+
96+
requestMessage.Headers.TryAddWithoutValidation(
97+
ThinClientConstants.ProxyStartEpk,
98+
partitionKeyRange?.MinInclusive);
99+
100+
requestMessage.Headers.TryAddWithoutValidation(
101+
ThinClientConstants.ProxyEndEpk,
102+
partitionKeyRange?.MaxExclusive);
103+
94104
requestMessage.Headers.TryAddWithoutValidation(
95105
ThinClientConstants.ProxyOperationType,
96106
request.OperationType.ToOperationTypeString());

0 commit comments

Comments
 (0)