Title: Error handling within Hapi Sentry integration · Issue #11069 · getsentry/sentry-javascript · GitHub
Open Graph Title: Error handling within Hapi Sentry integration · Issue #11069 · getsentry/sentry-javascript
X Title: Error handling within Hapi Sentry integration · Issue #11069 · getsentry/sentry-javascript
Description: Problem Statement We're looking into switching from the third-party hapi-sentry package to Sentry's built-in Hapi support, mainly to benefit from the added tracing support. However, the built-in Hapi support has what seems to be a potent...
Open Graph Description: Problem Statement We're looking into switching from the third-party hapi-sentry package to Sentry's built-in Hapi support, mainly to benefit from the added tracing support. However, the built-in Ha...
X Description: Problem Statement We're looking into switching from the third-party hapi-sentry package to Sentry's built-in Hapi support, mainly to benefit from the added tracing support. However, the bui...
Opengraph URL: https://github.com/getsentry/sentry-javascript/issues/11069
X: @github
Domain: github.com
IPv4 address: 140.82.112.3
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Error handling within Hapi Sentry integration","articleBody":"### Problem Statement\r\n\r\nWe're looking into switching from the third-party [hapi-sentry](https://github.com/hydra-newmedia/hapi-sentry) package to Sentry's [built-in Hapi support](https://github.com/getsentry/sentry-javascript/pull/9539), mainly to benefit from the added tracing support. However, the built-in Hapi support has what seems to be a potentially unwanted feature: every [Hapi Boom](https://github.com/hapijs/boom) response (i.e., every HTTP 4xx or 5xx response) is captured as a Sentry exception.\r\n\r\nIs this intended? I would expect that Sentry exceptions are for things that are very likely programming errors, not conditions like bad or unauthorized requests (HTTP 4xx) that are often outside of the application's control.\r\n\r\n### Solution Brainstorm\r\n\r\n1. Add an option to `Integrations.Hapi` to configure the error plugin and tracing plugin separately (so we could continue to use the third-party hapi-sentry).\r\n2. More directly expose / export `hapiErrorPlugin` and `hapiTracingPlugin` so that I can add one or the other or both to my Hapi server myself (and can then pick hapi-sentry over `hapiErrorPlugin`).\r\n4. Add an option to `Integrations.Hapi` to control whether the error plugin captures Boom replies as exceptions.\r\n5. Don't capture Boom replies by default.\r\n3. Some combination of the above.","author":{"url":"https://github.com/joshkel","@type":"Person","name":"joshkel"},"datePublished":"2024-03-12T21:56:10Z","url":"https://github.com/getsentry/sentry-javascript/issues/11069"}
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322 |
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:edb408cb-ff63-4200-f7a0-180a4d68b0e5 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | D0E2:103A59:3EB515F:5315196:6B03F0C3 |
| html-safe-nonce | 7bf4566d870baa9e5edaa66bfc76fc31aa1a9147298b6639e75db08b49101db6 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJEMEUyOjEwM0E1OTozRUI1MTVGOjUzMTUxOTY6NkIwM0YwQzMiLCJ2aXNpdG9yX2lkIjoiMTE4OTM1OTEwNjk5ODM5OTE3MSIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | 1d479e65d36b23eace2da415512f23a50419d5e7ad47c6ebee2616975fdd76d9 |
| hovercard-subject-tag | issue:2182760618 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/getsentry/sentry-javascript/11069/issue_layout |
| twitter:image | https://opengraph.githubassets.com/797c9b981198124257f6608c6c9a1430390c515df2eebad2ed3fe3b6e4731257/getsentry/sentry-javascript/issues/11069 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/797c9b981198124257f6608c6c9a1430390c515df2eebad2ed3fe3b6e4731257/getsentry/sentry-javascript/issues/11069 |
| og:image:alt | Problem Statement We're looking into switching from the third-party hapi-sentry package to Sentry's built-in Hapi support, mainly to benefit from the added tracing support. However, the built-in Ha... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | joshkel |
| hostname | github.com |
| expected-hostname | github.com |
| None | 87e774ee7c6b3bee0490394e4d3e57ec9dbc956f74b87ea685dc8996c1676456 |
| turbo-cache-control | no-preview |
| go-import | github.com/getsentry/sentry-javascript git https://github.com/getsentry/sentry-javascript.git |
| octolytics-dimension-user_id | 1396951 |
| octolytics-dimension-user_login | getsentry |
| octolytics-dimension-repository_id | 3328572 |
| octolytics-dimension-repository_nwo | getsentry/sentry-javascript |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 3328572 |
| octolytics-dimension-repository_network_root_nwo | getsentry/sentry-javascript |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 423dbb54c5e7bfecc838eb387c1435eb3d0e760d |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
| Server | github.com |
| Content-Type | text/html; charset=utf-8 |
| Cache-Control | max-age=0, private, must-revalidate |
Viewport: width=device-width