[Bug]: aws_docdb_cluster "unsupported attribute" error for documented attribute "allow-major-version-upgrade" #33764
Labels
enhancement
Requests to existing resources that expand the functionality or scope.
service/docdb
Issues and PRs that pertain to the docdb service.
Milestone
Terraform Core Version
1.5.5
AWS Provider Version
5.19.0
Affected Resource(s)
aws_docdb_cluster
Expected Behavior
When we try to perform an upgrade on a regional cluster without a mention of allow-major-version-upgrade field we get the below error
Error: modifying DocumentDB Cluster (ss-ddd-tes1-aaa-docdb-primary-cluster): InvalidParameterCombination: The AllowMajorVersionUpgrade flag must be present when upgrading to a new major version
And when we give allow-major-version-upgrade = true in the aws_docdb_cluster we get the below error
╷
│ Error: Unsupported argument
│
│ on modules/docdb/docdb_primary.tf line 23, in resource "aws_docdb_cluster" "primary_cluster":
│ 23: allow_major_version_upgrade = true
│
│ An argument named "allow_major_version_upgrade" is not expected here.
Actual Behavior
When we try to perform an upgrade on a regional cluster without a mention of allow-major-version-upgrade field we get the below error
Error: modifying DocumentDB Cluster (ss-ddd-tes1-aaa-docdb-primary-cluster): InvalidParameterCombination: The AllowMajorVersionUpgrade flag must be present when upgrading to a new major version
And when we give allow-major-version-upgrade = true in the aws_docdb_cluster we get the below error
╷
│ Error: Unsupported argument
│
│ on modules/docdb/docdb_primary.tf line 23, in resource "aws_docdb_cluster" "primary_cluster":
│ 23: allow_major_version_upgrade = true
│
│ An argument named "allow_major_version_upgrade" is not expected here.
Relevant Error/Panic Output Snippet
Terraform Configuration Files
resource "aws_docdb_cluster" "primary_cluster" {
db_subnet_group_name = aws_docdb_subnet_group.primary_subnet.name
cluster_identifier = var.primary_cluster_name
engine = var.engine
master_username = var.master_username
master_password = var.master_password
db_cluster_parameter_group_name = aws_docdb_cluster_parameter_group.primary_db_param_group5.name
vpc_security_group_ids = var.primary_security_group_ids
engine_version = "5.0.0"
storage_encrypted = true
port = 27017
apply_immediately = var.apply_immediately
skip_final_snapshot = true
enabled_cloudwatch_logs_exports = ["audit", "profiler"]
kms_key_id = var.primary_kms_key
allow_major_version_upgrade = true
}
Steps to Reproduce
terraform apply
Debug Output
No response
Panic Output
No response
Important Factoids
No response
References
No response
Would you like to implement a fix?
No
The text was updated successfully, but these errors were encountered: