-- | Polls 'Network.AWS.ElastiCache.DescribeCacheClusters' every 30 seconds until a
-- successful state is reached. An error is returned after 60 failed checks.
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)]
    }
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)]
    }
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)]
    }