pub enum ReceiverError {
Show 13 variants
InvalidProtocolVersion(String),
ProtobufParseError(DecodeError),
JsonParseError(Error),
InvalidContentType(String),
MessageTooLarge {
size: usize,
max: usize,
},
MissingField(String),
InvalidSignalType(String),
GrpcError(Error),
HttpError(String),
CompressionError(String),
ConfigError(String),
Internal(String),
StorageError(StorageError),
}Expand description
Errors that can occur in the OTLP receiver
Variants§
InvalidProtocolVersion(String)
Invalid OTLP protocol version
ProtobufParseError(DecodeError)
Failed to parse Protobuf message
JsonParseError(Error)
Failed to parse JSON message
InvalidContentType(String)
Invalid content type
MessageTooLarge
Message too large
MissingField(String)
Missing required field
InvalidSignalType(String)
Invalid signal type
GrpcError(Error)
gRPC server error
HttpError(String)
HTTP server error
CompressionError(String)
Compression error
ConfigError(String)
Configuration error
Internal(String)
Internal error
StorageError(StorageError)
Storage error
Implementations§
Source§impl ReceiverError
impl ReceiverError
Sourcepub fn http_error(msg: impl Into<String>) -> Self
pub fn http_error(msg: impl Into<String>) -> Self
Create a new HTTP error
Sourcepub fn compression_error(msg: impl Into<String>) -> Self
pub fn compression_error(msg: impl Into<String>) -> Self
Create a new compression error
Sourcepub fn config_error(msg: impl Into<String>) -> Self
pub fn config_error(msg: impl Into<String>) -> Self
Create a new configuration error
Sourcepub fn to_grpc_status(&self) -> Status
pub fn to_grpc_status(&self) -> Status
Convert to gRPC status code
Sourcepub fn to_http_status(&self) -> u16
pub fn to_http_status(&self) -> u16
Convert to HTTP status code
Trait Implementations§
Source§impl Debug for ReceiverError
impl Debug for ReceiverError
Source§impl Display for ReceiverError
impl Display for ReceiverError
Source§impl Error for ReceiverError
impl Error for ReceiverError
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()
Source§impl From<DecodeError> for ReceiverError
impl From<DecodeError> for ReceiverError
Source§fn from(source: DecodeError) -> Self
fn from(source: DecodeError) -> Self
Converts to this type from the input type.
Source§impl From<Error> for ReceiverError
impl From<Error> for ReceiverError
Source§impl From<Error> for ReceiverError
impl From<Error> for ReceiverError
Source§impl From<StorageError> for ReceiverError
impl From<StorageError> for ReceiverError
Source§fn from(source: StorageError) -> Self
fn from(source: StorageError) -> Self
Converts to this type from the input type.
Source§impl IntoResponse for ReceiverError
impl IntoResponse for ReceiverError
Source§fn into_response(self) -> Response
fn into_response(self) -> Response
Create a response.
Auto Trait Implementations§
impl Freeze for ReceiverError
impl !RefUnwindSafe for ReceiverError
impl Send for ReceiverError
impl Sync for ReceiverError
impl Unpin for ReceiverError
impl UnsafeUnpin for ReceiverError
impl !UnwindSafe for ReceiverError
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
Source§impl<T> FutureExt for T
impl<T> FutureExt for T
Source§fn with_context(self, otel_cx: Context) -> WithContext<Self>
fn with_context(self, otel_cx: Context) -> WithContext<Self>
Source§fn with_current_context(self) -> WithContext<Self>
fn with_current_context(self) -> WithContext<Self>
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T in a tonic::Request