{-# LANGUAGE DisambiguateRecordFields #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE StrictData #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
module Amazonka.CertificateManagerPCA.Waiters where
import Amazonka.CertificateManagerPCA.DescribeCertificateAuthorityAuditReport
import Amazonka.CertificateManagerPCA.GetCertificate
import Amazonka.CertificateManagerPCA.GetCertificateAuthorityCsr
import Amazonka.CertificateManagerPCA.Lens
import Amazonka.CertificateManagerPCA.Types
import qualified Amazonka.Core as Core
import qualified Amazonka.Core.Lens.Internal as Lens
import qualified Amazonka.Data as Data
import qualified Amazonka.Prelude as Prelude
newAuditReportCreated :: Core.Wait DescribeCertificateAuthorityAuditReport
newAuditReportCreated :: Wait DescribeCertificateAuthorityAuditReport
newAuditReportCreated =
Core.Wait
{ $sel:name:Wait :: ByteString
Core.name = ByteString
"AuditReportCreated",
$sel:attempts:Wait :: Int
Core.attempts = Int
60,
$sel:delay:Wait :: Seconds
Core.delay = Seconds
3,
$sel:acceptors:Wait :: [Acceptor DescribeCertificateAuthorityAuditReport]
Core.acceptors =
[ forall b a.
Eq b =>
b -> Accept -> Fold (AWSResponse a) b -> Acceptor a
Core.matchAll
CI Text
"SUCCESS"
Accept
Core.AcceptSuccess
( Lens'
DescribeCertificateAuthorityAuditReportResponse
(Maybe AuditReportStatus)
describeCertificateAuthorityAuditReportResponse_auditReportStatus
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall a b. Prism (Maybe a) (Maybe b) a b
Lens._Just
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (p :: * -> * -> *) (f :: * -> *) s a.
(Profunctor p, Contravariant f) =>
(s -> a) -> Optic' p f s a
Lens.to forall a. ToText a => a -> CI Text
Data.toTextCI
),
forall b a.
Eq b =>
b -> Accept -> Fold (AWSResponse a) b -> Acceptor a
Core.matchAll
CI Text
"FAILED"
Accept
Core.AcceptFailure
( Lens'
DescribeCertificateAuthorityAuditReportResponse
(Maybe AuditReportStatus)
describeCertificateAuthorityAuditReportResponse_auditReportStatus
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall a b. Prism (Maybe a) (Maybe b) a b
Lens._Just
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall (p :: * -> * -> *) (f :: * -> *) s a.
(Profunctor p, Contravariant f) =>
(s -> a) -> Optic' p f s a
Lens.to forall a. ToText a => a -> CI Text
Data.toTextCI
)
]
}
newCertificateAuthorityCSRCreated :: Core.Wait GetCertificateAuthorityCsr
newCertificateAuthorityCSRCreated :: Wait GetCertificateAuthorityCsr
newCertificateAuthorityCSRCreated =
Core.Wait
{ $sel:name:Wait :: ByteString
Core.name =
ByteString
"CertificateAuthorityCSRCreated",
$sel:attempts:Wait :: Int
Core.attempts = Int
60,
$sel:delay:Wait :: Seconds
Core.delay = Seconds
3,
$sel:acceptors:Wait :: [Acceptor GetCertificateAuthorityCsr]
Core.acceptors =
[ forall a. Int -> Accept -> Acceptor a
Core.matchStatus Int
200 Accept
Core.AcceptSuccess,
forall a. ErrorCode -> Accept -> Acceptor a
Core.matchError
ErrorCode
"RequestInProgressException"
Accept
Core.AcceptRetry
]
}
newCertificateIssued :: Core.Wait GetCertificate
newCertificateIssued :: Wait GetCertificate
newCertificateIssued =
Core.Wait
{ $sel:name:Wait :: ByteString
Core.name = ByteString
"CertificateIssued",
$sel:attempts:Wait :: Int
Core.attempts = Int
60,
$sel:delay:Wait :: Seconds
Core.delay = Seconds
3,
$sel:acceptors:Wait :: [Acceptor GetCertificate]
Core.acceptors =
[ forall a. Int -> Accept -> Acceptor a
Core.matchStatus Int
200 Accept
Core.AcceptSuccess,
forall a. ErrorCode -> Accept -> Acceptor a
Core.matchError
ErrorCode
"RequestInProgressException"
Accept
Core.AcceptRetry
]
}