pub struct Builder { /* private fields */ }
Expand description
A builder for LogDestinationConfig
.
Implementations
sourceimpl Builder
impl Builder
sourcepub fn log_type(self, input: LogType) -> Self
pub fn log_type(self, input: LogType) -> Self
The type of log to send. Alert logs report traffic that matches a StatefulRule
with an action setting that sends an alert log message. Flow logs are standard network traffic flow logs.
sourcepub fn set_log_type(self, input: Option<LogType>) -> Self
pub fn set_log_type(self, input: Option<LogType>) -> Self
The type of log to send. Alert logs report traffic that matches a StatefulRule
with an action setting that sends an alert log message. Flow logs are standard network traffic flow logs.
sourcepub fn log_destination_type(self, input: LogDestinationType) -> Self
pub fn log_destination_type(self, input: LogDestinationType) -> Self
The type of storage destination to send these logs to. You can send logs to an Amazon S3 bucket, a CloudWatch log group, or a Kinesis Data Firehose delivery stream.
sourcepub fn set_log_destination_type(self, input: Option<LogDestinationType>) -> Self
pub fn set_log_destination_type(self, input: Option<LogDestinationType>) -> Self
The type of storage destination to send these logs to. You can send logs to an Amazon S3 bucket, a CloudWatch log group, or a Kinesis Data Firehose delivery stream.
sourcepub fn log_destination(self, k: impl Into<String>, v: impl Into<String>) -> Self
pub fn log_destination(self, k: impl Into<String>, v: impl Into<String>) -> Self
Adds a key-value pair to log_destination
.
To override the contents of this collection use set_log_destination
.
The named location for the logs, provided in a key:value mapping that is specific to the chosen destination type.
-
For an Amazon S3 bucket, provide the name of the bucket, with key
bucketName
, and optionally provide a prefix, with keyprefix
. The following example specifies an Amazon S3 bucket namedDOC-EXAMPLE-BUCKET
and the prefixalerts
:"LogDestination": { "bucketName": "DOC-EXAMPLE-BUCKET", "prefix": "alerts" }
-
For a CloudWatch log group, provide the name of the CloudWatch log group, with key
logGroup
. The following example specifies a log group namedalert-log-group
:"LogDestination": { "logGroup": "alert-log-group" }
-
For a Kinesis Data Firehose delivery stream, provide the name of the delivery stream, with key
deliveryStream
. The following example specifies a delivery stream namedalert-delivery-stream
:"LogDestination": { "deliveryStream": "alert-delivery-stream" }
sourcepub fn set_log_destination(self, input: Option<HashMap<String, String>>) -> Self
pub fn set_log_destination(self, input: Option<HashMap<String, String>>) -> Self
The named location for the logs, provided in a key:value mapping that is specific to the chosen destination type.
-
For an Amazon S3 bucket, provide the name of the bucket, with key
bucketName
, and optionally provide a prefix, with keyprefix
. The following example specifies an Amazon S3 bucket namedDOC-EXAMPLE-BUCKET
and the prefixalerts
:"LogDestination": { "bucketName": "DOC-EXAMPLE-BUCKET", "prefix": "alerts" }
-
For a CloudWatch log group, provide the name of the CloudWatch log group, with key
logGroup
. The following example specifies a log group namedalert-log-group
:"LogDestination": { "logGroup": "alert-log-group" }
-
For a Kinesis Data Firehose delivery stream, provide the name of the delivery stream, with key
deliveryStream
. The following example specifies a delivery stream namedalert-delivery-stream
:"LogDestination": { "deliveryStream": "alert-delivery-stream" }
sourcepub fn build(self) -> LogDestinationConfig
pub fn build(self) -> LogDestinationConfig
Consumes the builder and constructs a LogDestinationConfig
.
Trait Implementations
impl StructuralPartialEq for Builder
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
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> Instrument for T
impl<T> Instrument for T
sourcefn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
sourcefn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
sourceimpl<T> WithSubscriber for T
impl<T> WithSubscriber for T
sourcefn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
Attaches the provided Subscriber
to this type, returning a
WithDispatch
wrapper. Read more
sourcefn with_current_subscriber(self) -> WithDispatch<Self>
fn with_current_subscriber(self) -> WithDispatch<Self>
Attaches the current default Subscriber
to this type, returning a
WithDispatch
wrapper. Read more