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

Implement retry logger #1041

Open
wants to merge 8 commits into
base: main
Choose a base branch
from

Conversation

MarkDordoy
Copy link
Contributor

@MarkDordoy MarkDordoy commented Mar 3, 2023

This PR implements the retry client and logs retry requests and responses in the format of:

[DEBUG] ============================ Begin AzureAD Request Retry Attempt 3 ============================
Request ID: c4900726-f75a-d7f9-c89d-a0e26f0b69ec

GET /beta/bd28a687-b2a9-420b-81f4-0a56c932c8a2/applications/bf148948-7115-4a0f-b913-d05595aa3bf9 HTTP/1.1
Host: graph.microsoft.us
User-Agent: HashiCorp Terraform/1.3.1 (+https://www.terraform.io) Terraform Plugin SDK/2.10.1 terraform-provider-azuread/dev Hamilton (Go-http-client/1.1) pid-222c6c49-1b0a-5959-a213-6608f9eb8820
Accept: application/json; charset=utf-8; IEEE754Compatible=false
Content-Type: application/json; charset=utf-8
Odata-Maxversion: 4.0
Odata-Version: 4.0
Accept-Encoding: gzip


============================= End AzureAD Request Retry Attempt =============================

Having this will be really handy. When we hit API issues and need to provide evidence to Microsoft they dont always believe us that a 404 happens after x number of retries. Having this log will be really helpful

@github-actions github-actions bot added size/S and removed size/XS labels Mar 3, 2023
@github-actions github-actions bot added size/M and removed size/S labels Mar 3, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant