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

Retryable http client in Sumologic TF provider masking error code bug fix. #610

Merged
merged 4 commits into from
Jan 24, 2024

Conversation

kaushik-sumo
Copy link
Collaborator

Sumo logic provider does not show the error code contained in the HTTP response, but only prints out generic: “failed after 11 attempts“. This was thrown by the HTTP client and was not handled. By adding an error handler in the retryable client it can be handled.

Logs printing after changes and testing in error handler: [ERROR] Request https://long-api.sumologic.net/api/v1/monitors/root failed after 2 attempts with response: [500 Internal Server Error]

Logs printing after changes and testing in API logs:
[DEBUG] Request: [Method=GET] [URL=https://long-api.sumologic.net/api/v1/monitors/root] [Headers=map[Authorization:[xxxxxxxxxxx] Content-Type:[application/json] User-Agent:[SumoLogicTerraformProvider/dev]]]. Response: [Status=500 Internal Server Error]

Copy link
Contributor

@dagould dagould left a comment

Choose a reason for hiding this comment

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

Approving to unblock, but should this have a CHANGELOG entry? Does this affect user-visible error responses, or is it just in our logs?

Other than that, lgtm.

kaushik-sumo added a commit that referenced this pull request Jan 24, 2024
Added bug fixes in 2.28.2 unreleased for GH-610.
@kaushik-sumo kaushik-sumo merged commit 7685d51 into master Jan 24, 2024
3 checks passed
@kaushik-sumo kaushik-sumo deleted the Test branch January 24, 2024 06:00
@kaushik-sumo
Copy link
Collaborator Author

Approving to unblock, but should this have a CHANGELOG entry? Does this affect user-visible error responses, or is it just in our logs?

Other than that, lgtm.

Yes, it is a user-facing change.
Added a changelog entry here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants