Repository navigation
feat(rest): load table credentials from the LoadCredentials endpoint - #899
Merged
Merged
Conversation
plusplusjiajia
force-pushed
the
feat-rest-load-credentials
branch
from
August 24, 2026 10:40
e65abbc to
eedf884
Compare
plusplusjiajia
force-pushed
the
feat-rest-load-credentials
branch
2 times, most recently
from
September 15, 2026 06:37
0435ab7 to
7ccee12
Compare
plusplusjiajia
force-pushed
the
feat-rest-load-credentials
branch
from
September 26, 2026 05:53
7ccee12 to
c4ddad8
Compare
plusplusjiajia
force-pushed
the
feat-rest-load-credentials
branch
from
September 29, 2026 04:19
c4ddad8 to
c0f1a6e
Compare
plusplusjiajia
marked this pull request as ready for review
September 29, 2026 05:30
Replace the opaque refresh callback with a typed provider and two-phase FileIO credential initialization. Keep REST fetching encapsulated and preserve resolver delegate setup.
wgtmac
approved these changes
Oct 8, 2026
wgtmac
left a comment
Member
There was a problem hiding this comment.
I pushed a small update that replaces the refresh callback with a typed StorageCredentialProvider::Load() and initializes each FileIO with both initial credentials and the provider before first use; SetStorageCredentials() remains for later same-scope updates. This keeps REST endpoint/auth/query details inside the REST provider, keeps ResolvingFileIO simple, and avoids exposing opaque callback or late-initialization state.
Thanks for adding this and sorry for the long delay!
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.
Adds the plumbing for replacing vended storage credentials, deliberately without any policy:
StorageCredentialProvider(a typed source returning the vended list) andInitializeStorageCredentials, which installs the initial credentials and provider before first use.SetStorageCredentialsremains for later same-scope updates.LoadCredentialsResponseand its parsing.storage-credentialsis required here per the REST spec, unlike LoadTable where it stays optional: reading a malformed response as "no credentials" would look like a refresh that succeeded and dropped them. Parse errors deliberately do not carry the response body — it contains the credentials themselves.RestCatalog::MakeStorageCredentialProviderbuilds a provider from the LoadCredentials endpoint with the table session, keeping the REST path and session ownership inside the provider. Both paths that cannot build one say so in the log, since the consequence only surfaces much later as credentials expiring mid-job.ResolvingFileIOforwards the installed provider to resolved delegates during credential initialization. Loads snapshot the provider together with the credentials, and credential installs bump the generation, so a delegate loaded from an older set is rebuilt rather than cached.Nothing invokes the provider yet; the policy that does arrives in the final PR of this series (#892).
MakeStorageCredentialProvideritself has no unit test —HttpClientis concrete, with no seam to fake. It was verified end-to-end against a live credential-vending catalog: endpoint advertised, GET succeeding, response parsing, and IO continuing on the replacements.