pub struct ProductionConfigBuilder { /* private fields */ }Expand description
Configuration builder
Implementations§
Source§impl ProductionConfigBuilder
impl ProductionConfigBuilder
Sourcepub fn production() -> Self
pub fn production() -> Self
Start from production preset
Sourcepub fn development() -> Self
pub fn development() -> Self
Start from development preset
Sourcepub fn high_performance() -> Self
pub fn high_performance() -> Self
Start from high-performance preset
Sourcepub fn environment(self, env: impl Into<String>) -> Self
pub fn environment(self, env: impl Into<String>) -> Self
Set environment
Sourcepub fn service_name(self, name: impl Into<String>) -> Self
pub fn service_name(self, name: impl Into<String>) -> Self
Set service name
Sourcepub fn security(self, f: impl FnOnce(SecurityConfig) -> SecurityConfig) -> Self
pub fn security(self, f: impl FnOnce(SecurityConfig) -> SecurityConfig) -> Self
Configure security
Sourcepub fn observability(
self,
f: impl FnOnce(ObservabilityConfig) -> ObservabilityConfig,
) -> Self
pub fn observability( self, f: impl FnOnce(ObservabilityConfig) -> ObservabilityConfig, ) -> Self
Configure observability
Sourcepub fn resilience(
self,
f: impl FnOnce(ResilienceConfig) -> ResilienceConfig,
) -> Self
pub fn resilience( self, f: impl FnOnce(ResilienceConfig) -> ResilienceConfig, ) -> Self
Configure resilience
Sourcepub fn runtime(self, f: impl FnOnce(RuntimeConfig) -> RuntimeConfig) -> Self
pub fn runtime(self, f: impl FnOnce(RuntimeConfig) -> RuntimeConfig) -> Self
Configure runtime
Sourcepub fn memory(self, f: impl FnOnce(MemoryConfig) -> MemoryConfig) -> Self
pub fn memory(self, f: impl FnOnce(MemoryConfig) -> MemoryConfig) -> Self
Configure memory
Sourcepub fn build(self) -> Result<ProductionConfig>
pub fn build(self) -> Result<ProductionConfig>
Build and validate the configuration
Sourcepub fn build_unchecked(self) -> ProductionConfig
pub fn build_unchecked(self) -> ProductionConfig
Build without validation
Trait Implementations§
Source§impl Default for ProductionConfigBuilder
impl Default for ProductionConfigBuilder
Source§fn default() -> ProductionConfigBuilder
fn default() -> ProductionConfigBuilder
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for ProductionConfigBuilder
impl RefUnwindSafe for ProductionConfigBuilder
impl Send for ProductionConfigBuilder
impl Sync for ProductionConfigBuilder
impl Unpin for ProductionConfigBuilder
impl UnwindSafe for ProductionConfigBuilder
Blanket Implementations§
Source§impl<T> ArchivePointee for T
impl<T> ArchivePointee for T
Source§type ArchivedMetadata = ()
type ArchivedMetadata = ()
The archived version of the pointer metadata for this type.
Source§fn pointer_metadata(
_: &<T as ArchivePointee>::ArchivedMetadata,
) -> <T as Pointee>::Metadata
fn pointer_metadata( _: &<T as ArchivePointee>::ArchivedMetadata, ) -> <T as Pointee>::Metadata
Converts some archived metadata to the pointer metadata for itself.
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<F, W, T, D> Deserialize<With<T, W>, D> for F
impl<F, W, T, D> Deserialize<With<T, W>, D> for F
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> LayoutRaw for T
impl<T> LayoutRaw for T
Source§fn layout_raw(_: <T as Pointee>::Metadata) -> Result<Layout, LayoutError>
fn layout_raw(_: <T as Pointee>::Metadata) -> Result<Layout, LayoutError>
Gets the layout of the type.