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

sentry: log error on raven/capture! failure #59

Merged
merged 1 commit into from
Jun 22, 2022

Conversation

bcachet
Copy link
Member

@bcachet bcachet commented Jun 22, 2022

When raven/capture! is failing we do not log anything
We keep current error logging with the sentry-id (useful to link Kibana logs with Sentry)

When `raven/capture!` is failing we do not log anything
We keep current error logging with the sentry-id (useful to link Kibana logs with Sentry)
(error e (str "captured exception as sentry event: " event-id))))
(d/catch (fn [e']
(error e "Failed to capture exception" {:tags tags :capture-exception e'})
(capture! this e'))))
Copy link
Member

Choose a reason for hiding this comment

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

If I understand correctly, in case of an error, we are going to log the previous error e and capture the raven error failure e' – i.e. in raven, right?

Copy link
Member Author

Choose a reason for hiding this comment

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

Exactly, instead of throwing from reporter/capture! and relying on calling service error handling to capture it

Choose a reason for hiding this comment

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

There is no change we'll end up on an infinite loop there?
Shall we call raven/capture! instead?

Copy link
Member Author

Choose a reason for hiding this comment

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

We are calling capture! on the raven exception that we should be able to capture (and experience show we are)

Copy link
Contributor

Choose a reason for hiding this comment

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

@arnaudgeiser I don't think we'll do b/c e' does not capture e in its context

@jeremyvdw jeremyvdw self-requested a review June 22, 2022 08:57
@bcachet bcachet merged commit a6c3d73 into master Jun 22, 2022
@bcachet bcachet deleted the sentry_log-capture-failure branch June 22, 2022 08:59
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.

None yet

4 participants