pub struct ServiceConfig {
pub url: String,
pub timeout: Duration,
pub retry_policy: RetryPolicy,
pub custom_headers: FxHashMap<String, String>,
pub additional_config: FxHashMap<String, Value>,
}Expand description
Configuration for creating a webhook service sender.
Fields§
§url: StringWebhook URL
timeout: DurationRequest timeout
retry_policy: RetryPolicyRetry policy for failed requests
custom_headers: FxHashMap<String, String>Custom HTTP headers
additional_config: FxHashMap<String, Value>Service-specific configuration
Implementations§
Source§impl ServiceConfig
impl ServiceConfig
Sourcepub const fn with_timeout(self, timeout: Duration) -> Self
pub const fn with_timeout(self, timeout: Duration) -> Self
Set the request timeout.
Sourcepub const fn with_retry_policy(self, policy: RetryPolicy) -> Self
pub const fn with_retry_policy(self, policy: RetryPolicy) -> Self
Set the retry policy.
Trait Implementations§
Source§impl Clone for ServiceConfig
impl Clone for ServiceConfig
Auto Trait Implementations§
impl Freeze for ServiceConfig
impl RefUnwindSafe for ServiceConfig
impl Send for ServiceConfig
impl Sync for ServiceConfig
impl Unpin for ServiceConfig
impl UnsafeUnpin for ServiceConfig
impl UnwindSafe for ServiceConfig
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