solana_stream_sdk/
error.rs

1use thiserror::Error;
2
3#[derive(Error, Debug)]
4pub enum SolanaStreamError {
5    #[error("Transport error: {0}")]
6    Transport(#[from] tonic::transport::Error),
7
8    #[error("gRPC status error: {0}")]
9    Status(#[from] tonic::Status),
10
11    #[error("Serialization error: {0}")]
12    Serialization(String),
13
14    #[error("Connection error: {0}")]
15    Connection(String),
16
17    #[error("Configuration error: {0}")]
18    Configuration(String),
19
20    #[error("IO error: {0}")]
21    Io(#[from] std::io::Error),
22
23    #[error("Serde JSONC error: {0}")]
24    SerdeJsonc(#[from] serde_jsonc::Error),
25
26    #[error("Invalid URI: {0}")]
27    InvalidUri(#[from] http::uri::InvalidUri),
28
29    #[error("Builder error: {0}")]
30    Builder(#[from] yellowstone_grpc_client::GeyserGrpcBuilderError),
31
32    #[error("Send error: {0}")]
33    SendError(#[from] futures::channel::mpsc::SendError),
34
35    #[error("Client error: {0}")]
36    Client(#[from] yellowstone_grpc_client::GeyserGrpcClientError),
37
38    #[error("URL Parse error: {0}")]
39    UrlParse(#[from] url::ParseError),
40}