From fa194909045c71a9528476b5c735ac208902e1fe Mon Sep 17 00:00:00 2001 From: BeckaL Date: Tue, 9 May 2023 17:54:36 +0100 Subject: [PATCH 1/2] Add HttpParserError to excluded exceptions Sentry ruby 5.9 ensured that low level puma errors were captured [1] and propagated to sentry. This ended up in a lot of noise [2] in sentry when applications were bumped to this version of sentry ruby, particularly with Puma::HttpParser errors. These errors are often unactionable and we believe a result of crawler activity. This suppresses these errors in order to reduce sentry noise. 1: https://github.com/getsentry/sentry-ruby/pull/2026 2: https://govuk.sentry.io/issues/4154286086/?project=202217 --- lib/govuk_app_config/govuk_error/configuration.rb | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/govuk_app_config/govuk_error/configuration.rb b/lib/govuk_app_config/govuk_error/configuration.rb index fc23499..a90e3fc 100644 --- a/lib/govuk_app_config/govuk_error/configuration.rb +++ b/lib/govuk_app_config/govuk_error/configuration.rb @@ -41,6 +41,7 @@ def set_up_defaults "GdsApi::HTTPIntermittentServerError", "GdsApi::TimedOutException", "Mongoid::Errors::DocumentNotFound", + "Puma::HttpParserError", "Sinatra::NotFound", "Slimmer::IntermittentRetrievalError", "Sidekiq::JobRetry::Skip", From 53e3173618dd57941a4d886251e823feadda774b Mon Sep 17 00:00:00 2001 From: BeckaL Date: Tue, 9 May 2023 18:02:04 +0100 Subject: [PATCH 2/2] Update changelog for Puma:HttpParserError suppression --- CHANGELOG.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 294cec9..10fe806 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,7 @@ +# Unreleased + +* Suppress noisy Puma::HttpParserError errors + # 7.1.0 * `GovukError` now allows specifying any name for the Sentry environment tag via the `SENTRY_CURRENT_ENV` environment variable. The environment name no longer has to match one of a fixed set of strings in order for `GovukError` to log events to Sentry.