Expand description

Any errors that merino-web might generate, and supporting implementations.

This module implements the supporting functionalities to manipulate [crate::error::HandlerError] to make it esier to send them to Sentry. The [crate::error::HandlerError] wraps the internal error [crate::error::HandlerErrorKind] and a related backtrace. The corresponding backtrace is captured when the error is created. This happens automatically when a [crate::error::HandlerErrorKind] is converted into a [crate::error::HandlerError].

Developers are expected to use [crate::error::HandlerError] as the error type of their functions and to set the appropriate error by

  • explicitly converting it using into(), e.g. Err(HandlerErrorKind::Internal.into()),
  • implicitly converting it using the question mark operator, e.g. Err(HandleErrorKind::Interal)?.

New errors can be added by extending [crate::error::HandlerErrorKind].

Structs

The Standard Error for most of Merino

Enums

An error that happened in a web handler.