-
Notifications
You must be signed in to change notification settings - Fork 1.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
#11185: Allow specifying a KMS key and tags for newly created AWS CloudWatch log groups. #22274
base: master
Are you sure you want to change the base?
Conversation
…ated AWS CloudWatch log groups.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Otherwise, this looks good and thank you for adding tests.
@@ -164,6 +165,14 @@ pub struct CloudwatchLogsSinkConfig { | |||
skip_serializing_if = "crate::serde::is_default" | |||
)] | |||
pub acknowledgements: AcknowledgementsConfig, | |||
|
|||
#[configurable(derived)] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @johannesfloriangeiger! Please add rustdocs and then make generate-components-docs
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done!
@@ -590,6 +590,15 @@ base: components: sinks: aws_cloudwatch_logs: configuration: { | |||
syntax: "template" | |||
} | |||
} | |||
kms_key: { | |||
description: """ | |||
The ARN of the [KMS key][kms_key] to use when encrypting log data. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is "ARN" a thing that will be obvious to all readers? If not, spell it out in parentheses after you mention it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, the acronym is already used in the same file (L41) and is a widely used terminology in AWS context but I’ll add a non abbreviated version.
@@ -5549,7 +5571,7 @@ version = "0.1.3" | |||
source = "registry+https://github.com/rust-lang/crates.io-index" | |||
checksum = "c0ff37bd590ca25063e35af745c343cb7a0271906fb7b37e4813e8f79f00268d" | |||
dependencies = [ | |||
"bitflags 2.6.0", | |||
"bitflags 2.8.0", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you also do a git merge origin master
to pick up the latest Cargo.lock? 🙏
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The docs team left a comment. Otherwise, LGTM
Summary
Implements the feature request #11185 by allowing users to specify a KMS key and tags for AWS CloudWatch log group sinks that are being used when creating new groups.
Change Type
Is this a breaking change?
How did you test this PR?
$KMS_KEY
with the ARN of the key created in the previous step.vector --config ./vector.yaml
, see 3 new log groups being created: One without both custom KMS key and tags, one with only tags and one with both custom KMS key and tags.Key policy that allows the usage in log groups in
us-east-1
:vector.yaml
Does this PR include user facing changes?
Checklist
make check-all
is a good command to run locally. This check isdefined here. Some of these
checks might not be relevant to your PR. For Rust changes, at the very least you should run:
cargo fmt --all
cargo clippy --workspace --all-targets -- -D warnings
cargo nextest run --workspace
(alternatively, you can runcargo test --all
)Cargo.lock
), pleaserun
dd-rust-license-tool write
to regenerate the license inventory and commit the changes (if any). More details here.References