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

feat: Moving configuration and auth logic #37

Merged
merged 5 commits into from
Oct 17, 2023

Conversation

mnorbury
Copy link
Contributor

@mnorbury mnorbury commented Oct 16, 2023

This is being moved from cloudquery/cli to allow it to be shared by both the plugin-sdk and cloudquery/cli components.

This may not be the best place for this code in the long run, but for now we want to share the code between cloudquery/cli and plugin-sdk without having cloudquery/cli introduce a dependency on the plugin-sdk.

This PR also modifies the token issuing logic, to only refresh the ID token if the existing token is close to expiry. This is to minimise the API calls needed during the sync upsert process.

@mnorbury mnorbury marked this pull request as ready for review October 16, 2023 09:51
@mnorbury mnorbury force-pushed the feat/allow-shareable-cli-configuration branch from 969a6a2 to b3bbc69 Compare October 17, 2023 08:24
This is being moged from cloudquery/cli to allow it to be shared by both
the `plugin-sdk` and `cloudquery/cli` components.

fixes: cloudquery/cloudquery-issues#668
@mnorbury mnorbury force-pushed the feat/allow-shareable-cli-configuration branch from b3bbc69 to f1309cf Compare October 17, 2023 08:59
@mnorbury mnorbury force-pushed the feat/allow-shareable-cli-configuration branch from f1309cf to a6df06a Compare October 17, 2023 09:16
@@ -0,0 +1,8 @@
.PHONY: test
test:
go test -tags=assert -race ./...
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

-tags=assert is for Arrow tests, we don't need this I think... just fyi :) (still it could be beneficial to keep it...)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah, I wasn't quite sure what that was for. Good to know.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah good call, let's remove it :)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry, missed the request - follow up here

@mnorbury mnorbury added the automerge Add to automerge PRs once requirements are met label Oct 17, 2023
@kodiakhq kodiakhq bot merged commit 0bffdb2 into main Oct 17, 2023
1 check passed
@kodiakhq kodiakhq bot deleted the feat/allow-shareable-cli-configuration branch October 17, 2023 11:46
kodiakhq bot pushed a commit that referenced this pull request Oct 17, 2023
🤖 I have created a release *beep* *boop*
---


## [1.3.0](v1.2.9...v1.3.0) (2023-10-17)


### Features

* Moving configuration and auth logic ([#37](#37)) ([0bffdb2](0bffdb2))

---
This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
automerge Add to automerge PRs once requirements are met
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants