module Network.AWS.ElastiCache.Waiters where
import Network.AWS.ElastiCache.DescribeCacheClusters
import Network.AWS.ElastiCache.DescribeCacheClusters
import Network.AWS.ElastiCache.DescribeReplicationGroups
import Network.AWS.ElastiCache.DescribeReplicationGroups
import Network.AWS.ElastiCache.Types
import Network.AWS.Prelude
import Network.AWS.Waiter
cacheClusterAvailable :: Wait DescribeCacheClusters
cacheClusterAvailable =
Wait
{ _waitName = "CacheClusterAvailable"
, _waitAttempts = 60
, _waitDelay = 30
, _waitAcceptors = [ matchAll
"available"
AcceptSuccess
(folding (concatOf drsCacheClusters) .
ccCacheClusterStatus . _Just . to toTextCI)
, matchAny
"deleted"
AcceptFailure
(folding (concatOf drsCacheClusters) .
ccCacheClusterStatus . _Just . to toTextCI)
, matchAny
"deleting"
AcceptFailure
(folding (concatOf drsCacheClusters) .
ccCacheClusterStatus . _Just . to toTextCI)
, matchAny
"incompatible-network"
AcceptFailure
(folding (concatOf drsCacheClusters) .
ccCacheClusterStatus . _Just . to toTextCI)
, matchAny
"restore-failed"
AcceptFailure
(folding (concatOf drsCacheClusters) .
ccCacheClusterStatus . _Just . to toTextCI)]
}
cacheClusterDeleted :: Wait DescribeCacheClusters
cacheClusterDeleted =
Wait
{ _waitName = "CacheClusterDeleted"
, _waitAttempts = 60
, _waitDelay = 30
, _waitAcceptors = [ matchError "CacheClusterNotFound" AcceptSuccess
, matchAny
"creating"
AcceptFailure
(folding (concatOf drsCacheClusters) .
ccCacheClusterStatus . _Just . to toTextCI)
, matchAny
"modifying"
AcceptFailure
(folding (concatOf drsCacheClusters) .
ccCacheClusterStatus . _Just . to toTextCI)
, matchAny
"rebooting"
AcceptFailure
(folding (concatOf drsCacheClusters) .
ccCacheClusterStatus . _Just . to toTextCI)]
}
replicationGroupDeleted :: Wait DescribeReplicationGroups
replicationGroupDeleted =
Wait
{ _waitName = "ReplicationGroupDeleted"
, _waitAttempts = 60
, _waitDelay = 30
, _waitAcceptors = [ matchError
"ReplicationGroupNotFoundFault"
AcceptSuccess
, matchAny
"creating"
AcceptFailure
(folding (concatOf drgrsReplicationGroups) .
rgStatus . _Just . to toTextCI)
, matchAny
"modifying"
AcceptFailure
(folding (concatOf drgrsReplicationGroups) .
rgStatus . _Just . to toTextCI)
, matchAny
"rebooting"
AcceptFailure
(folding (concatOf drgrsReplicationGroups) .
rgStatus . _Just . to toTextCI)]
}
replicationGroupAvailable :: Wait DescribeReplicationGroups
replicationGroupAvailable =
Wait
{ _waitName = "ReplicationGroupAvailable"
, _waitAttempts = 60
, _waitDelay = 30
, _waitAcceptors = [ matchAll
"available"
AcceptSuccess
(folding (concatOf drgrsReplicationGroups) .
rgStatus . _Just . to toTextCI)
, matchAny
"deleted"
AcceptFailure
(folding (concatOf drgrsReplicationGroups) .
rgStatus . _Just . to toTextCI)
, matchAny
"deleting"
AcceptFailure
(folding (concatOf drgrsReplicationGroups) .
rgStatus . _Just . to toTextCI)
, matchAny
"incompatible-network"
AcceptFailure
(folding (concatOf drgrsReplicationGroups) .
rgStatus . _Just . to toTextCI)
, matchAny
"restore-failed"
AcceptFailure
(folding (concatOf drgrsReplicationGroups) .
rgStatus . _Just . to toTextCI)]
}