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

forward headers #90

Merged
merged 3 commits into from
May 8, 2023
Merged

forward headers #90

merged 3 commits into from
May 8, 2023

Conversation

scottlepp
Copy link
Collaborator

@scottlepp scottlepp commented May 5, 2023

forward headers for sql datasources. this allows pass through oauth tokens

this was a bit hard to do without breaking compatibility

when a sql ds first connects, it happens before queryData/checkHealth. so it will not have the headers yet since those are applied as middleware on queryData and checkHealth. so the first "ping" will fail. sqlds allows retries and defining what errors to retry on, so the datasource can retry on "bad token" or whatever the underlying database returns. then retry will then reconnect and will have the headers available and a new connection is established with the headers

@scottlepp scottlepp requested a review from a team May 5, 2023 19:53
@scottlepp scottlepp merged commit 29ba2a5 into main May 8, 2023
3 checks passed
@scottlepp scottlepp deleted the forward-headers branch May 8, 2023 12:32
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.

None yet

1 participant