Class: PublishingPlatformError::Configuration
- Inherits:
-
SimpleDelegator
- Object
- SimpleDelegator
- PublishingPlatformError::Configuration
- Defined in:
- lib/publishing_platform_app_config/publishing_platform_error/configuration.rb
Instance Method Summary collapse
-
#initialize(_sentry_configuration) ⇒ Configuration
constructor
A new instance of Configuration.
- #set_up_defaults ⇒ Object
Constructor Details
#initialize(_sentry_configuration) ⇒ Configuration
Returns a new instance of Configuration.
5 6 7 8 |
# File 'lib/publishing_platform_app_config/publishing_platform_error/configuration.rb', line 5 def initialize(_sentry_configuration) super set_up_defaults end |
Instance Method Details
#set_up_defaults ⇒ Object
10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 |
# File 'lib/publishing_platform_app_config/publishing_platform_error/configuration.rb', line 10 def set_up_defaults self.excluded_exceptions = [ # Default ActionDispatch rescue responses "ActionController::RoutingError", "AbstractController::ActionNotFound", "ActionController::MethodNotAllowed", "ActionController::UnknownHttpMethod", "ActionController::NotImplemented", "ActionController::UnknownFormat", "Mime::Type::InvalidMimeType", "ActionController::MissingExactTemplate", "ActionController::InvalidAuthenticityToken", "ActionController::InvalidCrossOriginRequest", "ActionDispatch::Http::Parameters::ParseError", "ActionController::BadRequest", "ActionController::ParameterMissing", "Rack::QueryParser::ParameterTypeError", "Rack::QueryParser::InvalidParameterError", # Default ActiveRecord rescue responses "ActiveRecord::RecordNotFound", "ActiveRecord::StaleObjectError", "ActiveRecord::RecordInvalid", "ActiveRecord::RecordNotSaved", # Additional items "ActiveJob::DeserializationError", "CGI::Session::CookieStore::TamperedWithCookie", # TODO # "GdsApi::HTTPIntermittentServerError", # "GdsApi::TimedOutException", "PublishingPlatform::SSO::PermissionDeniedError", "Mongoid::Errors::DocumentNotFound", "Puma::HttpParserError", "Sinatra::NotFound", "Slimmer::IntermittentRetrievalError", "Slimmer::SourceWrapperNotFoundError", "Sidekiq::JobRetry::Skip", "SignalException", ] # This will exclude exceptions that are triggered by one of the ignored # exceptions. For example, when any exception occurs in a template, # Rails will raise a ActionView::Template::Error, instead of the original error. self.inspect_exception_causes_for_exclusion = true # Avoid "Sending envelope with items ... to Sentry" logspew, since we # don't use Sentry's automatic session tracking. self.auto_session_tracking = false end |