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

snowflake oauth: take refresh_token instead of access_token #2126

Closed
cmcarthur opened this issue Feb 12, 2020 · 1 comment · Fixed by #2141
Closed

snowflake oauth: take refresh_token instead of access_token #2126

cmcarthur opened this issue Feb 12, 2020 · 1 comment · Fixed by #2141
Labels
enhancement New feature or request snowflake
Milestone

Comments

@cmcarthur
Copy link
Member

cmcarthur commented Feb 12, 2020

Instead of just using the access_token to make requests (it only lasts 10 minutes), use the refresh_token to generate an access token. A reasonable naive solution would be to do this right before creating a handle / issuing a query. Once a connection is open, it should be available for the normal amount of time (4 hours?)

If snowflake returns an error specifically saying that the refresh token is expired, it would be nice if dbt could return that error so that cloud could consume it

@drewbanin drewbanin added this to the 0.15.3 milestone Feb 12, 2020
@drewbanin drewbanin added enhancement New feature or request snowflake labels Feb 12, 2020
beckjake added a commit that referenced this issue Feb 19, 2020
@beckjake
Copy link
Contributor

Fixed in #2141, merged into the 0.15.3 branch.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request snowflake
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants