Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upsert item: Fixes a bug causing session tokens for PKRangeId 0 to be overridden by session token for another partition on upserts #3102

Conversation

FabianMeiswinkel
Copy link
Member

Pull Request Template

Description

TransportHandler.ProcessUpsertAsync was capturing session tokens even for throttled (or failed) requests. Because throttled requests (or 449/410) won't always have a PKRangeId header this resulted in session tokens for PKRangeId 0 being overridden with the session token of another partition. There is no reason to ever capture a session token on a 429, 449 or 410 - and it turned out there was also no need for the special-casing of upserts in TransportHandler.

So, this PR is...

  • removing the special casing of upserts in TransportHandler
  • adding regression test (NoSessionTokenCaptureForThrottledUpsertRequestsTest failed without the change in TransportHandler - now succeeds)
  • adding basic coverage to ensure session tokens are captured for point operations (main validation for this is in Direct package)

Type of change

Please delete options that are not relevant.

  • Bug fix (non-breaking change which fixes an issue)

…y session token for another partition on upserts
@ealsur ealsur enabled auto-merge (squash) March 22, 2022 14:27
@j82w j82w changed the title Fixes a bug causing session tokens for PKRangeId 0 to be overridden by session token for another partition on upserts Upsert item: Fixes a bug causing session tokens for PKRangeId 0 to be overridden by session token for another partition on upserts Mar 22, 2022
@j82w j82w disabled auto-merge March 22, 2022 14:57
@j82w j82w enabled auto-merge (squash) March 22, 2022 14:57
@j82w j82w merged commit 6bbe69b into Azure:master Mar 22, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants