Skip to content

fix(compute/metadata): fix retry logic to not panic on error#4714

Merged
gcf-merge-on-green[bot] merged 11 commits intogoogleapis:masterfrom
codyoss:fix-meta-retry
Sep 2, 2021
Merged

fix(compute/metadata): fix retry logic to not panic on error#4714
gcf-merge-on-green[bot] merged 11 commits intogoogleapis:masterfrom
codyoss:fix-meta-retry

Conversation

@codyoss
Copy link
Copy Markdown
Member

@codyoss codyoss commented Sep 1, 2021

In the case of an error res will be nil. Also, we should not break on nil err
as it might be eligible for a retry from the status code.

Fixes: #4713

In the case of an error res will be nil.

Fixes: #4713
@codyoss codyoss requested a review from a team September 1, 2021 16:04
@product-auto-label product-auto-label bot added the api: compute Issues related to the Compute Engine API. label Sep 1, 2021
@google-cla google-cla bot added the cla: yes This human has signed the Contributor License Agreement. label Sep 1, 2021
Comment thread compute/metadata/retry.go Outdated
@codyoss codyoss added the kokoro:force-run Add this label to force Kokoro to re-run the tests. label Sep 1, 2021
@kokoro-team kokoro-team removed the kokoro:force-run Add this label to force Kokoro to re-run the tests. label Sep 1, 2021
@codyoss codyoss added the automerge Merge the pull request once unit tests and other checks pass. label Sep 2, 2021
@gcf-merge-on-green gcf-merge-on-green bot merged commit 75c63b9 into googleapis:master Sep 2, 2021
@gcf-merge-on-green gcf-merge-on-green bot removed the automerge Merge the pull request once unit tests and other checks pass. label Sep 2, 2021
@codyoss codyoss deleted the fix-meta-retry branch September 11, 2021 19:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

api: compute Issues related to the Compute Engine API. cla: yes This human has signed the Contributor License Agreement.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

compute/metadata: retryer tries to get the status code from the resource that does not exist

4 participants