-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
Update provider reference docs on quota usage and always use billing_project as quota project if appropriately specified #12411
base: main
Are you sure you want to change the base?
Conversation
…project as quota specified
Adding comment from bug for @SarahFrench So current behavior is we don't read quota-project from ADC at all. First they attempt to read from an env variable. Then they attempt to read from a 'well-known-file' aka adc. then then fall back to GCE compute runtime credentials. The projectId you are seeing never correlates to QuotaProjectID. This is the credential file's projectID which is still different from the quota project id. I don't know the significance of the project id here. I suspect its the project that credentials were created from. It's worth noting that the oauth2 library does pass back the raw credential json bits which google-api library exposes an accessor of. Basically they just index into the raw credential json to see if quota project is there as a fallback. It's also worth noting that they reference a env variable for quota project To align with googleapis library and general naming convention I would recommend we sunset billing project terminology in favor of quota_project. Also to add I think the only thing left I didn't cover is why we don't receive this quota project if google apis library has accessor functions for it. This is because the transport library we use to create our client transport doesn't have the rawjson in the credential object available because we only pass token source for credentials and their client library doesn't read thefull object. GetQuotaProject needs the rawJSON in the credentials object to parse the quota-project from the credential file. TLDRgoogle apis client library is kind of funky and the way we interact with it doesn't auto get quota project parsing from the credential file. We should probably handle it ourselves anyways. There is currently undocumented behavior of |
Created two child issues. |
Just a heads up that some of the files affected by this PR have been deleted as part of the muxing fixes. Instead of parallel implementations of logic that handles credentials etc there are now only the original versions that date from when the provider was 100% SDK-implemented |
…odules into update-provider-ref-docs
all good :) |
Hi there, I'm the Modular magician. I've detected the following information about your changes: Diff reportYour PR generated some diffs in downstreams - here they are.
Errors
|
Tests analyticsTotal tests: 0 Click here to see the affected service packages
🔴 Errors occurred during REPLAYING mode. Please fix them to complete your PR. View the build log |
Hi there, I'm the Modular magician. I've detected the following information about your changes: Diff reportYour PR generated some diffs in downstreams - here they are.
|
Tests analyticsTotal tests: 4317 Click here to see the affected service packages
Action takenFound 2 affected test(s) by replaying old test recordings. Starting RECORDING based on the most recent commit. Click here to see the affected tests
|
🟢 Tests passed during RECORDING mode: 🔴 Tests failed when rerunning REPLAYING mode: Tests failed due to non-determinism or randomness when the VCR replayed the response after the HTTP request was made. Please fix these to complete your PR. If you believe these test failures to be incorrect or unrelated to your change, or if you have any questions, please raise the concern with your reviewer. 🔴 Tests failed during RECORDING mode: 🔴 Errors occurred during RECORDING mode. Please fix them to complete your PR. |
closes hashicorp/terraform-provider-google#17882
b/360405077#comment8
Release Note Template for Downstream PRs (will be copied)
See Write release notes for guidance.