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

[db] wait for token to propagate #10431

Merged
merged 1 commit into from
Mar 14, 2024
Merged

Conversation

FredKSchott
Copy link
Member

@FredKSchott FredKSchott commented Mar 13, 2024

Changes

  • A new attempt to solve this problem: [db] Pass preferred region for token management #10428
  • That PR did solve the problem when each region had a single machine running, but failed to account for replication across multiple machines in the same region.
  • In practice, Machine A in region sjc could create your token and Machine B (also in region sjc) could attempt to use it before it's been propagated. Pinning to region sjc did not solve the problem in that case.
  • The new solution removes the complexity of the original one, and now just embraces replication as something to wait for vs. trying to build around and solve for. It adds a delay on token creation greater than the maximum time our tokens take to propagate (2sec of wait vs. 1600ms of maximum token propagation). In the near future, we should be able to get this down closer to 1sec of wait time.
Untitled.mov

Testing

  • Tested manually

Docs

  • N/A

Copy link

changeset-bot bot commented Mar 13, 2024

🦋 Changeset detected

Latest commit: 05db6f1

The changes in this PR will be included in the next version bump.

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@FredKSchott FredKSchott force-pushed the new-solution-token-problem branch from 1b0aeec to 05db6f1 Compare March 13, 2024 23:06
@matthewp
Copy link
Contributor

Approved to get this fix out the door. Would love to discuss trying to figure out a deterministic solution for the future.

@FredKSchott FredKSchott merged commit 1076864 into main Mar 14, 2024
13 checks passed
@FredKSchott FredKSchott deleted the new-solution-token-problem branch March 14, 2024 15:57
@astrobot-houston astrobot-houston mentioned this pull request Mar 14, 2024
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.

2 participants