Skip to content
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

resource aws_msk_cluster enhanced_monitoring does not allow setting to PER_TOPIC_PER_PARTITION #16866

Closed
cemeyer2 opened this issue Dec 21, 2020 · 5 comments · Fixed by #16914
Labels
enhancement Requests to existing resources that expand the functionality or scope. good first issue Call to action for new contributors looking for a place to start. Smaller or straightforward issues. service/kafka Issues and PRs that pertain to the kafka service.
Milestone

Comments

@cemeyer2
Copy link

Community Note

  • Please vote on this issue by adding a 👍 reaction to the original issue to help the community and maintainers prioritize this request
  • Please do not leave "+1" or other comments that do not add relevant new information or questions, they generate extra noise for issue followers and do not help prioritize the request
  • If you are interested in working on this issue or have submitted a pull request, please leave a comment

Terraform CLI and Terraform AWS Provider Version

  • Terraform 0.12.28
  • AWS provider 3.22.0

Affected Resource(s)

  • aws_msk_cluster

Terraform Configuration Files

Please include all Terraform configurations required to reproduce the bug. Bug reports without a functional reproduction may be closed without investigation.

resource "aws_msk_cluster" "kafka_cluster" {
...
enhanced_monitoring = "PER_TOPIC_PER_PARTITION"
...
}

Expected Behavior

The provider should provision MSK with the correct monitoring level specified.

Actual Behavior

Error: expected enhanced_monitoring to be one of [DEFAULT PER_BROKER PER_TOPIC_PER_BROKER], got PER_TOPIC_PER_PARTITION

Steps to Reproduce

  1. terraform apply

Important Factoids

https://docs.aws.amazon.com/msk/latest/developerguide/metrics-details.html indicates PER_TOPIC_PER_PARTITION is a valid setting now, but https://github.com/hashicorp/terraform-provider-aws/blob/master/aws/resource_aws_msk_cluster.go#L219-L223 seems to need to be updated to support this new value as one of the allowed parameters.

@ghost ghost added the service/kafka Issues and PRs that pertain to the kafka service. label Dec 21, 2020
@github-actions github-actions bot added the needs-triage Waiting for first response or review from a maintainer. label Dec 21, 2020
@anGie44 anGie44 added enhancement Requests to existing resources that expand the functionality or scope. good first issue Call to action for new contributors looking for a place to start. Smaller or straightforward issues. and removed needs-triage Waiting for first response or review from a maintainer. labels Dec 23, 2020
@anGie44
Copy link
Contributor

anGie44 commented Dec 23, 2020

Thank you for raising this issue @cemeyer2 , adding support should be a straightforward fix 👍 Just noting that we're moving in the direction of using the AWS Go SDK _Values() funcs to retrieve the possible list of values if available (for reference: #14601)

@gunadhya
Copy link
Contributor

gunadhya commented Dec 27, 2020

Hi @anGie44, I'd like to work on this issue. So I'm thinking the change would be something like this right?

Before:

"enhanced_monitoring": {
				Type:     schema.TypeString,
				Optional: true,
				Default:  kafka.EnhancedMonitoringDefault,
				ValidateFunc: validation.StringInSlice([]string{
					kafka.EnhancedMonitoringDefault,
					kafka.EnhancedMonitoringPerBroker,
					kafka.EnhancedMonitoringPerTopicPerBroker,
				}, true),
			}

After:

"enhanced_monitoring": {
   			Type:     schema.TypeString,
   			Optional: true,
   			Default:  kafka.EnhancedMonitoringDefault,
   			ValidateFunc: validation.StringInSlice(kafka.EnhancedMonitoring_Values(), true),
   		}

@anGie44
Copy link
Contributor

anGie44 commented Jan 5, 2021

PER_TOPIC_PER_PARTITION support has been merged and will release with v3.23.0 of the Terraform AWS Provider, likely out this Thursday.

@ghost
Copy link

ghost commented Jan 8, 2021

This has been released in version 3.23.0 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 for triage. Thanks!

@ghost
Copy link

ghost commented Feb 4, 2021

I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues.

If you feel this issue should be reopened, we encourage creating a new issue linking back to this one for added context. Thanks!

@ghost ghost locked as resolved and limited conversation to collaborators Feb 4, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
enhancement Requests to existing resources that expand the functionality or scope. good first issue Call to action for new contributors looking for a place to start. Smaller or straightforward issues. service/kafka Issues and PRs that pertain to the kafka service.
Projects
None yet
3 participants