Skip to main content

aep_tower/
error.rs

1use thiserror::Error;
2
3#[derive(Debug, Error)]
4pub enum TowerError {
5    #[error(transparent)]
6    Core(#[from] aep_core::CoreError),
7    #[error("invalid AEP HTTP adapter configuration: {0}")]
8    InvalidConfiguration(String),
9    #[error("read AEP HTTP request body: {0}")]
10    RequestBody(String),
11    #[error("AEP HTTP request exceeds the configured body limit")]
12    RequestTooLarge,
13    #[error(transparent)]
14    Service(#[from] aep_service::ServiceError),
15    #[error(transparent)]
16    Json(#[from] serde_json::Error),
17    #[error(transparent)]
18    Url(#[from] url::ParseError),
19}