#[non_exhaustive]pub enum ConsumerError {
TaskJoin {
stream_name: &'static str,
source: JoinError,
},
StreamRead {
source: StreamReadError,
},
}Expand description
Errors that the Consumer infrastructure itself can raise while driving its stream.
These describe failures of the consumer task — joining, or reading the underlying stream.
Visitor-specific failures (for example, a write-backed visitor’s sink rejecting bytes) live
in the visitor’s own StreamVisitor::Output /
AsyncStreamVisitor::Output type, not here. So a
writer-backed consumer’s wait returns
Result<Result<W, SinkWriteError>, ConsumerError>: the outer result is what ConsumerError
describes, the inner is the writer visitor’s own outcome.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
TaskJoin
The consumer task could not be joined/terminated.
Fields
StreamRead
The underlying stream failed while being read.
Fields
§
source: StreamReadErrorThe source error.
Trait Implementations§
Source§impl Debug for ConsumerError
impl Debug for ConsumerError
Source§impl Display for ConsumerError
impl Display for ConsumerError
Source§impl Error for ConsumerError
impl Error for ConsumerError
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0:
use the Display impl or to_string()
Auto Trait Implementations§
impl Freeze for ConsumerError
impl !RefUnwindSafe for ConsumerError
impl Send for ConsumerError
impl Sync for ConsumerError
impl Unpin for ConsumerError
impl UnsafeUnpin for ConsumerError
impl !UnwindSafe for ConsumerError
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more