Repository navigation
Conversation
Signed-off-by: Cathleen Yan <58714163+cathleeny@users.noreply.github.com> Co-authored-by: Isaac <no-reply@databricks.com>
cathleeny
marked this pull request as ready for review
December 3, 2026 20:26
There was a problem hiding this comment.
🔀 Cross-reviewed: two independent reviews (Claude Opus 5.5 · GPT-6.1 Sol), checked by a judge model (Claude Sonnet 5.5).
Verdict: 1 Medium · 2 Low
Looks good, with 1 medium and 1 low concern. The cache, subject tracking and superseded-flight handling hold up under the tests. The weak spots are how cancellation propagates through the shared exchange and the expiry assumed for tokens the server doesn't date.
This overview is Claude Opus 5.5's initial take; GPT-6.1 Sol added findings it doesn't mention — see the findings below.
Signed-off-by: Cathleen Yan <58714163+cathleeny@users.noreply.github.com> Co-authored-by: Isaac <no-reply@databricks.com>
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Avoid an RFC 8693 exchange on every Thrift request by caching tokens in the federation provider, mirroring databricks/databricks-sql-nodejs#660. The same cache also applies to kernel requests once #610 routes them through this provider.
Changes
Reuse exchanged tokens until their subject changes or they near expiry, coalesce concurrent exchanges, and temporarily cache fallback tokens before retrying.
Tests
Build, vet, lint, default unit tests, and token-provider race tests passed. Kernel-tagged token-provider tests passed; no live or end-to-end tests were run.
This pull request and its description were written by Isaac.