-
Notifications
You must be signed in to change notification settings - Fork 9.2k
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
provider aws v2.16.0 fails to create a new replica node for elasticache cluster with identifier of 20 characters #9131
Comments
This issue can be worked around with AWS CLI, but obviously means it happens outside of terraform state management. Try something like:
Elasticache should spin up replicas in a different AZ than the primary. The fix for this would be if terraform provider can copy whatever API call the AWS CLI is doing to modify clusters that were created before this identifier string length limit was imposed. I do not expect AWS to raise this limit anytime soon, but they clearly are allowing users to work around it, and terraform should also allow for this. |
…ntifiers This also switches some of the hardcoded us-west-2 testing to use the aws_availability_zones data source so the testing is more region agnostic. Now its at least possible to run parallel testing locally in us-east-1 of an EC2-Classic enabled AWS account. References: - #9906 - #9131 - #7409 - #5381 Output from acceptance testing: ``` --- PASS: TestAccAWSElasticacheCluster_AZMode_Memcached_Ec2Classic (515.21s) --- PASS: TestAccAWSElasticacheCluster_AZMode_Redis_Ec2Classic (507.64s) --- PASS: TestAccAWSElasticacheCluster_Engine_Memcached_Ec2Classic (663.59s) --- PASS: TestAccAWSElasticacheCluster_Engine_Redis_Ec2Classic (595.65s) --- PASS: TestAccAWSElasticacheCluster_EngineVersion_Memcached_Ec2Classic (1260.72s) --- PASS: TestAccAWSElasticacheCluster_EngineVersion_Redis_Ec2Classic (1303.63s) --- PASS: TestAccAWSElasticacheCluster_multiAZInVpc (737.16s) --- PASS: TestAccAWSElasticacheCluster_NodeTypeResize_Memcached_Ec2Classic (954.44s) --- PASS: TestAccAWSElasticacheCluster_NodeTypeResize_Redis_Ec2Classic (1022.11s) --- PASS: TestAccAWSElasticacheCluster_NumCacheNodes_Decrease (995.54s) --- PASS: TestAccAWSElasticacheCluster_NumCacheNodes_Increase (1038.00s) --- PASS: TestAccAWSElasticacheCluster_NumCacheNodes_IncreaseWithPreferredAvailabilityZones (958.56s) --- PASS: TestAccAWSElasticacheCluster_NumCacheNodes_Redis_Ec2Classic (6.63s) --- PASS: TestAccAWSElasticacheCluster_ParameterGroupName_Default (596.16s) --- PASS: TestAccAWSElasticacheCluster_Port_Ec2Classic (576.63s) --- PASS: TestAccAWSElasticacheCluster_ReplicationGroupID_AvailabilityZone_Ec2Classic (1214.33s) --- PASS: TestAccAWSElasticacheCluster_ReplicationGroupID_InvalidAttributes (8.37s) --- PASS: TestAccAWSElasticacheCluster_ReplicationGroupID_MultipleReplica_Ec2Classic (1884.91s) --- PASS: TestAccAWSElasticacheCluster_ReplicationGroupID_SingleReplica_Ec2Classic (1746.94s) --- PASS: TestAccAWSElasticacheCluster_SecurityGroup (626.97s) --- PASS: TestAccAWSElasticacheCluster_snapshotsWithUpdates (1167.22s) --- PASS: TestAccAWSElasticacheCluster_vpc (646.18s) --- PASS: TestAccAWSElasticacheReplicationGroup_basic (1857.56s) --- PASS: TestAccAWSElasticacheReplicationGroup_clusteringAndCacheNodesCausesError (10.99s) --- PASS: TestAccAWSElasticacheReplicationGroup_ClusterMode_Basic (1875.48s) --- PASS: TestAccAWSElasticacheReplicationGroup_ClusterMode_NumNodeGroups (3713.74s) --- PASS: TestAccAWSElasticacheReplicationGroup_enableAtRestEncryption (1419.18s) --- PASS: TestAccAWSElasticacheReplicationGroup_enableAuthTokenTransitEncryption (734.55s) --- PASS: TestAccAWSElasticacheReplicationGroup_enableSnapshotting (1917.01s) --- PASS: TestAccAWSElasticacheReplicationGroup_importBasic (806.91s) --- PASS: TestAccAWSElasticacheReplicationGroup_multiAzInVpc (950.44s) --- PASS: TestAccAWSElasticacheReplicationGroup_NumberCacheClusters (2821.85s) --- PASS: TestAccAWSElasticacheReplicationGroup_NumberCacheClusters_Failover_AutoFailoverDisabled (2029.86s) --- PASS: TestAccAWSElasticacheReplicationGroup_NumberCacheClusters_Failover_AutoFailoverEnabled (1919.87s) --- PASS: TestAccAWSElasticacheReplicationGroup_redisClusterInVpc2 (737.16s) --- PASS: TestAccAWSElasticacheReplicationGroup_updateDescription (1240.24s) --- PASS: TestAccAWSElasticacheReplicationGroup_updateMaintenanceWindow (1047.59s) --- PASS: TestAccAWSElasticacheReplicationGroup_updateNodeSize (1985.53s) --- PASS: TestAccAWSElasticacheReplicationGroup_updateParameterGroup (900.33s) --- PASS: TestAccAWSElasticacheReplicationGroup_Uppercase (594.69s) --- PASS: TestAccAWSElasticacheReplicationGroup_vpc (1355.75s) ```
The Elasticache service now supports cluster identifiers up to 50 characters. We will support this new limit via: #9941 |
What about modifying existing clusters that were named before the limit went into place? |
The above has been merged and will release in version 2.28.0 of the Terraform AWS Provider, Thursday. 👍
The AWS Announcement does not provide any detail into this. From Terraform's perspective, we will allow and/or passthrough any configured value (under the new 50 character limit) to the Elasticache API. |
This has been released in version 2.28.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! |
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! |
environment:
TF code:
we are updating the number of replica nodes to
3
and when we apply the above code we see the following erroraws elasticache increase-replica-count --replication-group-id speyside-ts-redis-cl --new-replica-count 2 --apply-immediately
withawscli
version<1.2
and we got the same error. When we updatedawscli
version to1.16.184
it is working fine.The text was updated successfully, but these errors were encountered: