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_elasticache_replication_group: Must be in available state before modifying tags #24021

Merged
merged 3 commits into from
Apr 7, 2022

Conversation

gdavison
Copy link
Contributor

@gdavison gdavison commented Apr 4, 2022

ElastiCache replication groups must be in the available state before modifying tags.

Also adds tests for ElastiCache cache clusters.

Closes #23219

Output from acceptance testing:

$ make testacc PKG=elasticache TESTS='TestAccElastiCacheCluster|TestAccElastiCacheReplicationGroup'

--- PASS: TestAccElastiCacheReplicationGroup_clusteringAndCacheNodesCausesError (23.18s)
--- PASS: TestAccElastiCacheClusterDataSource_Data_basic (519.79s)
--- PASS: TestAccElastiCacheReplicationGroup_ClusterMode_singleNode (757.42s)
--- PASS: TestAccElastiCacheReplicationGroup_enableAtRestEncryption (767.08s)
--- PASS: TestAccElastiCacheReplicationGroup_ClusterMode_nonClusteredParameterGroup (865.62s)
--- PASS: TestAccElastiCacheReplicationGroup_enableSnapshotting (869.15s)
--- PASS: TestAccElastiCacheReplicationGroup_Validation_noNodeType (4.70s)
--- PASS: TestAccElastiCacheReplicationGroup_enableAuthTokenTransitEncryption (1135.66s)
--- PASS: TestAccElastiCacheReplicationGroup_tags (1278.81s)
--- PASS: TestAccElastiCacheReplicationGroup_dataTiering (1305.53s)
--- PASS: TestAccElastiCacheReplicationGroup_Engine_Redis_LogDeliveryConfigurations_ClusterMode_Enabled (1565.95s)
--- PASS: TestAccElastiCacheReplicationGroup_Engine_Redis_LogDeliveryConfigurations_ClusterMode_Disabled (1646.85s)
--- PASS: TestAccElastiCacheReplicationGroup_GlobalReplicationGroupIDClusterModeValidation_numNodeGroupsOnSecondary (1723.05s)
--- PASS: TestAccElastiCacheReplicationGroup_deprecatedAvailabilityZones_multiAzNotInVPC (1790.96s)
--- PASS: TestAccElastiCacheReplicationGroup_useCMKKMSKeyID (1867.88s)
--- PASS: TestAccElastiCacheReplicationGroup_ValidationMultiAz_noAutomaticFailover (2.67s)
--- PASS: TestAccElastiCacheReplicationGroup_Validation_globalReplicationGroupIdAndNodeType (1175.98s)
--- PASS: TestAccElastiCacheReplicationGroup_NumberCacheClustersMemberClusterDisappearsRemoveMemberCluster_scaleDown (1504.29s)
--- PASS: TestAccElastiCacheReplicationGroup_NumberCacheClustersMemberClusterDisappearsRemoveMemberCluster_atTargetSize (1276.19s)
--- PASS: TestAccElastiCacheCluster_Memcached_finalSnapshot (2.77s)
--- PASS: TestAccElastiCacheReplicationGroup_finalSnapshot (1130.78s)
--- PASS: TestAccElastiCacheReplicationGroup_ClusterMode_updateReplicasPerNodeGroup (2527.11s)
--- PASS: TestAccElastiCacheReplicationGroup_ClusterModeUpdateNumNodeGroups_scaleUp (2670.02s)
--- PASS: TestAccElastiCacheReplicationGroup_NumberCacheClustersMemberClusterDisappears_noChange (1411.19s)
--- PASS: TestAccElastiCacheReplicationGroup_deprecatedAvailabilityZones_multiAzInVPC (1055.76s)
--- PASS: TestAccElastiCacheReplicationGroup_tagWithOtherModification (1219.12s)
--- PASS: TestAccElastiCacheCluster_vpc (468.57s)
--- PASS: TestAccElastiCacheCluster_NumCacheNodes_redis (2.78s)
--- PASS: TestAccElastiCacheReplicationGroup_NumberCacheClustersMemberClusterDisappears_addMemberCluster (2178.41s)
--- PASS: TestAccElastiCacheReplicationGroup_ClusterModeUpdateNumNodeGroups_scaleDown (3078.33s)
--- PASS: TestAccElastiCacheReplicationGroup_multiAzInVPC (855.02s)
--- PASS: TestAccElastiCacheReplicationGroup_multiAzNotInVPC_repeated (820.69s)
--- PASS: TestAccElastiCacheReplicationGroup_NumberCacheClustersFailover_autoFailoverDisabled (1399.94s)
--- PASS: TestAccElastiCacheReplicationGroup_NumberCacheClustersFailover_autoFailoverEnabled (1601.16s)
--- PASS: TestAccElastiCacheReplicationGroup_ClusterModeUpdateNumNodeGroupsAndReplicasPerNodeGroup_scaleDown (3467.17s)
--- PASS: TestAccElastiCacheReplicationGroup_depecatedAvailabilityZones_vpc (711.99s)
--- PASS: TestAccElastiCacheReplicationGroup_multiAzNotInVPC (822.00s)
--- PASS: TestAccElastiCacheReplicationGroup_vpc (712.31s)
--- PASS: TestAccElastiCacheReplicationGroup_NumberCacheClusters_basic (1690.17s)
--- PASS: TestAccElastiCacheReplicationGroup_NumberCacheClusters_multiAZEnabled (2132.71s)
--- PASS: TestAccElastiCacheCluster_ReplicationGroupID_multipleReplica (1254.33s)
--- PASS: TestAccElastiCacheReplicationGroup_ClusterModeUpdateNumNodeGroupsAndReplicasPerNodeGroup_scaleUp (3809.60s)
--- PASS: TestAccElastiCacheReplicationGroup_GlobalReplicationGroupID_disappears (3827.83s)
--- PASS: TestAccElastiCacheCluster_ReplicationGroupID_availabilityZone (1182.33s)
--- PASS: TestAccElastiCacheReplicationGroup_updateAuthToken (883.84s)
--- PASS: TestAccElastiCacheCluster_AZMode_redis (494.63s)
--- PASS: TestAccElastiCacheCluster_AZMode_memcached (455.84s)
--- PASS: TestAccElastiCacheReplicationGroup_updateParameterGroup (890.12s)
--- PASS: TestAccElastiCacheReplicationGroup_GlobalReplicationGroupID_basic (3403.80s)
--- PASS: TestAccElastiCacheReplicationGroup_GlobalReplicationGroupIDClusterMode_basic (4180.41s)
--- PASS: TestAccElastiCacheCluster_NodeTypeResize_redis (1135.15s)
--- PASS: TestAccElastiCacheCluster_NodeTypeResize_memcached (955.94s)
--- SKIP: TestAccElastiCacheCluster_SecurityGroup_ec2Classic (0.86s)
--- PASS: TestAccElastiCacheReplicationGroupDataSource_nonExistent (3.14s)
--- PASS: TestAccElastiCacheCluster_Engine_None (2.41s)
--- PASS: TestAccElastiCacheReplicationGroup_GlobalReplicationGroupID_full (3725.89s)
--- PASS: TestAccElastiCacheCluster_port (474.21s)
--- PASS: TestAccElastiCacheCluster_multiAZInVPC (538.05s)
--- PASS: TestAccElastiCacheCluster_EngineVersion_memcached (1023.69s)
--- PASS: TestAccElastiCacheCluster_ReplicationGroupID_singleReplica (1776.80s)
--- PASS: TestAccElastiCacheReplicationGroup_disappears (644.70s)
--- PASS: TestAccElastiCacheReplicationGroup_updateMaintenanceWindow (840.25s)
--- PASS: TestAccElastiCacheReplicationGroup_updateUserGroups (995.55s)
--- PASS: TestAccElastiCacheCluster_NumCacheNodes_increaseWithPreferredAvailabilityZones (613.19s)
--- PASS: TestAccElastiCacheReplicationGroup_updateDescription (829.77s)
--- PASS: TestAccElastiCacheCluster_snapshotsWithUpdates (541.93s)
--- PASS: TestAccElastiCacheCluster_NumCacheNodes_increase (725.01s)
--- PASS: TestAccElastiCacheCluster_ParameterGroupName_default (457.21s)
--- PASS: TestAccElastiCacheReplicationGroup_uppercase (701.41s)
--- PASS: TestAccElastiCacheCluster_EngineVersion_redis (1595.16s)
--- PASS: TestAccElastiCacheCluster_NumCacheNodes_decrease (724.10s)
--- PASS: TestAccElastiCacheReplicationGroup_basic (698.67s)
--- PASS: TestAccElastiCacheCluster_PortRedis_default (514.46s)
--- PASS: TestAccElastiCacheReplicationGroupDataSource_multiAZ (809.43s)
--- PASS: TestAccElastiCacheReplicationGroup_updateNodeSize (1533.68s)
--- PASS: TestAccElastiCacheCluster_Engine_memcached (444.47s)
--- PASS: TestAccElastiCacheReplicationGroupDataSource_Engine_Redis_LogDeliveryConfigurations (849.46s)
--- PASS: TestAccElastiCacheCluster_tags (510.75s)
--- PASS: TestAccElastiCacheReplicationGroupDataSource_basic (738.10s)
--- PASS: TestAccElastiCacheCluster_tagWithOtherModification (612.44s)
--- PASS: TestAccElastiCacheCluster_Redis_finalSnapshot (715.25s)
--- PASS: TestAccElastiCacheCluster_Engine_redis (486.07s)
--- PASS: TestAccElastiCacheReplicationGroupDataSource_clusterMode (969.66s)
--- PASS: TestAccElastiCacheClusterDataSource_Engine_Redis_LogDeliveryConfigurations (747.37s)
--- PASS: TestAccElastiCacheCluster_Engine_Redis_LogDeliveryConfigurations (976.98s)
--- PASS: TestAccElastiCacheReplicationGroup_ClusterMode_basic (977.72s)
--- PASS: TestAccElastiCacheReplicationGroup_EngineVersion_update (3187.51s)

@github-actions github-actions bot added service/elasticache Issues and PRs that pertain to the elasticache service. tests PRs: expanded test coverage. Issues: expanded coverage, enhancements to test infrastructure. size/L Managed by automation to categorize the size of a PR. labels Apr 4, 2022
@gdavison gdavison marked this pull request as ready for review April 5, 2022 17:30
@ewbankkit ewbankkit self-assigned this Apr 5, 2022
Copy link
Contributor

@ewbankkit ewbankkit left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 🚀.

% make testacc TESTARGS='-run=TestAccElastiCacheCluster_tags\|TestAccElastiCacheCluster_tagWithOtherModification\|TestAccElastiCacheReplicationGroup_tagWithOtherModification\|TestAccElastiCacheReplicationGroup_tags' PKG=elasticache ACCTEST_PARALLELISM=2 ACCTEST_TIMEOUT=720m 
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./internal/service/elasticache/... -v -count 1 -parallel 2  -run=TestAccElastiCacheCluster_tags\|TestAccElastiCacheCluster_tagWithOtherModification\|TestAccElastiCacheReplicationGroup_tagWithOtherModification\|TestAccElastiCacheReplicationGroup_tags -timeout 720m
=== RUN   TestAccElastiCacheCluster_tags
=== PAUSE TestAccElastiCacheCluster_tags
=== RUN   TestAccElastiCacheCluster_tagWithOtherModification
=== PAUSE TestAccElastiCacheCluster_tagWithOtherModification
=== RUN   TestAccElastiCacheReplicationGroup_tags
=== PAUSE TestAccElastiCacheReplicationGroup_tags
=== RUN   TestAccElastiCacheReplicationGroup_tagWithOtherModification
=== PAUSE TestAccElastiCacheReplicationGroup_tagWithOtherModification
=== CONT  TestAccElastiCacheCluster_tags
=== CONT  TestAccElastiCacheReplicationGroup_tags
--- PASS: TestAccElastiCacheCluster_tags (467.59s)
=== CONT  TestAccElastiCacheCluster_tagWithOtherModification
--- PASS: TestAccElastiCacheReplicationGroup_tags (983.81s)
=== CONT  TestAccElastiCacheReplicationGroup_tagWithOtherModification
--- PASS: TestAccElastiCacheCluster_tagWithOtherModification (598.85s)
--- PASS: TestAccElastiCacheReplicationGroup_tagWithOtherModification (1125.85s)
PASS
ok  	github.com/hashicorp/terraform-provider-aws/internal/service/elasticache	2113.157s

@ewbankkit ewbankkit removed their assignment Apr 5, 2022
@gdavison gdavison merged commit 831b4ed into main Apr 7, 2022
@gdavison gdavison deleted the repgroup-tag-needs-available branch April 7, 2022 19:33
@github-actions github-actions bot added this to the v4.9.0 milestone Apr 7, 2022
@github-actions
Copy link

github-actions bot commented Apr 7, 2022

This functionality has been released in v4.9.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!

@github-actions
Copy link

github-actions bot commented May 9, 2022

I'm going to lock this pull request 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 related to this change, 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 May 9, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
service/elasticache Issues and PRs that pertain to the elasticache service. size/L Managed by automation to categorize the size of a PR. tests PRs: expanded test coverage. Issues: expanded coverage, enhancements to test infrastructure.
Projects
None yet
2 participants