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

[Bug]: elasticache/replication_group update is not waiting for replication group in the available state before updating the tags #33859

Closed
yogesh2580 opened this issue Oct 10, 2023 · 6 comments · Fixed by #36310
Labels
bug Addresses a defect in current functionality. service/elasticache Issues and PRs that pertain to the elasticache service. tags Pertains to resource tagging.
Milestone

Comments

@yogesh2580
Copy link

yogesh2580 commented Oct 10, 2023

Potentially Related

Terraform Core Version

1.5.4

AWS Provider Version

5.11.0

Affected Resource(s)

aws_elasticache_replication_group

Expected Behavior

The Tags on existing replication_group should be updated with the new keys-values and engine version update to 6.0.5

Actual Behavior

 Error: listing tags for ElastiCache Replication Group (arn): InvalidReplicationGroupState: Cluster not in available state to perform tagging operations.
status code: 400, request id: 5222cf25-276d-4294-8460-dd4364433d5f

Relevant Error/Panic Output Snippet

No response

Terraform Configuration Files

provider "aws" {
  shared_credentials_file = "CREDENTIAL_FILE"
  profile                 = "AWS_PROFILE"
  region                  = "us-east-1"
}

resource "aws_elasticache_replication_group" "test-redis" {
  replication_group_id          = "test-redis"
  replication_group_description = "test-redis"
  node_type                     = "cache.t4g.micro"
  engine                        = "redis"
  engine_version                = "6.0.5"
  parameter_group_name          = "parameter-grp"
  port                          = 6379
  number_cache_clusters         = 1 
  automatic_failover_enabled    = false

  security_group_ids = ["${var.redis-sg}"]
  subnet_group_name  = "${aws_elasticache_subnet_group.default.name}"

  tags {
    Name        = "TestRedis"
    Environment = "Dev"
    creator = "yogesh"  # adding new tag tagone to the existing resource group
  }
}

resource "aws_elasticache_subnet_group" "default" {
  name       = "test-subnet"
  subnet_ids = ["SUBNET-ID1", "SUBNET-ID2"]
}

Steps to Reproduce

terraform apply
Update aws_elasticache_replication_group tags
terraform apply

Debug Output

No response

Panic Output

No response

Important Factoids

No response

References

Previously the same issue was seen in version 3.74.1 and i got fixed in 4.9.0
Reference ticket number #23219

Would you like to implement a fix?

None

@yogesh2580 yogesh2580 added the bug Addresses a defect in current functionality. label Oct 10, 2023
@github-actions github-actions bot added the service/elasticache Issues and PRs that pertain to the elasticache service. label Oct 10, 2023
@github-actions
Copy link

Community Note

Voting for Prioritization

  • Please vote on this issue by adding a 👍 reaction to the original post to help the community and maintainers prioritize this request.
  • Please see our prioritization guide for information on how we prioritize.
  • 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.

Volunteering to Work on This Issue

  • If you are interested in working on this issue, please leave a comment.
  • If this would be your first contribution, please review the contribution guide.

@terraform-aws-provider terraform-aws-provider bot added the needs-triage Waiting for first response or review from a maintainer. label Oct 10, 2023
@phene
Copy link

phene commented Oct 12, 2023

Looks like someone attempted to fix this in the past: #24021

@justinretzolk justinretzolk added tags Pertains to resource tagging. and removed needs-triage Waiting for first response or review from a maintainer. labels Oct 25, 2023
@ybulakhau
Copy link

I have the same behavior in version 5.31.0

@brunofarina
Copy link

Hi,
I'm having the same error when I try to update something of an existent replication group, for instance updating the engine version or even enabling the multi-az.

Copy link

This functionality has been released in v5.41.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. Thank you!

Copy link

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 have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Apr 14, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Addresses a defect in current functionality. service/elasticache Issues and PRs that pertain to the elasticache service. tags Pertains to resource tagging.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants