hashicorp / terraform-provider-aws

The AWS Provider enables Terraform to manage AWS resources.
https://registry.terraform.io/providers/hashicorp/aws
Mozilla Public License 2.0
9.84k stars 9.19k forks source link

feat: Add description arg/attr for aws_cloudwatch_event_bus resource and data source #39980

Closed acwwat closed 1 week ago

acwwat commented 2 weeks ago

Description

This PR is to add the description argument/attribute to the aws_cloudwatch_event_bus resource and data source.

Note that there is a quirk with the AWS API where you cannot unset the description on update when it is previously set. The only way is to set the description to am empty string, which is coincidentally mapped to the zero string value. So in the state, the value is never null, only empty string for now.

Relations

Closes #39900

References

Referred to CreateTask for specs and wordings.

Output from Acceptance Testing

For the aws_cloudwatch_event_bus resource:

$ make testacc TESTS=TestAccEventsBus_basic PKG=events
make: Verifying source code with gofmt...
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go1.23.2 test ./internal/service/events/... -v -count 1 -parallel 20 -run='TestAccEventsBus_basic'  -timeout 360m
2024/10/31 23:46:42 Initializing Terraform AWS Provider...
=== RUN   TestAccEventsBus_basic
=== PAUSE TestAccEventsBus_basic
=== CONT  TestAccEventsBus_basic
--- PASS: TestAccEventsBus_basic (50.18s)
PASS
ok      github.com/hashicorp/terraform-provider-aws/internal/service/events     50.394s

$

For the aws_cloudwatch_event_bus data source:

$ make testacc TESTS=TestAccEventsBusDataSource_kmsKeyIdentifier PKG=events
make: Verifying source code with gofmt...
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go1.23.2 test ./internal/service/events/... -v -count 1 -parallel 20 -run='TestAccEventsBusDataSource_kmsKeyIdentifier'  -timeout 360m
2024/10/31 23:58:15 Initializing Terraform AWS Provider...
=== RUN   TestAccEventsBusDataSource_kmsKeyIdentifier
=== PAUSE TestAccEventsBusDataSource_kmsKeyIdentifier
=== CONT  TestAccEventsBusDataSource_kmsKeyIdentifier
--- PASS: TestAccEventsBusDataSource_kmsKeyIdentifier (25.18s)
PASS
ok      github.com/hashicorp/terraform-provider-aws/internal/service/events     25.392s

$
github-actions[bot] commented 2 weeks ago

Community Note

Voting for Prioritization

For Submitters

jar-b commented 1 week ago

Thanks for your contribution, @acwwat! 👍 👏

github-actions[bot] commented 4 days ago

This functionality has been released in v5.75.1 of the Terraform AWS Provider. Please see the Terraform documentation on provider versioning or reach out if you need any assistance upgrading.

For further feature requests or bug reports with this functionality, please create a new GitHub issue following the template. Thank you!