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

Add api ver to path in opsgenie client #29256

Merged
merged 3 commits into from
Jul 21, 2023

Conversation

EdwardDowling
Copy link
Contributor

@EdwardDowling EdwardDowling commented Jul 18, 2023

Add the missing api version num to api endpoint.

@EdwardDowling EdwardDowling marked this pull request as ready for review July 18, 2023 15:55
@@ -78,7 +78,6 @@ func (c *Config) NewBot(clusterName, webProxyAddr string) (common.MessagingBot,
}
c.ClientConfig.WebProxyURL = webProxyURL
c.ClientConfig.ClusterName = clusterName
c.ClientConfig.APIKey = c.Opsgenie.Token
Copy link
Collaborator

Choose a reason for hiding this comment

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

Why was this removed?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

This line was not meant to be committed originally.

@@ -123,7 +123,7 @@ func (og Client) CreateAlert(ctx context.Context, reqID string, reqData RequestD
SetContext(ctx).
SetBody(body).
SetResult(&result).
Post("alerts")
Post("v2/alerts")
Copy link
Collaborator

Choose a reason for hiding this comment

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

How come we didn't detect this issue during testing?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Had the api kjey hardcoded locally as https://api.opsgenie.com/v2/ during testing before frontend was added. Forgot to remove it when it was, so never noticed the options were set to 'https://api.opsgenie.com' [here](value: 'https://api.opsgenie.com',).

@public-teleport-github-review-bot public-teleport-github-review-bot bot removed the request for review from hugoShaka July 20, 2023 14:39
@EdwardDowling EdwardDowling added this pull request to the merge queue Jul 21, 2023
Merged via the queue into master with commit 9bbd7ba Jul 21, 2023
21 checks passed
@EdwardDowling EdwardDowling deleted the edwarddowling/opsgenie-healthcheck-fix branch July 21, 2023 15:36
@public-teleport-github-review-bot

@EdwardDowling See the table below for backport results.

Branch Result
branch/v13 Create PR

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.

None yet

3 participants