pub struct OtlpConfig {
pub endpoint: Option<String>,
pub protocol: OtlpProtocol,
pub headers: BTreeMap<String, String>,
pub timeout_secs: u64,
}Expand description
Where the data goes.
Fields§
§endpoint: Option<String>Base URL of an OTLP/HTTP receiver — http://localhost:4318, or a
vendor’s ingest URL. The signal paths (/v1/traces, /v1/metrics) are
appended. Unset falls back to OTEL_EXPORTER_OTLP_ENDPOINT; unset in
both places exports nothing.
protocol: OtlpProtocolhttp/protobuf (the default, and what every collector accepts) or
http/json for a receiver that only speaks JSON.
headers: BTreeMap<String, String>Sent with every export request — this is where a vendor’s API key goes.
Use $VAR rather than writing the key into a committed file.
timeout_secs: u64How long one export may take before it is abandoned. The exporter drops the batch rather than blocking the process behind a collector that has stopped answering.
Trait Implementations§
Source§impl Clone for OtlpConfig
impl Clone for OtlpConfig
Source§fn clone(&self) -> OtlpConfig
fn clone(&self) -> OtlpConfig
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for OtlpConfig
impl Debug for OtlpConfig
Source§impl Default for OtlpConfig
impl Default for OtlpConfig
Source§impl<'de> Deserialize<'de> for OtlpConfigwhere
OtlpConfig: Default,
impl<'de> Deserialize<'de> for OtlpConfigwhere
OtlpConfig: Default,
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for OtlpConfig
impl RefUnwindSafe for OtlpConfig
impl Send for OtlpConfig
impl Sync for OtlpConfig
impl Unpin for OtlpConfig
impl UnsafeUnpin for OtlpConfig
impl UnwindSafe for OtlpConfig
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