{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE DuplicateRecordFields #-}
{-# LANGUAGE NamedFieldPuns #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE StrictData #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-unused-matches #-}

-- Derived from AWS service descriptions, licensed under Apache 2.0.

-- |
-- Module      : Amazonka.SSM.Types.InstanceAssociationStatusInfo
-- Copyright   : (c) 2013-2021 Brendan Hay
-- License     : Mozilla Public License, v. 2.0.
-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>
-- Stability   : auto-generated
-- Portability : non-portable (GHC extensions)
module Amazonka.SSM.Types.InstanceAssociationStatusInfo where

import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
import Amazonka.SSM.Types.InstanceAssociationOutputUrl

-- | Status information about the instance association.
--
-- /See:/ 'newInstanceAssociationStatusInfo' smart constructor.
data InstanceAssociationStatusInfo = InstanceAssociationStatusInfo'
  { -- | The association ID.
    InstanceAssociationStatusInfo -> Maybe Text
associationId :: Prelude.Maybe Prelude.Text,
    -- | The instance ID where the association was created.
    InstanceAssociationStatusInfo -> Maybe Text
instanceId :: Prelude.Maybe Prelude.Text,
    -- | Detailed status information about the instance association.
    InstanceAssociationStatusInfo -> Maybe Text
detailedStatus :: Prelude.Maybe Prelude.Text,
    -- | Status information about the instance association.
    InstanceAssociationStatusInfo -> Maybe Text
status :: Prelude.Maybe Prelude.Text,
    -- | A URL for an S3 bucket where you want to store the results of this
    -- request.
    InstanceAssociationStatusInfo -> Maybe InstanceAssociationOutputUrl
outputUrl :: Prelude.Maybe InstanceAssociationOutputUrl,
    -- | Summary information about association execution.
    InstanceAssociationStatusInfo -> Maybe Text
executionSummary :: Prelude.Maybe Prelude.Text,
    -- | The name of the association.
    InstanceAssociationStatusInfo -> Maybe Text
name :: Prelude.Maybe Prelude.Text,
    -- | An error code returned by the request to create the association.
    InstanceAssociationStatusInfo -> Maybe Text
errorCode :: Prelude.Maybe Prelude.Text,
    -- | The association document versions.
    InstanceAssociationStatusInfo -> Maybe Text
documentVersion :: Prelude.Maybe Prelude.Text,
    -- | The version of the association applied to the instance.
    InstanceAssociationStatusInfo -> Maybe Text
associationVersion :: Prelude.Maybe Prelude.Text,
    -- | The date the instance association ran.
    InstanceAssociationStatusInfo -> Maybe POSIX
executionDate :: Prelude.Maybe Core.POSIX,
    -- | The name of the association applied to the instance.
    InstanceAssociationStatusInfo -> Maybe Text
associationName :: Prelude.Maybe Prelude.Text
  }
  deriving (InstanceAssociationStatusInfo
-> InstanceAssociationStatusInfo -> Bool
(InstanceAssociationStatusInfo
 -> InstanceAssociationStatusInfo -> Bool)
-> (InstanceAssociationStatusInfo
    -> InstanceAssociationStatusInfo -> Bool)
-> Eq InstanceAssociationStatusInfo
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: InstanceAssociationStatusInfo
-> InstanceAssociationStatusInfo -> Bool
$c/= :: InstanceAssociationStatusInfo
-> InstanceAssociationStatusInfo -> Bool
== :: InstanceAssociationStatusInfo
-> InstanceAssociationStatusInfo -> Bool
$c== :: InstanceAssociationStatusInfo
-> InstanceAssociationStatusInfo -> Bool
Prelude.Eq, ReadPrec [InstanceAssociationStatusInfo]
ReadPrec InstanceAssociationStatusInfo
Int -> ReadS InstanceAssociationStatusInfo
ReadS [InstanceAssociationStatusInfo]
(Int -> ReadS InstanceAssociationStatusInfo)
-> ReadS [InstanceAssociationStatusInfo]
-> ReadPrec InstanceAssociationStatusInfo
-> ReadPrec [InstanceAssociationStatusInfo]
-> Read InstanceAssociationStatusInfo
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [InstanceAssociationStatusInfo]
$creadListPrec :: ReadPrec [InstanceAssociationStatusInfo]
readPrec :: ReadPrec InstanceAssociationStatusInfo
$creadPrec :: ReadPrec InstanceAssociationStatusInfo
readList :: ReadS [InstanceAssociationStatusInfo]
$creadList :: ReadS [InstanceAssociationStatusInfo]
readsPrec :: Int -> ReadS InstanceAssociationStatusInfo
$creadsPrec :: Int -> ReadS InstanceAssociationStatusInfo
Prelude.Read, Int -> InstanceAssociationStatusInfo -> ShowS
[InstanceAssociationStatusInfo] -> ShowS
InstanceAssociationStatusInfo -> String
(Int -> InstanceAssociationStatusInfo -> ShowS)
-> (InstanceAssociationStatusInfo -> String)
-> ([InstanceAssociationStatusInfo] -> ShowS)
-> Show InstanceAssociationStatusInfo
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [InstanceAssociationStatusInfo] -> ShowS
$cshowList :: [InstanceAssociationStatusInfo] -> ShowS
show :: InstanceAssociationStatusInfo -> String
$cshow :: InstanceAssociationStatusInfo -> String
showsPrec :: Int -> InstanceAssociationStatusInfo -> ShowS
$cshowsPrec :: Int -> InstanceAssociationStatusInfo -> ShowS
Prelude.Show, (forall x.
 InstanceAssociationStatusInfo
 -> Rep InstanceAssociationStatusInfo x)
-> (forall x.
    Rep InstanceAssociationStatusInfo x
    -> InstanceAssociationStatusInfo)
-> Generic InstanceAssociationStatusInfo
forall x.
Rep InstanceAssociationStatusInfo x
-> InstanceAssociationStatusInfo
forall x.
InstanceAssociationStatusInfo
-> Rep InstanceAssociationStatusInfo x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep InstanceAssociationStatusInfo x
-> InstanceAssociationStatusInfo
$cfrom :: forall x.
InstanceAssociationStatusInfo
-> Rep InstanceAssociationStatusInfo x
Prelude.Generic)

-- |
-- Create a value of 'InstanceAssociationStatusInfo' with all optional fields omitted.
--
-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.
--
-- The following record fields are available, with the corresponding lenses provided
-- for backwards compatibility:
--
-- 'associationId', 'instanceAssociationStatusInfo_associationId' - The association ID.
--
-- 'instanceId', 'instanceAssociationStatusInfo_instanceId' - The instance ID where the association was created.
--
-- 'detailedStatus', 'instanceAssociationStatusInfo_detailedStatus' - Detailed status information about the instance association.
--
-- 'status', 'instanceAssociationStatusInfo_status' - Status information about the instance association.
--
-- 'outputUrl', 'instanceAssociationStatusInfo_outputUrl' - A URL for an S3 bucket where you want to store the results of this
-- request.
--
-- 'executionSummary', 'instanceAssociationStatusInfo_executionSummary' - Summary information about association execution.
--
-- 'name', 'instanceAssociationStatusInfo_name' - The name of the association.
--
-- 'errorCode', 'instanceAssociationStatusInfo_errorCode' - An error code returned by the request to create the association.
--
-- 'documentVersion', 'instanceAssociationStatusInfo_documentVersion' - The association document versions.
--
-- 'associationVersion', 'instanceAssociationStatusInfo_associationVersion' - The version of the association applied to the instance.
--
-- 'executionDate', 'instanceAssociationStatusInfo_executionDate' - The date the instance association ran.
--
-- 'associationName', 'instanceAssociationStatusInfo_associationName' - The name of the association applied to the instance.
newInstanceAssociationStatusInfo ::
  InstanceAssociationStatusInfo
newInstanceAssociationStatusInfo :: InstanceAssociationStatusInfo
newInstanceAssociationStatusInfo =
  InstanceAssociationStatusInfo' :: Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe InstanceAssociationOutputUrl
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> Maybe Text
-> InstanceAssociationStatusInfo
InstanceAssociationStatusInfo'
    { $sel:associationId:InstanceAssociationStatusInfo' :: Maybe Text
associationId =
        Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:instanceId:InstanceAssociationStatusInfo' :: Maybe Text
instanceId = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:detailedStatus:InstanceAssociationStatusInfo' :: Maybe Text
detailedStatus = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:status:InstanceAssociationStatusInfo' :: Maybe Text
status = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:outputUrl:InstanceAssociationStatusInfo' :: Maybe InstanceAssociationOutputUrl
outputUrl = Maybe InstanceAssociationOutputUrl
forall a. Maybe a
Prelude.Nothing,
      $sel:executionSummary:InstanceAssociationStatusInfo' :: Maybe Text
executionSummary = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:name:InstanceAssociationStatusInfo' :: Maybe Text
name = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:errorCode:InstanceAssociationStatusInfo' :: Maybe Text
errorCode = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:documentVersion:InstanceAssociationStatusInfo' :: Maybe Text
documentVersion = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:associationVersion:InstanceAssociationStatusInfo' :: Maybe Text
associationVersion = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:executionDate:InstanceAssociationStatusInfo' :: Maybe POSIX
executionDate = Maybe POSIX
forall a. Maybe a
Prelude.Nothing,
      $sel:associationName:InstanceAssociationStatusInfo' :: Maybe Text
associationName = Maybe Text
forall a. Maybe a
Prelude.Nothing
    }

-- | The association ID.
instanceAssociationStatusInfo_associationId :: Lens.Lens' InstanceAssociationStatusInfo (Prelude.Maybe Prelude.Text)
instanceAssociationStatusInfo_associationId :: (Maybe Text -> f (Maybe Text))
-> InstanceAssociationStatusInfo -> f InstanceAssociationStatusInfo
instanceAssociationStatusInfo_associationId = (InstanceAssociationStatusInfo -> Maybe Text)
-> (InstanceAssociationStatusInfo
    -> Maybe Text -> InstanceAssociationStatusInfo)
-> Lens
     InstanceAssociationStatusInfo
     InstanceAssociationStatusInfo
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InstanceAssociationStatusInfo' {Maybe Text
associationId :: Maybe Text
$sel:associationId:InstanceAssociationStatusInfo' :: InstanceAssociationStatusInfo -> Maybe Text
associationId} -> Maybe Text
associationId) (\s :: InstanceAssociationStatusInfo
s@InstanceAssociationStatusInfo' {} Maybe Text
a -> InstanceAssociationStatusInfo
s {$sel:associationId:InstanceAssociationStatusInfo' :: Maybe Text
associationId = Maybe Text
a} :: InstanceAssociationStatusInfo)

-- | The instance ID where the association was created.
instanceAssociationStatusInfo_instanceId :: Lens.Lens' InstanceAssociationStatusInfo (Prelude.Maybe Prelude.Text)
instanceAssociationStatusInfo_instanceId :: (Maybe Text -> f (Maybe Text))
-> InstanceAssociationStatusInfo -> f InstanceAssociationStatusInfo
instanceAssociationStatusInfo_instanceId = (InstanceAssociationStatusInfo -> Maybe Text)
-> (InstanceAssociationStatusInfo
    -> Maybe Text -> InstanceAssociationStatusInfo)
-> Lens
     InstanceAssociationStatusInfo
     InstanceAssociationStatusInfo
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InstanceAssociationStatusInfo' {Maybe Text
instanceId :: Maybe Text
$sel:instanceId:InstanceAssociationStatusInfo' :: InstanceAssociationStatusInfo -> Maybe Text
instanceId} -> Maybe Text
instanceId) (\s :: InstanceAssociationStatusInfo
s@InstanceAssociationStatusInfo' {} Maybe Text
a -> InstanceAssociationStatusInfo
s {$sel:instanceId:InstanceAssociationStatusInfo' :: Maybe Text
instanceId = Maybe Text
a} :: InstanceAssociationStatusInfo)

-- | Detailed status information about the instance association.
instanceAssociationStatusInfo_detailedStatus :: Lens.Lens' InstanceAssociationStatusInfo (Prelude.Maybe Prelude.Text)
instanceAssociationStatusInfo_detailedStatus :: (Maybe Text -> f (Maybe Text))
-> InstanceAssociationStatusInfo -> f InstanceAssociationStatusInfo
instanceAssociationStatusInfo_detailedStatus = (InstanceAssociationStatusInfo -> Maybe Text)
-> (InstanceAssociationStatusInfo
    -> Maybe Text -> InstanceAssociationStatusInfo)
-> Lens
     InstanceAssociationStatusInfo
     InstanceAssociationStatusInfo
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InstanceAssociationStatusInfo' {Maybe Text
detailedStatus :: Maybe Text
$sel:detailedStatus:InstanceAssociationStatusInfo' :: InstanceAssociationStatusInfo -> Maybe Text
detailedStatus} -> Maybe Text
detailedStatus) (\s :: InstanceAssociationStatusInfo
s@InstanceAssociationStatusInfo' {} Maybe Text
a -> InstanceAssociationStatusInfo
s {$sel:detailedStatus:InstanceAssociationStatusInfo' :: Maybe Text
detailedStatus = Maybe Text
a} :: InstanceAssociationStatusInfo)

-- | Status information about the instance association.
instanceAssociationStatusInfo_status :: Lens.Lens' InstanceAssociationStatusInfo (Prelude.Maybe Prelude.Text)
instanceAssociationStatusInfo_status :: (Maybe Text -> f (Maybe Text))
-> InstanceAssociationStatusInfo -> f InstanceAssociationStatusInfo
instanceAssociationStatusInfo_status = (InstanceAssociationStatusInfo -> Maybe Text)
-> (InstanceAssociationStatusInfo
    -> Maybe Text -> InstanceAssociationStatusInfo)
-> Lens
     InstanceAssociationStatusInfo
     InstanceAssociationStatusInfo
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InstanceAssociationStatusInfo' {Maybe Text
status :: Maybe Text
$sel:status:InstanceAssociationStatusInfo' :: InstanceAssociationStatusInfo -> Maybe Text
status} -> Maybe Text
status) (\s :: InstanceAssociationStatusInfo
s@InstanceAssociationStatusInfo' {} Maybe Text
a -> InstanceAssociationStatusInfo
s {$sel:status:InstanceAssociationStatusInfo' :: Maybe Text
status = Maybe Text
a} :: InstanceAssociationStatusInfo)

-- | A URL for an S3 bucket where you want to store the results of this
-- request.
instanceAssociationStatusInfo_outputUrl :: Lens.Lens' InstanceAssociationStatusInfo (Prelude.Maybe InstanceAssociationOutputUrl)
instanceAssociationStatusInfo_outputUrl :: (Maybe InstanceAssociationOutputUrl
 -> f (Maybe InstanceAssociationOutputUrl))
-> InstanceAssociationStatusInfo -> f InstanceAssociationStatusInfo
instanceAssociationStatusInfo_outputUrl = (InstanceAssociationStatusInfo
 -> Maybe InstanceAssociationOutputUrl)
-> (InstanceAssociationStatusInfo
    -> Maybe InstanceAssociationOutputUrl
    -> InstanceAssociationStatusInfo)
-> Lens
     InstanceAssociationStatusInfo
     InstanceAssociationStatusInfo
     (Maybe InstanceAssociationOutputUrl)
     (Maybe InstanceAssociationOutputUrl)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InstanceAssociationStatusInfo' {Maybe InstanceAssociationOutputUrl
outputUrl :: Maybe InstanceAssociationOutputUrl
$sel:outputUrl:InstanceAssociationStatusInfo' :: InstanceAssociationStatusInfo -> Maybe InstanceAssociationOutputUrl
outputUrl} -> Maybe InstanceAssociationOutputUrl
outputUrl) (\s :: InstanceAssociationStatusInfo
s@InstanceAssociationStatusInfo' {} Maybe InstanceAssociationOutputUrl
a -> InstanceAssociationStatusInfo
s {$sel:outputUrl:InstanceAssociationStatusInfo' :: Maybe InstanceAssociationOutputUrl
outputUrl = Maybe InstanceAssociationOutputUrl
a} :: InstanceAssociationStatusInfo)

-- | Summary information about association execution.
instanceAssociationStatusInfo_executionSummary :: Lens.Lens' InstanceAssociationStatusInfo (Prelude.Maybe Prelude.Text)
instanceAssociationStatusInfo_executionSummary :: (Maybe Text -> f (Maybe Text))
-> InstanceAssociationStatusInfo -> f InstanceAssociationStatusInfo
instanceAssociationStatusInfo_executionSummary = (InstanceAssociationStatusInfo -> Maybe Text)
-> (InstanceAssociationStatusInfo
    -> Maybe Text -> InstanceAssociationStatusInfo)
-> Lens
     InstanceAssociationStatusInfo
     InstanceAssociationStatusInfo
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InstanceAssociationStatusInfo' {Maybe Text
executionSummary :: Maybe Text
$sel:executionSummary:InstanceAssociationStatusInfo' :: InstanceAssociationStatusInfo -> Maybe Text
executionSummary} -> Maybe Text
executionSummary) (\s :: InstanceAssociationStatusInfo
s@InstanceAssociationStatusInfo' {} Maybe Text
a -> InstanceAssociationStatusInfo
s {$sel:executionSummary:InstanceAssociationStatusInfo' :: Maybe Text
executionSummary = Maybe Text
a} :: InstanceAssociationStatusInfo)

-- | The name of the association.
instanceAssociationStatusInfo_name :: Lens.Lens' InstanceAssociationStatusInfo (Prelude.Maybe Prelude.Text)
instanceAssociationStatusInfo_name :: (Maybe Text -> f (Maybe Text))
-> InstanceAssociationStatusInfo -> f InstanceAssociationStatusInfo
instanceAssociationStatusInfo_name = (InstanceAssociationStatusInfo -> Maybe Text)
-> (InstanceAssociationStatusInfo
    -> Maybe Text -> InstanceAssociationStatusInfo)
-> Lens
     InstanceAssociationStatusInfo
     InstanceAssociationStatusInfo
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InstanceAssociationStatusInfo' {Maybe Text
name :: Maybe Text
$sel:name:InstanceAssociationStatusInfo' :: InstanceAssociationStatusInfo -> Maybe Text
name} -> Maybe Text
name) (\s :: InstanceAssociationStatusInfo
s@InstanceAssociationStatusInfo' {} Maybe Text
a -> InstanceAssociationStatusInfo
s {$sel:name:InstanceAssociationStatusInfo' :: Maybe Text
name = Maybe Text
a} :: InstanceAssociationStatusInfo)

-- | An error code returned by the request to create the association.
instanceAssociationStatusInfo_errorCode :: Lens.Lens' InstanceAssociationStatusInfo (Prelude.Maybe Prelude.Text)
instanceAssociationStatusInfo_errorCode :: (Maybe Text -> f (Maybe Text))
-> InstanceAssociationStatusInfo -> f InstanceAssociationStatusInfo
instanceAssociationStatusInfo_errorCode = (InstanceAssociationStatusInfo -> Maybe Text)
-> (InstanceAssociationStatusInfo
    -> Maybe Text -> InstanceAssociationStatusInfo)
-> Lens
     InstanceAssociationStatusInfo
     InstanceAssociationStatusInfo
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InstanceAssociationStatusInfo' {Maybe Text
errorCode :: Maybe Text
$sel:errorCode:InstanceAssociationStatusInfo' :: InstanceAssociationStatusInfo -> Maybe Text
errorCode} -> Maybe Text
errorCode) (\s :: InstanceAssociationStatusInfo
s@InstanceAssociationStatusInfo' {} Maybe Text
a -> InstanceAssociationStatusInfo
s {$sel:errorCode:InstanceAssociationStatusInfo' :: Maybe Text
errorCode = Maybe Text
a} :: InstanceAssociationStatusInfo)

-- | The association document versions.
instanceAssociationStatusInfo_documentVersion :: Lens.Lens' InstanceAssociationStatusInfo (Prelude.Maybe Prelude.Text)
instanceAssociationStatusInfo_documentVersion :: (Maybe Text -> f (Maybe Text))
-> InstanceAssociationStatusInfo -> f InstanceAssociationStatusInfo
instanceAssociationStatusInfo_documentVersion = (InstanceAssociationStatusInfo -> Maybe Text)
-> (InstanceAssociationStatusInfo
    -> Maybe Text -> InstanceAssociationStatusInfo)
-> Lens
     InstanceAssociationStatusInfo
     InstanceAssociationStatusInfo
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InstanceAssociationStatusInfo' {Maybe Text
documentVersion :: Maybe Text
$sel:documentVersion:InstanceAssociationStatusInfo' :: InstanceAssociationStatusInfo -> Maybe Text
documentVersion} -> Maybe Text
documentVersion) (\s :: InstanceAssociationStatusInfo
s@InstanceAssociationStatusInfo' {} Maybe Text
a -> InstanceAssociationStatusInfo
s {$sel:documentVersion:InstanceAssociationStatusInfo' :: Maybe Text
documentVersion = Maybe Text
a} :: InstanceAssociationStatusInfo)

-- | The version of the association applied to the instance.
instanceAssociationStatusInfo_associationVersion :: Lens.Lens' InstanceAssociationStatusInfo (Prelude.Maybe Prelude.Text)
instanceAssociationStatusInfo_associationVersion :: (Maybe Text -> f (Maybe Text))
-> InstanceAssociationStatusInfo -> f InstanceAssociationStatusInfo
instanceAssociationStatusInfo_associationVersion = (InstanceAssociationStatusInfo -> Maybe Text)
-> (InstanceAssociationStatusInfo
    -> Maybe Text -> InstanceAssociationStatusInfo)
-> Lens
     InstanceAssociationStatusInfo
     InstanceAssociationStatusInfo
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InstanceAssociationStatusInfo' {Maybe Text
associationVersion :: Maybe Text
$sel:associationVersion:InstanceAssociationStatusInfo' :: InstanceAssociationStatusInfo -> Maybe Text
associationVersion} -> Maybe Text
associationVersion) (\s :: InstanceAssociationStatusInfo
s@InstanceAssociationStatusInfo' {} Maybe Text
a -> InstanceAssociationStatusInfo
s {$sel:associationVersion:InstanceAssociationStatusInfo' :: Maybe Text
associationVersion = Maybe Text
a} :: InstanceAssociationStatusInfo)

-- | The date the instance association ran.
instanceAssociationStatusInfo_executionDate :: Lens.Lens' InstanceAssociationStatusInfo (Prelude.Maybe Prelude.UTCTime)
instanceAssociationStatusInfo_executionDate :: (Maybe UTCTime -> f (Maybe UTCTime))
-> InstanceAssociationStatusInfo -> f InstanceAssociationStatusInfo
instanceAssociationStatusInfo_executionDate = (InstanceAssociationStatusInfo -> Maybe POSIX)
-> (InstanceAssociationStatusInfo
    -> Maybe POSIX -> InstanceAssociationStatusInfo)
-> Lens
     InstanceAssociationStatusInfo
     InstanceAssociationStatusInfo
     (Maybe POSIX)
     (Maybe POSIX)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InstanceAssociationStatusInfo' {Maybe POSIX
executionDate :: Maybe POSIX
$sel:executionDate:InstanceAssociationStatusInfo' :: InstanceAssociationStatusInfo -> Maybe POSIX
executionDate} -> Maybe POSIX
executionDate) (\s :: InstanceAssociationStatusInfo
s@InstanceAssociationStatusInfo' {} Maybe POSIX
a -> InstanceAssociationStatusInfo
s {$sel:executionDate:InstanceAssociationStatusInfo' :: Maybe POSIX
executionDate = Maybe POSIX
a} :: InstanceAssociationStatusInfo) ((Maybe POSIX -> f (Maybe POSIX))
 -> InstanceAssociationStatusInfo
 -> f InstanceAssociationStatusInfo)
-> ((Maybe UTCTime -> f (Maybe UTCTime))
    -> Maybe POSIX -> f (Maybe POSIX))
-> (Maybe UTCTime -> f (Maybe UTCTime))
-> InstanceAssociationStatusInfo
-> f InstanceAssociationStatusInfo
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso POSIX POSIX UTCTime UTCTime
-> Iso (Maybe POSIX) (Maybe POSIX) (Maybe UTCTime) (Maybe UTCTime)
forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping AnIso POSIX POSIX UTCTime UTCTime
forall (a :: Format). Iso' (Time a) UTCTime
Core._Time

-- | The name of the association applied to the instance.
instanceAssociationStatusInfo_associationName :: Lens.Lens' InstanceAssociationStatusInfo (Prelude.Maybe Prelude.Text)
instanceAssociationStatusInfo_associationName :: (Maybe Text -> f (Maybe Text))
-> InstanceAssociationStatusInfo -> f InstanceAssociationStatusInfo
instanceAssociationStatusInfo_associationName = (InstanceAssociationStatusInfo -> Maybe Text)
-> (InstanceAssociationStatusInfo
    -> Maybe Text -> InstanceAssociationStatusInfo)
-> Lens
     InstanceAssociationStatusInfo
     InstanceAssociationStatusInfo
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InstanceAssociationStatusInfo' {Maybe Text
associationName :: Maybe Text
$sel:associationName:InstanceAssociationStatusInfo' :: InstanceAssociationStatusInfo -> Maybe Text
associationName} -> Maybe Text
associationName) (\s :: InstanceAssociationStatusInfo
s@InstanceAssociationStatusInfo' {} Maybe Text
a -> InstanceAssociationStatusInfo
s {$sel:associationName:InstanceAssociationStatusInfo' :: Maybe Text
associationName = Maybe Text
a} :: InstanceAssociationStatusInfo)

instance Core.FromJSON InstanceAssociationStatusInfo where
  parseJSON :: Value -> Parser InstanceAssociationStatusInfo
parseJSON =
    String
-> (Object -> Parser InstanceAssociationStatusInfo)
-> Value
-> Parser InstanceAssociationStatusInfo
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Core.withObject
      String
"InstanceAssociationStatusInfo"
      ( \Object
x ->
          Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe InstanceAssociationOutputUrl
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> Maybe Text
-> InstanceAssociationStatusInfo
InstanceAssociationStatusInfo'
            (Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe InstanceAssociationOutputUrl
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe POSIX
 -> Maybe Text
 -> InstanceAssociationStatusInfo)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe InstanceAssociationOutputUrl
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe Text
      -> InstanceAssociationStatusInfo)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"AssociationId")
            Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe InstanceAssociationOutputUrl
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe Text
   -> InstanceAssociationStatusInfo)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe InstanceAssociationOutputUrl
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe Text
      -> InstanceAssociationStatusInfo)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"InstanceId")
            Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe InstanceAssociationOutputUrl
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe Text
   -> InstanceAssociationStatusInfo)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe InstanceAssociationOutputUrl
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe Text
      -> InstanceAssociationStatusInfo)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"DetailedStatus")
            Parser
  (Maybe Text
   -> Maybe InstanceAssociationOutputUrl
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe Text
   -> InstanceAssociationStatusInfo)
-> Parser (Maybe Text)
-> Parser
     (Maybe InstanceAssociationOutputUrl
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe Text
      -> InstanceAssociationStatusInfo)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Status")
            Parser
  (Maybe InstanceAssociationOutputUrl
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe Text
   -> InstanceAssociationStatusInfo)
-> Parser (Maybe InstanceAssociationOutputUrl)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe Text
      -> InstanceAssociationStatusInfo)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe InstanceAssociationOutputUrl)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"OutputUrl")
            Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe Text
   -> InstanceAssociationStatusInfo)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe Text
      -> InstanceAssociationStatusInfo)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"ExecutionSummary")
            Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe Text
   -> InstanceAssociationStatusInfo)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe Text
      -> InstanceAssociationStatusInfo)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Name")
            Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe Text
   -> InstanceAssociationStatusInfo)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe Text
      -> InstanceAssociationStatusInfo)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"ErrorCode")
            Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe Text
   -> InstanceAssociationStatusInfo)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe POSIX -> Maybe Text -> InstanceAssociationStatusInfo)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"DocumentVersion")
            Parser
  (Maybe Text
   -> Maybe POSIX -> Maybe Text -> InstanceAssociationStatusInfo)
-> Parser (Maybe Text)
-> Parser
     (Maybe POSIX -> Maybe Text -> InstanceAssociationStatusInfo)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"AssociationVersion")
            Parser (Maybe POSIX -> Maybe Text -> InstanceAssociationStatusInfo)
-> Parser (Maybe POSIX)
-> Parser (Maybe Text -> InstanceAssociationStatusInfo)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe POSIX)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"ExecutionDate")
            Parser (Maybe Text -> InstanceAssociationStatusInfo)
-> Parser (Maybe Text) -> Parser InstanceAssociationStatusInfo
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"AssociationName")
      )

instance
  Prelude.Hashable
    InstanceAssociationStatusInfo

instance Prelude.NFData InstanceAssociationStatusInfo