Open adeliab opened 1 year ago
Thank you for your feedback. This has been routed to the support team for assistance.
We think that the issue happens when we perform an operation twice or more times with the same client (either blobcontainerclient or blobclient). Scenarios that would reproduce this error:
The custom domain seems to have an impact since we didn't have this issue before using custom domain
Thanks for the feedback! We are routing this to the appropriate team for follow-up. cc @xgithubtriage.
Sounds like there's a proxy cache in between altering the x-ms-client-request-id
. I highly recommend you disable the cache as it's altering the requests sent by the Storage SDK.
@amnguye thanks for your reply. we expect so too, but how do we disable this cache? can you provide more instructions for it? Thanks
Sorry for the late reply. A cache could be implemented in many places (e.g. firewall, network, client-side). I can't provide you specific instructions on how to disable it since it's not SDK related.
Also related to this issue https://github.com/Azure/azure-sdk-for-net/issues/24635#issuecomment-944470427
Is there any update on this? Or any way to get around this issue? I really need to be able to list files in a storage account, and everything I do inside a C# azure function gets me to the same error.
Library name and version
Azure.Storage.Blobs 12.16.0
Describe the bug
Iterating through the result of BlobContainerClient.GetBlobsAsync or GetBlobs throws Azure.RequestFailedException with message: "Response x-ms-client-request-id 'xxx' does not match the original expected request id, 'yyy'."
This only happens in subsequent runs, not in initial run. In my test application, doing either these two will 'fix' the issue:
The download uri is a SAS uri with custom domain. I tried setting the clientOptions.Retry.Mode to exponential and maxretry=5 but it doesnt solve the issue
Expected behavior
Blobs retrieved successfully
Actual behavior
It throws Azure.RequestFailedException with message: "Response x-ms-client-request-id 'xxx' does not match the original expected request id, 'yyy'."
Reproduction Steps
The line
await foreach (var blob in blobs)
throws Azure.RequestFailedException with message: "Response x-ms-client-request-id 'xxx' does not match the original expected request id, 'yyy'." Stack trace:The downloadUri is a SAS uri with custom domain.
Environment
.NET SDK: Version: 7.0.202 Commit: 6c74320bc3
Runtime Environment: OS Name: Windows OS Version: 10.0.19044 OS Platform: Windows RID: win10-x64 Base Path: C:\Program Files\dotnet\sdk\7.0.202\
Host: Version: 7.0.4 Architecture: x64 Commit: 0a396acafe
The application is running in .net 6