-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
Add request_reason provider support #5037
Add request_reason provider support #5037
Conversation
Oops! It looks like no changelog entry is attached to this PR. Please include a release note block in the PR body, as described in https://github.com/GoogleCloudPlatform/magic-modules/blob/master/.ci/RELEASE_NOTES_GUIDE.md:
|
Hello! I am a robot who works on Magic Modules PRs. I have detected that you are a community contributor, so your PR will be assigned to someone with a commit-bit on this repo for initial review. Thanks for your contribution! A human will be with you soon. @rileykarson, please review this PR or find an appropriate assignee. |
Hi! I'm the modular magician. Your PR generated some diffs in downstreams - here they are. Diff report:Terraform GA: Diff ( 4 files changed, 12 insertions(+), 2 deletions(-)) |
Hi! I'm the modular magician. Your PR generated some diffs in downstreams - here they are. Diff report:Terraform GA: Diff ( 4 files changed, 16 insertions(+), 2 deletions(-)) |
Hi! I'm the modular magician. Your PR generated some diffs in downstreams - here they are. Diff report:Terraform GA: Diff ( 4 files changed, 16 insertions(+), 2 deletions(-)) |
Our CI got broken, would you mind rebasing? That should make it run correctly. |
@@ -148,6 +148,8 @@ the provider should wait for a single HTTP request. This will not adjust the | |||
amount of time the provider will wait for a logical operation - use the resource | |||
timeout blocks for that. | |||
|
|||
* `request_reason` - (Optional) Send a Request Reason [System Parameter](https://cloud.google.com/apis/docs/system-parameters) for each API call made by the provider. The `X-Goog-Request-Reason` header value is used to provide a user-supplied justification into GCP AuditLogs. The value set within the provider is overridden if `CLOUDSDK_CORE_REQUEST_REASON` environment variable is used. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should be added under "Full Reference" as well. For consistency with the rest of the file, we should only include the env var there and use text like Alternatively, this can be specified using the 'CLOUDSDK_CORE_REQUEST_REASON' environment variable.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Provider config will override the environment variable w/ this implementation (which is the correct behaviour imo) so the docs should reflect as much!
/gcbrun may be all that's required (rather than needing to rebase) |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
didn't do the rebase per previous comments but did address comments above |
This comment has been minimized.
This comment has been minimized.
/gcbrun - CI issue is now resolved |
Hi! I'm the modular magician. Your PR generated some diffs in downstreams - here they are. Diff report:Terraform GA: Diff ( 4 files changed, 21 insertions(+), 5 deletions(-)) |
Hi! I'm the modular magician. Your PR generated some diffs in downstreams - here they are. Diff report:Terraform GA: Diff ( 4 files changed, 21 insertions(+), 5 deletions(-)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
suggest rewriting for a cleaner implementation. headerTransport is an extension of http.Header
Hi! I'm the modular magician. Your PR generated some diffs in downstreams - here they are. Diff report:Terraform GA: Diff ( 4 files changed, 20 insertions(+), 4 deletions(-)) |
I have triggered VCR tests in RECORDING mode for the following tests that failed during VCR: You can view the result here: https://ci-oss.hashicorp.engineering/viewQueued.html?itemId=200384 |
@@ -148,6 +148,8 @@ the provider should wait for a single HTTP request. This will not adjust the | |||
amount of time the provider will wait for a logical operation - use the resource | |||
timeout blocks for that. | |||
|
|||
* `request_reason` - (Optional) Send a Request Reason [System Parameter](https://cloud.google.com/apis/docs/system-parameters) for each API call made by the provider. The `X-Goog-Request-Reason` header value is used to provide a user-supplied justification into GCP AuditLogs. The value set within the provider is overridden if `CLOUDSDK_CORE_REQUEST_REASON` environment variable is used. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Provider config will override the environment variable w/ this implementation (which is the correct behaviour imo) so the docs should reflect as much!
Hi! I'm the modular magician. Your PR generated some diffs in downstreams - here they are. Diff report:Terraform GA: Diff ( 4 files changed, 20 insertions(+), 4 deletions(-)) |
Error trying to cancel build () |
Hi! I'm the modular magician. Your PR generated some diffs in downstreams - here they are. Diff report:Terraform GA: Diff ( 4 files changed, 20 insertions(+), 4 deletions(-)) |
Error trying to cancel build () |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
seems reasonable to me
mmv1/third_party/terraform/website/docs/guides/provider_reference.html.markdown
Outdated
Show resolved
Hide resolved
Hi! I'm the modular magician. Your PR generated some diffs in downstreams - here they are. Diff report:Terraform GA: Diff ( 4 files changed, 20 insertions(+), 4 deletions(-)) |
Error trying to cancel build () |
1 similar comment
Error trying to cancel build () |
/gcbrun |
Hi! I'm the modular magician. Your PR generated some diffs in downstreams - here they are. Diff report:Terraform GA: Diff ( 4 files changed, 20 insertions(+), 4 deletions(-)) |
Error trying to cancel build () |
2 similar comments
Error trying to cancel build () |
Error trying to cancel build () |
I have triggered VCR tests in RECORDING mode for the following tests that failed during VCR: You can view the result here: https://ci-oss.hashicorp.engineering/viewQueued.html?itemId=200705 |
I have triggered VCR tests in RECORDING mode for the following tests that failed during VCR: TestAccComputeRouterPeer_advertiseMode You can view the result here: https://ci-oss.hashicorp.engineering/viewQueued.html?itemId=200804 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ScottSuarez: You looked at this more recently (w/ the linked issue below), I'll leave the merge to you
fixes hashicorp/terraform-provider-google#9724
PR Description
...