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

chore(sentry apps): add slos for issue link req #87775

Merged
merged 9 commits into from
Mar 31, 2025

Conversation

Christinarlong
Copy link
Contributor

@Christinarlong Christinarlong commented Mar 24, 2025

Very similar to the SelectRequester external request SLOs. This module we send out a request to the 3p telling them this user would like to link their Sentry issue to your ext platform.
The failure modes for this module are almost the same for SelectRequester

We can fail in a few ways here:

  • Integrator returns some bad error code (400-500) -> halt
  • Integrator returns some bad response -> halt
  • Some other Unexpected Error -> failure

@github-actions github-actions bot added the Scope: Backend Automatically applied to PRs that change backend components label Mar 24, 2025
Copy link

codecov bot commented Mar 24, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

✅ All tests successful. No failed tests found.

Additional details and impacted files
@@            Coverage Diff             @@
##           master   #87775      +/-   ##
==========================================
+ Coverage   87.73%   87.79%   +0.06%     
==========================================
  Files        9991     9968      -23     
  Lines      565181   565079     -102     
  Branches    22276    22146     -130     
==========================================
+ Hits       495840   496109     +269     
+ Misses      68919    68569     -350     
+ Partials      422      401      -21     

@Christinarlong Christinarlong marked this pull request as ready for review March 25, 2025 14:32
@Christinarlong Christinarlong requested review from a team as code owners March 25, 2025 14:32
@Christinarlong Christinarlong requested a review from cathteng March 25, 2025 14:33
Comment on lines 96 to 98
halt_reason = FAILURE_REASON_BASE.format(
SentryAppExternalRequestHaltReason.BAD_RESPONSE
)
Copy link
Member

Choose a reason for hiding this comment

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

nit: maybe make this into a variable and reuse instead of declaring this 3x?

Copy link
Member

Choose a reason for hiding this comment

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

same thing with recording the halt 🤔

Copy link
Contributor Author

Choose a reason for hiding this comment

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

okes to the reusing of the halt reason, though I think it's okay to keep the halt part since, imo, it's a bit easier to trace, that in this flow we recorded a halt for this use case.

halt_reason = FAILURE_REASON_BASE.format(
SentryAppExternalRequestHaltReason.BAD_RESPONSE
)
extras["error_message"] = str(e)
Copy link
Member

Choose a reason for hiding this comment

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

nit: you are already recording the exception as the halt reason, do you also need to add it to extras?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

We're add the error_message here to be included in the webhook_context for the integrator, but yes it's redundant for the context manager.

@Christinarlong Christinarlong merged commit a9054a5 into master Mar 31, 2025
48 checks passed
@Christinarlong Christinarlong deleted the crl/slos-issue-link branch March 31, 2025 20:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Scope: Backend Automatically applied to PRs that change backend components
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants