Terraform-provider-aws: enabled_cloudwatch_logs_exports is incompatible with PostgreSQL 10.5 export log parameters ("postgresql", "upgrade") in aws_db_instance

Created on 12 Dec 2018  ·  4Comments  ·  Source: hashicorp/terraform-provider-aws

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 "me too" comments, 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 Version

$ terraform -v
Terraform v0.11.10
+ provider.aws v1.51.0

Affected Resource(s)

resource "aws_db_instance" "foo" {
  ...
  #enabled_cloudwatch_logs_exports = ["postgresql", "upgrade"] Disabled until Terraform supports PostgreSQL-log parameters. Currently only supports: alert, audit, error, general, listener, slowquery and trace. 
}

Terraform Configuration Files

resource "aws_db_instance" "foo" {
  engine = "postgres"
  engine_version = "10.5"
  ...
  #enabled_cloudwatch_logs_exports = ["postgresql", "upgrade"] Disabled until Terraform supports PostgreSQL-log parameters. Currently only supports: alert, audit, error, general, listener, slowquery and trace. 
}

Actual Behavior

After enabling 'CloudWatch Logs Export' on a PostgreSQL 10.5 RDS instance created by Terraform via the AWS web console:

Wed Dec 12 15:09:23 GMT+1300 2018 CloudWatch Logs Export enabled for logs [postgresql, upgrade]

Terraform will attempt to remove the parameters: postgresql and upgrade from the instance when enabled_cloudwatch_logs_exports is not present in the Terraform configuration:

  #enabled_cloudwatch_logs_exports = ["postgresql", "upgrade"] Disabled until Terraform supports PostgreSQL-log parameters. Currently only supports: alert, audit, error, general, listener, slowquery and trace. 
$ terraform apply
...
  ~ aws_db_instance.foo
      enabled_cloudwatch_logs_exports.#: "2" => "0"
      enabled_cloudwatch_logs_exports.0: "postgresql" => ""
      enabled_cloudwatch_logs_exports.1: "upgrade" => ""



md5-fd55e6a749676b00c847dc829f9e03df



```hcl
$ terraform apply
...
Error: aws_db_instance.foo: expected enabled_cloudwatch_logs_exports.0 to be one of [alert audit error general listener slowquery trace], got postgresql

Error: aws_db_instance.foo: expected enabled_cloudwatch_logs_exports.1 to be one of [alert audit error general listener slowquery trace], got upgrade

I'm not sure if this should be a bug report or feature request.

Expected Behavior

postgresql and upgrade should be added as a supported enabled_cloudwatch_logs_exports parameter.

Steps to Reproduce

  1. terraform apply

References

  • #5235 Covered this issue but for Oracle parameters.
enhancement servicrds

Most helpful comment

Support for the new postgresql and upgrade values under enabled_cloudwatch_logs_exports has been merged and will release with version 1.52.0 of the AWS provider, likely later today or tomorrow. 👍

All 4 comments

I opened #6829 to address this

Support for the new postgresql and upgrade values under enabled_cloudwatch_logs_exports has been merged and will release with version 1.52.0 of the AWS provider, likely later today or tomorrow. 👍

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

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!

Was this page helpful?
0 / 5 - 0 ratings