From d0a71c918d5e6780f73e3fb61e2ae28b60eddd50 Mon Sep 17 00:00:00 2001 From: Enis Konuk Date: Mon, 30 Mar 2015 16:40:02 -0400 Subject: [PATCH 1/4] fixed bugs in CloudFront & RDS waiters --- aws-sdk-core/apis/CloudFront.waiters.json | 6 +++--- aws-sdk-core/apis/RDS.waiters.json | 11 +++++------ 2 files changed, 8 insertions(+), 9 deletions(-) diff --git a/aws-sdk-core/apis/CloudFront.waiters.json b/aws-sdk-core/apis/CloudFront.waiters.json index f6d3ba7bc05..edd74b2a3b4 100644 --- a/aws-sdk-core/apis/CloudFront.waiters.json +++ b/aws-sdk-core/apis/CloudFront.waiters.json @@ -11,7 +11,7 @@ "expected": "Deployed", "matcher": "path", "state": "success", - "argument": "Status" + "argument": "Distribution.Status" } ] }, @@ -25,7 +25,7 @@ "expected": "Completed", "matcher": "path", "state": "success", - "argument": "Status" + "argument": "Invalidation.Status" } ] }, @@ -39,7 +39,7 @@ "expected": "Deployed", "matcher": "path", "state": "success", - "argument": "Status" + "argument": "StreamingDistribution.Status" } ] } diff --git a/aws-sdk-core/apis/RDS.waiters.json b/aws-sdk-core/apis/RDS.waiters.json index b01500797d0..f6538b0359d 100644 --- a/aws-sdk-core/apis/RDS.waiters.json +++ b/aws-sdk-core/apis/RDS.waiters.json @@ -42,12 +42,6 @@ "state": "failure", "argument": "DBInstances[].DBInstanceStatus" }, - { - "expected": "incompatible-parameters", - "matcher": "pathAny", - "state": "failure", - "argument": "DBInstances[].DBInstanceStatus" - }, { "expected": "incompatible-restore", "matcher": "pathAny", @@ -67,6 +61,11 @@ "state": "success", "argument": "DBInstances[].DBInstanceStatus" }, + { + "expected": "DBInstanceNotFound", + "matcher": "error", + "state": "success" + }, { "expected": "creating", "matcher": "pathAny", From 61a4f1f9212cf7acdc3f0a0b2b9e28939393a9ce Mon Sep 17 00:00:00 2001 From: Enis Konuk Date: Mon, 30 Mar 2015 16:41:39 -0400 Subject: [PATCH 2/4] added waiters for CloudFormation, ElastiCache and OpsWorks --- aws-sdk-core/apis/CloudFormation.waiters.json | 70 +++++++ aws-sdk-core/apis/ElastiCache.waiters.json | 143 +++++++++++++ aws-sdk-core/apis/OpsWorks.waiters.json | 190 ++++++++++++++++++ .../lib/aws-sdk-core/cloudformation.rb | 1 + aws-sdk-core/lib/aws-sdk-core/elasticache.rb | 1 + aws-sdk-core/lib/aws-sdk-core/opsworks.rb | 1 + 6 files changed, 406 insertions(+) create mode 100644 aws-sdk-core/apis/CloudFormation.waiters.json create mode 100644 aws-sdk-core/apis/ElastiCache.waiters.json create mode 100644 aws-sdk-core/apis/OpsWorks.waiters.json diff --git a/aws-sdk-core/apis/CloudFormation.waiters.json b/aws-sdk-core/apis/CloudFormation.waiters.json new file mode 100644 index 00000000000..8daeb7c762a --- /dev/null +++ b/aws-sdk-core/apis/CloudFormation.waiters.json @@ -0,0 +1,70 @@ +{ + "version": 2, + "waiters": { + "StackCreateComplete": { + "delay": 30, + "operation": "DescribeStacks", + "maxAttempts": 50, + "description": "Wait until stack status is CREATE_COMPLETE.", + "acceptors": [ + { + "expected": "CREATE_COMPLETE", + "matcher": "pathAll", + "state": "success", + "argument": "Stacks[].StackStatus" + }, + { + "expected": "CREATE_FAILED", + "matcher": "pathAny", + "state": "failure", + "argument": "Stacks[].StackStatus" + } + ] + }, + "StackDeleteComplete": { + "delay": 30, + "operation": "DescribeStacks", + "maxAttempts": 25, + "description": "Wait until stack status is DELETE_COMPLETE.", + "acceptors": [ + { + "expected": "DELETE_COMPLETE", + "matcher": "pathAll", + "state": "success", + "argument": "Stacks[].StackStatus" + }, + { + "expected": "ValidationError", + "matcher": "error", + "state": "success" + }, + { + "expected": "DELETE_FAILED", + "matcher": "pathAny", + "state": "failure", + "argument": "Stacks[].StackStatus" + } + ] + }, + "StackUpdateComplete": { + "delay": 30, + "operation": "DescribeStacks", + "maxAttempts": 5, + "description": "Wait until stack status is UPDATE_COMPLETE.", + "acceptors": [ + { + "expected": "UPDATE_COMPLETE", + "matcher": "pathAll", + "state": "success", + "argument": "Stacks[].StackStatus" + }, + { + "expected": "UPDATE_FAILED", + "matcher": "pathAny", + "state": "failure", + "argument": "Stacks[].StackStatus" + } + ] + } + } +} diff --git a/aws-sdk-core/apis/ElastiCache.waiters.json b/aws-sdk-core/apis/ElastiCache.waiters.json new file mode 100644 index 00000000000..219b3f0e4f8 --- /dev/null +++ b/aws-sdk-core/apis/ElastiCache.waiters.json @@ -0,0 +1,143 @@ +{ + "version": 2, + "waiters": { + "CacheClusterAvailable": { + "delay": 15, + "operation": "DescribeCacheClusters", + "maxAttempts": 40, + "description": "Wait until ElastiCache cluster is available.", + "acceptors": [ + { + "expected": "available", + "matcher": "pathAll", + "state": "success", + "argument": "CacheClusters[].CacheClusterStatus" + }, + { + "expected": "deleted", + "matcher": "pathAny", + "state": "failure", + "argument": "CacheClusters[].CacheClusterStatus" + }, + { + "expected": "deleting", + "matcher": "pathAny", + "state": "failure", + "argument": "CacheClusters[].CacheClusterStatus" + }, + { + "expected": "incompatible-network", + "matcher": "pathAny", + "state": "failure", + "argument": "CacheClusters[].CacheClusterStatus" + }, + { + "expected": "restore-failed", + "matcher": "pathAny", + "state": "failure", + "argument": "CacheClusters[].CacheClusterStatus" + } + ] + }, + "CacheClusterDeleted": { + "delay": 15, + "operation": "DescribeCacheClusters", + "maxAttempts": 40, + "description": "Wait until ElastiCache cluster is deleted.", + "acceptors": [ + { + "expected": "deleted", + "matcher": "pathAll", + "state": "success", + "argument": "CacheClusters[].CacheClusterStatus" + }, + { + "expected": "CacheClusterNotFound", + "matcher": "error", + "state": "success" + }, + { + "expected": "available", + "matcher": "pathAny", + "state": "failure", + "argument": "CacheClusters[].CacheClusterStatus" + }, + { + "expected": "creating", + "matcher": "pathAny", + "state": "failure", + "argument": "CacheClusters[].CacheClusterStatus" + }, + { + "expected": "incompatible-network", + "matcher": "pathAny", + "state": "failure", + "argument": "CacheClusters[].CacheClusterStatus" + }, + { + "expected": "modifying", + "matcher": "pathAny", + "state": "failure", + "argument": "CacheClusters[].CacheClusterStatus" + }, + { + "expected": "restore-failed", + "matcher": "pathAny", + "state": "failure", + "argument": "CacheClusters[].CacheClusterStatus" + }, + { + "expected": "snapshotting", + "matcher": "pathAny", + "state": "failure", + "argument": "CacheClusters[].CacheClusterStatus" + } + ] + }, + "ReplicationGroupAvailable": { + "delay": 15, + "operation": "DescribeReplicationGroups", + "maxAttempts": 40, + "description": "Wait until ElastiCache replication group is available.", + "acceptors": [ + { + "expected": "available", + "matcher": "pathAll", + "state": "success", + "argument": "ReplicationGroups[].Status" + }, + { + "expected": "deleted", + "matcher": "pathAny", + "state": "failure", + "argument": "ReplicationGroups[].Status" + } + ] + }, + "ReplicationGroupDeleted": { + "delay": 15, + "operation": "DescribeReplicationGroups", + "maxAttempts": 40, + "description": "Wait until ElastiCache replication group is deleted.", + "acceptors": [ + { + "expected": "deleted", + "matcher": "pathAll", + "state": "success", + "argument": "ReplicationGroups[].Status" + }, + { + "expected": "available", + "matcher": "pathAny", + "state": "failure", + "argument": "ReplicationGroups[].Status" + }, + { + "expected": "ReplicationGroupNotFoundFault", + "matcher": "error", + "state": "success" + } + ] + } + } +} diff --git a/aws-sdk-core/apis/OpsWorks.waiters.json b/aws-sdk-core/apis/OpsWorks.waiters.json new file mode 100644 index 00000000000..2b5bb44de6e --- /dev/null +++ b/aws-sdk-core/apis/OpsWorks.waiters.json @@ -0,0 +1,190 @@ +{ + "version": 2, + "waiters": { + "InstanceOnline": { + "delay": 15, + "operation": "DescribeInstances", + "maxAttempts": 40, + "description": "Wait until OpsWorks instance is online.", + "acceptors": [ + { + "expected": "online", + "matcher": "pathAll", + "state": "success", + "argument": "Instances[].Status" + }, + { + "expected": "setup_failed", + "matcher": "pathAny", + "state": "failure", + "argument": "Instances[].Status" + }, + { + "expected": "shutting_down", + "matcher": "pathAny", + "state": "failure", + "argument": "Instances[].Status" + }, + { + "expected": "start_failed", + "matcher": "pathAny", + "state": "failure", + "argument": "Instances[].Status" + }, + { + "expected": "stopped", + "matcher": "pathAny", + "state": "failure", + "argument": "Instances[].Status" + }, + { + "expected": "stopping", + "matcher": "pathAny", + "state": "failure", + "argument": "Instances[].Status" + }, + { + "expected": "terminating", + "matcher": "pathAny", + "state": "failure", + "argument": "Instances[].Status" + }, + { + "expected": "terminated", + "matcher": "pathAny", + "state": "failure", + "argument": "Instances[].Status" + } + ] + }, + "InstanceStopped": { + "delay": 15, + "operation": "DescribeInstances", + "maxAttempts": 40, + "description": "Wait until OpsWorks instance is stopped.", + "acceptors": [ + { + "expected": "stopped", + "matcher": "pathAll", + "state": "success", + "argument": "Instances[].Status" + }, + { + "expected": "booting", + "matcher": "pathAny", + "state": "failure", + "argument": "Instances[].Status" + }, + { + "expected": "online", + "matcher": "pathAny", + "state": "failure", + "argument": "Instances[].Status" + }, + { + "expected": "pending", + "matcher": "pathAny", + "state": "failure", + "argument": "Instances[].Status" + }, + { + "expected": "rebooting", + "matcher": "pathAny", + "state": "failure", + "argument": "Instances[].Status" + }, + { + "expected": "requested", + "matcher": "pathAny", + "state": "failure", + "argument": "Instances[].Status" + }, + { + "expected": "running_setup", + "matcher": "pathAny", + "state": "failure", + "argument": "Instances[].Status" + }, + { + "expected": "setup_failed", + "matcher": "pathAny", + "state": "failure", + "argument": "Instances[].Status" + }, + { + "expected": "start_failed", + "matcher": "pathAny", + "state": "failure", + "argument": "Instances[].Status" + } + ] + }, + "InstanceTerminated": { + "delay": 15, + "operation": "DescribeInstances", + "maxAttempts": 40, + "description": "Wait until OpsWorks instance is terminated.", + "acceptors": [ + { + "expected": "terminated", + "matcher": "pathAll", + "state": "success", + "argument": "Instances[].Status" + }, + { + "expected": "ResourceNotFoundException", + "matcher": "error", + "state": "success" + }, + { + "expected": "booting", + "matcher": "pathAny", + "state": "failure", + "argument": "Instances[].Status" + }, + { + "expected": "online", + "matcher": "pathAny", + "state": "failure", + "argument": "Instances[].Status" + }, + { + "expected": "pending", + "matcher": "pathAny", + "state": "failure", + "argument": "Instances[].Status" + }, + { + "expected": "rebooting", + "matcher": "pathAny", + "state": "failure", + "argument": "Instances[].Status" + }, + { + "expected": "requested", + "matcher": "pathAny", + "state": "failure", + "argument": "Instances[].Status" + }, + { + "expected": "running_setup", + "matcher": "pathAny", + "state": "failure", + "argument": "Instances[].Status" + }, + { + "expected": "setup_failed", + "matcher": "pathAny", + "state": "failure", + "argument": "Instances[].Status" + }, + { + "expected": "start_failed", + "matcher": "pathAny", + "state": "failure", + "argument": "Instances[].Status" + } + ] + } + } +} diff --git a/aws-sdk-core/lib/aws-sdk-core/cloudformation.rb b/aws-sdk-core/lib/aws-sdk-core/cloudformation.rb index 069e96675d4..29058b8bffb 100644 --- a/aws-sdk-core/lib/aws-sdk-core/cloudformation.rb +++ b/aws-sdk-core/lib/aws-sdk-core/cloudformation.rb @@ -3,4 +3,5 @@ docs: File.join(Aws::API_DIR, 'CloudFormation.docs.json'), paginators: File.join(Aws::API_DIR, 'CloudFormation.paginators.json'), resources: File.join(Aws::API_DIR, 'CloudFormation.resources.json'), + waiters: File.join(Aws::API_DIR, 'CloudFormation.waiters.json'), }) diff --git a/aws-sdk-core/lib/aws-sdk-core/elasticache.rb b/aws-sdk-core/lib/aws-sdk-core/elasticache.rb index 5dc5410e643..f2955230643 100644 --- a/aws-sdk-core/lib/aws-sdk-core/elasticache.rb +++ b/aws-sdk-core/lib/aws-sdk-core/elasticache.rb @@ -2,4 +2,5 @@ api: File.join(Aws::API_DIR, 'ElastiCache.api.json'), docs: File.join(Aws::API_DIR, 'ElastiCache.docs.json'), paginators: File.join(Aws::API_DIR, 'ElastiCache.paginators.json'), + waiters: File.join(Aws::API_DIR, 'ElastiCache.waiters.json'), }) diff --git a/aws-sdk-core/lib/aws-sdk-core/opsworks.rb b/aws-sdk-core/lib/aws-sdk-core/opsworks.rb index ea76e0e78b2..1e8b5ec3368 100644 --- a/aws-sdk-core/lib/aws-sdk-core/opsworks.rb +++ b/aws-sdk-core/lib/aws-sdk-core/opsworks.rb @@ -3,4 +3,5 @@ docs: File.join(Aws::API_DIR, 'OpsWorks.docs.json'), paginators: File.join(Aws::API_DIR, 'OpsWorks.paginators.json'), resources: File.join(Aws::API_DIR, 'OpsWorks.resources.json'), + waiters: File.join(Aws::API_DIR, 'OpsWorks.waiters.json'), }) From 95aa4090108322f9f1913ad06ed2915ddc8eeabe Mon Sep 17 00:00:00 2001 From: Enis Konuk Date: Mon, 30 Mar 2015 18:18:38 -0400 Subject: [PATCH 3/4] added KeyPairExists and NetworkInterfaceAvailable to EC2 waiters --- aws-sdk-core/apis/EC2.waiters.json | 36 ++++++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) diff --git a/aws-sdk-core/apis/EC2.waiters.json b/aws-sdk-core/apis/EC2.waiters.json index 17f087055b6..48cd998dc81 100644 --- a/aws-sdk-core/apis/EC2.waiters.json +++ b/aws-sdk-core/apis/EC2.waiters.json @@ -235,6 +235,42 @@ } ] }, + "KeyPairExists": { + "operation": "DescribeKeyPairs", + "delay": 5, + "maxAttempts": 6, + "acceptors": [ + { + "expected": true, + "matcher": "pathAll", + "state": "success", + "argument": "length(KeyPairs[].KeyName) > `0`" + }, + { + "expected": "InvalidKeyPairNotFound", + "matcher": "error", + "state": "retry" + } + ] + }, + "NetworkInterfaceAvailable": { + "operation": "DescribeNetworkInterfaces", + "delay": 20, + "maxAttempts": 10, + "acceptors": [ + { + "expected": "available", + "matcher": "pathAll", + "state": "success", + "argument": "NetworkInterfaces[].Status" + }, + { + "expected": "InvalidNetworkInterfaceIDNotFound", + "matcher": "error", + "state": "failure" + } + ] + }, "PasswordDataAvailable": { "operation": "GetPasswordData", "maxAttempts": 40, From bd115ca62c495e0470c7801d565d1974e80e49dc Mon Sep 17 00:00:00 2001 From: Enis Konuk Date: Fri, 10 Apr 2015 12:13:21 -0400 Subject: [PATCH 4/4] renamed waiter files to match new directory structure --- aws-sdk-core/apis/CloudFormation.waiters.json | 70 ------- aws-sdk-core/apis/ElastiCache.waiters.json | 143 ------------- aws-sdk-core/apis/OpsWorks.waiters.json | 190 ------------------ 3 files changed, 403 deletions(-) delete mode 100644 aws-sdk-core/apis/CloudFormation.waiters.json delete mode 100644 aws-sdk-core/apis/ElastiCache.waiters.json delete mode 100644 aws-sdk-core/apis/OpsWorks.waiters.json diff --git a/aws-sdk-core/apis/CloudFormation.waiters.json b/aws-sdk-core/apis/CloudFormation.waiters.json deleted file mode 100644 index 8daeb7c762a..00000000000 --- a/aws-sdk-core/apis/CloudFormation.waiters.json +++ /dev/null @@ -1,70 +0,0 @@ -{ - "version": 2, - "waiters": { - "StackCreateComplete": { - "delay": 30, - "operation": "DescribeStacks", - "maxAttempts": 50, - "description": "Wait until stack status is CREATE_COMPLETE.", - "acceptors": [ - { - "expected": "CREATE_COMPLETE", - "matcher": "pathAll", - "state": "success", - "argument": "Stacks[].StackStatus" - }, - { - "expected": "CREATE_FAILED", - "matcher": "pathAny", - "state": "failure", - "argument": "Stacks[].StackStatus" - } - ] - }, - "StackDeleteComplete": { - "delay": 30, - "operation": "DescribeStacks", - "maxAttempts": 25, - "description": "Wait until stack status is DELETE_COMPLETE.", - "acceptors": [ - { - "expected": "DELETE_COMPLETE", - "matcher": "pathAll", - "state": "success", - "argument": "Stacks[].StackStatus" - }, - { - "expected": "ValidationError", - "matcher": "error", - "state": "success" - }, - { - "expected": "DELETE_FAILED", - "matcher": "pathAny", - "state": "failure", - "argument": "Stacks[].StackStatus" - } - ] - }, - "StackUpdateComplete": { - "delay": 30, - "operation": "DescribeStacks", - "maxAttempts": 5, - "description": "Wait until stack status is UPDATE_COMPLETE.", - "acceptors": [ - { - "expected": "UPDATE_COMPLETE", - "matcher": "pathAll", - "state": "success", - "argument": "Stacks[].StackStatus" - }, - { - "expected": "UPDATE_FAILED", - "matcher": "pathAny", - "state": "failure", - "argument": "Stacks[].StackStatus" - } - ] - } - } -} diff --git a/aws-sdk-core/apis/ElastiCache.waiters.json b/aws-sdk-core/apis/ElastiCache.waiters.json deleted file mode 100644 index 219b3f0e4f8..00000000000 --- a/aws-sdk-core/apis/ElastiCache.waiters.json +++ /dev/null @@ -1,143 +0,0 @@ -{ - "version": 2, - "waiters": { - "CacheClusterAvailable": { - "delay": 15, - "operation": "DescribeCacheClusters", - "maxAttempts": 40, - "description": "Wait until ElastiCache cluster is available.", - "acceptors": [ - { - "expected": "available", - "matcher": "pathAll", - "state": "success", - "argument": "CacheClusters[].CacheClusterStatus" - }, - { - "expected": "deleted", - "matcher": "pathAny", - "state": "failure", - "argument": "CacheClusters[].CacheClusterStatus" - }, - { - "expected": "deleting", - "matcher": "pathAny", - "state": "failure", - "argument": "CacheClusters[].CacheClusterStatus" - }, - { - "expected": "incompatible-network", - "matcher": "pathAny", - "state": "failure", - "argument": "CacheClusters[].CacheClusterStatus" - }, - { - "expected": "restore-failed", - "matcher": "pathAny", - "state": "failure", - "argument": "CacheClusters[].CacheClusterStatus" - } - ] - }, - "CacheClusterDeleted": { - "delay": 15, - "operation": "DescribeCacheClusters", - "maxAttempts": 40, - "description": "Wait until ElastiCache cluster is deleted.", - "acceptors": [ - { - "expected": "deleted", - "matcher": "pathAll", - "state": "success", - "argument": "CacheClusters[].CacheClusterStatus" - }, - { - "expected": "CacheClusterNotFound", - "matcher": "error", - "state": "success" - }, - { - "expected": "available", - "matcher": "pathAny", - "state": "failure", - "argument": "CacheClusters[].CacheClusterStatus" - }, - { - "expected": "creating", - "matcher": "pathAny", - "state": "failure", - "argument": "CacheClusters[].CacheClusterStatus" - }, - { - "expected": "incompatible-network", - "matcher": "pathAny", - "state": "failure", - "argument": "CacheClusters[].CacheClusterStatus" - }, - { - "expected": "modifying", - "matcher": "pathAny", - "state": "failure", - "argument": "CacheClusters[].CacheClusterStatus" - }, - { - "expected": "restore-failed", - "matcher": "pathAny", - "state": "failure", - "argument": "CacheClusters[].CacheClusterStatus" - }, - { - "expected": "snapshotting", - "matcher": "pathAny", - "state": "failure", - "argument": "CacheClusters[].CacheClusterStatus" - } - ] - }, - "ReplicationGroupAvailable": { - "delay": 15, - "operation": "DescribeReplicationGroups", - "maxAttempts": 40, - "description": "Wait until ElastiCache replication group is available.", - "acceptors": [ - { - "expected": "available", - "matcher": "pathAll", - "state": "success", - "argument": "ReplicationGroups[].Status" - }, - { - "expected": "deleted", - "matcher": "pathAny", - "state": "failure", - "argument": "ReplicationGroups[].Status" - } - ] - }, - "ReplicationGroupDeleted": { - "delay": 15, - "operation": "DescribeReplicationGroups", - "maxAttempts": 40, - "description": "Wait until ElastiCache replication group is deleted.", - "acceptors": [ - { - "expected": "deleted", - "matcher": "pathAll", - "state": "success", - "argument": "ReplicationGroups[].Status" - }, - { - "expected": "available", - "matcher": "pathAny", - "state": "failure", - "argument": "ReplicationGroups[].Status" - }, - { - "expected": "ReplicationGroupNotFoundFault", - "matcher": "error", - "state": "success" - } - ] - } - } -} diff --git a/aws-sdk-core/apis/OpsWorks.waiters.json b/aws-sdk-core/apis/OpsWorks.waiters.json deleted file mode 100644 index 2b5bb44de6e..00000000000 --- a/aws-sdk-core/apis/OpsWorks.waiters.json +++ /dev/null @@ -1,190 +0,0 @@ -{ - "version": 2, - "waiters": { - "InstanceOnline": { - "delay": 15, - "operation": "DescribeInstances", - "maxAttempts": 40, - "description": "Wait until OpsWorks instance is online.", - "acceptors": [ - { - "expected": "online", - "matcher": "pathAll", - "state": "success", - "argument": "Instances[].Status" - }, - { - "expected": "setup_failed", - "matcher": "pathAny", - "state": "failure", - "argument": "Instances[].Status" - }, - { - "expected": "shutting_down", - "matcher": "pathAny", - "state": "failure", - "argument": "Instances[].Status" - }, - { - "expected": "start_failed", - "matcher": "pathAny", - "state": "failure", - "argument": "Instances[].Status" - }, - { - "expected": "stopped", - "matcher": "pathAny", - "state": "failure", - "argument": "Instances[].Status" - }, - { - "expected": "stopping", - "matcher": "pathAny", - "state": "failure", - "argument": "Instances[].Status" - }, - { - "expected": "terminating", - "matcher": "pathAny", - "state": "failure", - "argument": "Instances[].Status" - }, - { - "expected": "terminated", - "matcher": "pathAny", - "state": "failure", - "argument": "Instances[].Status" - } - ] - }, - "InstanceStopped": { - "delay": 15, - "operation": "DescribeInstances", - "maxAttempts": 40, - "description": "Wait until OpsWorks instance is stopped.", - "acceptors": [ - { - "expected": "stopped", - "matcher": "pathAll", - "state": "success", - "argument": "Instances[].Status" - }, - { - "expected": "booting", - "matcher": "pathAny", - "state": "failure", - "argument": "Instances[].Status" - }, - { - "expected": "online", - "matcher": "pathAny", - "state": "failure", - "argument": "Instances[].Status" - }, - { - "expected": "pending", - "matcher": "pathAny", - "state": "failure", - "argument": "Instances[].Status" - }, - { - "expected": "rebooting", - "matcher": "pathAny", - "state": "failure", - "argument": "Instances[].Status" - }, - { - "expected": "requested", - "matcher": "pathAny", - "state": "failure", - "argument": "Instances[].Status" - }, - { - "expected": "running_setup", - "matcher": "pathAny", - "state": "failure", - "argument": "Instances[].Status" - }, - { - "expected": "setup_failed", - "matcher": "pathAny", - "state": "failure", - "argument": "Instances[].Status" - }, - { - "expected": "start_failed", - "matcher": "pathAny", - "state": "failure", - "argument": "Instances[].Status" - } - ] - }, - "InstanceTerminated": { - "delay": 15, - "operation": "DescribeInstances", - "maxAttempts": 40, - "description": "Wait until OpsWorks instance is terminated.", - "acceptors": [ - { - "expected": "terminated", - "matcher": "pathAll", - "state": "success", - "argument": "Instances[].Status" - }, - { - "expected": "ResourceNotFoundException", - "matcher": "error", - "state": "success" - }, - { - "expected": "booting", - "matcher": "pathAny", - "state": "failure", - "argument": "Instances[].Status" - }, - { - "expected": "online", - "matcher": "pathAny", - "state": "failure", - "argument": "Instances[].Status" - }, - { - "expected": "pending", - "matcher": "pathAny", - "state": "failure", - "argument": "Instances[].Status" - }, - { - "expected": "rebooting", - "matcher": "pathAny", - "state": "failure", - "argument": "Instances[].Status" - }, - { - "expected": "requested", - "matcher": "pathAny", - "state": "failure", - "argument": "Instances[].Status" - }, - { - "expected": "running_setup", - "matcher": "pathAny", - "state": "failure", - "argument": "Instances[].Status" - }, - { - "expected": "setup_failed", - "matcher": "pathAny", - "state": "failure", - "argument": "Instances[].Status" - }, - { - "expected": "start_failed", - "matcher": "pathAny", - "state": "failure", - "argument": "Instances[].Status" - } - ] - } - } -}