Struct opentelemetry::sdk::logs::Builder
source · pub struct Builder { /* private fields */ }
Available on crate feature
logs
only.Expand description
Builder for provider attributes.
Implementations§
source§impl Builder
impl Builder
sourcepub fn with_simple_exporter<T>(self, exporter: T) -> Builderwhere
T: LogExporter + 'static,
pub fn with_simple_exporter<T>(self, exporter: T) -> Builderwhere T: LogExporter + 'static,
The LogExporter
that this provider should use.
sourcepub fn with_batch_exporter<T, R>(self, exporter: T, runtime: R) -> Builderwhere
T: LogExporter + 'static,
R: RuntimeChannel<BatchMessage>,
pub fn with_batch_exporter<T, R>(self, exporter: T, runtime: R) -> Builderwhere T: LogExporter + 'static, R: RuntimeChannel<BatchMessage>,
The LogExporter
setup using a default BatchLogProcessor
that this provider should use.
sourcepub fn with_log_processor<T>(self, processor: T) -> Builderwhere
T: LogProcessor + 'static,
pub fn with_log_processor<T>(self, processor: T) -> Builderwhere T: LogProcessor + 'static,
The LogProcessor
that this provider should use.
sourcepub fn with_config(self, config: Config) -> Builder
pub fn with_config(self, config: Config) -> Builder
The Config
that this provider should use.
sourcepub fn build(self) -> LoggerProvider
pub fn build(self) -> LoggerProvider
Create a new provider from this configuration.
Trait Implementations§
Auto Trait Implementations§
impl !RefUnwindSafe for Builder
impl Send for Builder
impl Sync for Builder
impl Unpin for Builder
impl !UnwindSafe for Builder
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