{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE DuplicateRecordFields #-}
{-# LANGUAGE NamedFieldPuns #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE StrictData #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_GHC -fno-warn-unused-binds #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-unused-matches #-}
module Amazonka.OpsWorks.UpdateInstance
(
UpdateInstance (..),
newUpdateInstance,
updateInstance_agentVersion,
updateInstance_amiId,
updateInstance_architecture,
updateInstance_autoScalingType,
updateInstance_ebsOptimized,
updateInstance_hostname,
updateInstance_installUpdatesOnBoot,
updateInstance_instanceType,
updateInstance_layerIds,
updateInstance_os,
updateInstance_sshKeyName,
updateInstance_instanceId,
UpdateInstanceResponse (..),
newUpdateInstanceResponse,
)
where
import qualified Amazonka.Core as Core
import qualified Amazonka.Core.Lens.Internal as Lens
import qualified Amazonka.Data as Data
import Amazonka.OpsWorks.Types
import qualified Amazonka.Prelude as Prelude
import qualified Amazonka.Request as Request
import qualified Amazonka.Response as Response
data UpdateInstance = UpdateInstance'
{
UpdateInstance -> Maybe Text
agentVersion :: Prelude.Maybe Prelude.Text,
UpdateInstance -> Maybe Text
amiId :: Prelude.Maybe Prelude.Text,
UpdateInstance -> Maybe Architecture
architecture :: Prelude.Maybe Architecture,
UpdateInstance -> Maybe AutoScalingType
autoScalingType :: Prelude.Maybe AutoScalingType,
UpdateInstance -> Maybe Bool
ebsOptimized :: Prelude.Maybe Prelude.Bool,
UpdateInstance -> Maybe Text
hostname :: Prelude.Maybe Prelude.Text,
UpdateInstance -> Maybe Bool
installUpdatesOnBoot :: Prelude.Maybe Prelude.Bool,
UpdateInstance -> Maybe Text
instanceType :: Prelude.Maybe Prelude.Text,
UpdateInstance -> Maybe [Text]
layerIds :: Prelude.Maybe [Prelude.Text],
UpdateInstance -> Maybe Text
os :: Prelude.Maybe Prelude.Text,
UpdateInstance -> Maybe Text
sshKeyName :: Prelude.Maybe Prelude.Text,
UpdateInstance -> Text
instanceId :: Prelude.Text
}
deriving (UpdateInstance -> UpdateInstance -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: UpdateInstance -> UpdateInstance -> Bool
$c/= :: UpdateInstance -> UpdateInstance -> Bool
== :: UpdateInstance -> UpdateInstance -> Bool
$c== :: UpdateInstance -> UpdateInstance -> Bool
Prelude.Eq, ReadPrec [UpdateInstance]
ReadPrec UpdateInstance
Int -> ReadS UpdateInstance
ReadS [UpdateInstance]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [UpdateInstance]
$creadListPrec :: ReadPrec [UpdateInstance]
readPrec :: ReadPrec UpdateInstance
$creadPrec :: ReadPrec UpdateInstance
readList :: ReadS [UpdateInstance]
$creadList :: ReadS [UpdateInstance]
readsPrec :: Int -> ReadS UpdateInstance
$creadsPrec :: Int -> ReadS UpdateInstance
Prelude.Read, Int -> UpdateInstance -> ShowS
[UpdateInstance] -> ShowS
UpdateInstance -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [UpdateInstance] -> ShowS
$cshowList :: [UpdateInstance] -> ShowS
show :: UpdateInstance -> String
$cshow :: UpdateInstance -> String
showsPrec :: Int -> UpdateInstance -> ShowS
$cshowsPrec :: Int -> UpdateInstance -> ShowS
Prelude.Show, forall x. Rep UpdateInstance x -> UpdateInstance
forall x. UpdateInstance -> Rep UpdateInstance x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep UpdateInstance x -> UpdateInstance
$cfrom :: forall x. UpdateInstance -> Rep UpdateInstance x
Prelude.Generic)
newUpdateInstance ::
Prelude.Text ->
UpdateInstance
newUpdateInstance :: Text -> UpdateInstance
newUpdateInstance Text
pInstanceId_ =
UpdateInstance'
{ $sel:agentVersion:UpdateInstance' :: Maybe Text
agentVersion = forall a. Maybe a
Prelude.Nothing,
$sel:amiId:UpdateInstance' :: Maybe Text
amiId = forall a. Maybe a
Prelude.Nothing,
$sel:architecture:UpdateInstance' :: Maybe Architecture
architecture = forall a. Maybe a
Prelude.Nothing,
$sel:autoScalingType:UpdateInstance' :: Maybe AutoScalingType
autoScalingType = forall a. Maybe a
Prelude.Nothing,
$sel:ebsOptimized:UpdateInstance' :: Maybe Bool
ebsOptimized = forall a. Maybe a
Prelude.Nothing,
$sel:hostname:UpdateInstance' :: Maybe Text
hostname = forall a. Maybe a
Prelude.Nothing,
$sel:installUpdatesOnBoot:UpdateInstance' :: Maybe Bool
installUpdatesOnBoot = forall a. Maybe a
Prelude.Nothing,
$sel:instanceType:UpdateInstance' :: Maybe Text
instanceType = forall a. Maybe a
Prelude.Nothing,
$sel:layerIds:UpdateInstance' :: Maybe [Text]
layerIds = forall a. Maybe a
Prelude.Nothing,
$sel:os:UpdateInstance' :: Maybe Text
os = forall a. Maybe a
Prelude.Nothing,
$sel:sshKeyName:UpdateInstance' :: Maybe Text
sshKeyName = forall a. Maybe a
Prelude.Nothing,
$sel:instanceId:UpdateInstance' :: Text
instanceId = Text
pInstanceId_
}
updateInstance_agentVersion :: Lens.Lens' UpdateInstance (Prelude.Maybe Prelude.Text)
updateInstance_agentVersion :: Lens' UpdateInstance (Maybe Text)
updateInstance_agentVersion = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateInstance' {Maybe Text
agentVersion :: Maybe Text
$sel:agentVersion:UpdateInstance' :: UpdateInstance -> Maybe Text
agentVersion} -> Maybe Text
agentVersion) (\s :: UpdateInstance
s@UpdateInstance' {} Maybe Text
a -> UpdateInstance
s {$sel:agentVersion:UpdateInstance' :: Maybe Text
agentVersion = Maybe Text
a} :: UpdateInstance)
updateInstance_amiId :: Lens.Lens' UpdateInstance (Prelude.Maybe Prelude.Text)
updateInstance_amiId :: Lens' UpdateInstance (Maybe Text)
updateInstance_amiId = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateInstance' {Maybe Text
amiId :: Maybe Text
$sel:amiId:UpdateInstance' :: UpdateInstance -> Maybe Text
amiId} -> Maybe Text
amiId) (\s :: UpdateInstance
s@UpdateInstance' {} Maybe Text
a -> UpdateInstance
s {$sel:amiId:UpdateInstance' :: Maybe Text
amiId = Maybe Text
a} :: UpdateInstance)
updateInstance_architecture :: Lens.Lens' UpdateInstance (Prelude.Maybe Architecture)
updateInstance_architecture :: Lens' UpdateInstance (Maybe Architecture)
updateInstance_architecture = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateInstance' {Maybe Architecture
architecture :: Maybe Architecture
$sel:architecture:UpdateInstance' :: UpdateInstance -> Maybe Architecture
architecture} -> Maybe Architecture
architecture) (\s :: UpdateInstance
s@UpdateInstance' {} Maybe Architecture
a -> UpdateInstance
s {$sel:architecture:UpdateInstance' :: Maybe Architecture
architecture = Maybe Architecture
a} :: UpdateInstance)
updateInstance_autoScalingType :: Lens.Lens' UpdateInstance (Prelude.Maybe AutoScalingType)
updateInstance_autoScalingType :: Lens' UpdateInstance (Maybe AutoScalingType)
updateInstance_autoScalingType = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateInstance' {Maybe AutoScalingType
autoScalingType :: Maybe AutoScalingType
$sel:autoScalingType:UpdateInstance' :: UpdateInstance -> Maybe AutoScalingType
autoScalingType} -> Maybe AutoScalingType
autoScalingType) (\s :: UpdateInstance
s@UpdateInstance' {} Maybe AutoScalingType
a -> UpdateInstance
s {$sel:autoScalingType:UpdateInstance' :: Maybe AutoScalingType
autoScalingType = Maybe AutoScalingType
a} :: UpdateInstance)
updateInstance_ebsOptimized :: Lens.Lens' UpdateInstance (Prelude.Maybe Prelude.Bool)
updateInstance_ebsOptimized :: Lens' UpdateInstance (Maybe Bool)
updateInstance_ebsOptimized = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateInstance' {Maybe Bool
ebsOptimized :: Maybe Bool
$sel:ebsOptimized:UpdateInstance' :: UpdateInstance -> Maybe Bool
ebsOptimized} -> Maybe Bool
ebsOptimized) (\s :: UpdateInstance
s@UpdateInstance' {} Maybe Bool
a -> UpdateInstance
s {$sel:ebsOptimized:UpdateInstance' :: Maybe Bool
ebsOptimized = Maybe Bool
a} :: UpdateInstance)
updateInstance_hostname :: Lens.Lens' UpdateInstance (Prelude.Maybe Prelude.Text)
updateInstance_hostname :: Lens' UpdateInstance (Maybe Text)
updateInstance_hostname = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateInstance' {Maybe Text
hostname :: Maybe Text
$sel:hostname:UpdateInstance' :: UpdateInstance -> Maybe Text
hostname} -> Maybe Text
hostname) (\s :: UpdateInstance
s@UpdateInstance' {} Maybe Text
a -> UpdateInstance
s {$sel:hostname:UpdateInstance' :: Maybe Text
hostname = Maybe Text
a} :: UpdateInstance)
updateInstance_installUpdatesOnBoot :: Lens.Lens' UpdateInstance (Prelude.Maybe Prelude.Bool)
updateInstance_installUpdatesOnBoot :: Lens' UpdateInstance (Maybe Bool)
updateInstance_installUpdatesOnBoot = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateInstance' {Maybe Bool
installUpdatesOnBoot :: Maybe Bool
$sel:installUpdatesOnBoot:UpdateInstance' :: UpdateInstance -> Maybe Bool
installUpdatesOnBoot} -> Maybe Bool
installUpdatesOnBoot) (\s :: UpdateInstance
s@UpdateInstance' {} Maybe Bool
a -> UpdateInstance
s {$sel:installUpdatesOnBoot:UpdateInstance' :: Maybe Bool
installUpdatesOnBoot = Maybe Bool
a} :: UpdateInstance)
updateInstance_instanceType :: Lens.Lens' UpdateInstance (Prelude.Maybe Prelude.Text)
updateInstance_instanceType :: Lens' UpdateInstance (Maybe Text)
updateInstance_instanceType = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateInstance' {Maybe Text
instanceType :: Maybe Text
$sel:instanceType:UpdateInstance' :: UpdateInstance -> Maybe Text
instanceType} -> Maybe Text
instanceType) (\s :: UpdateInstance
s@UpdateInstance' {} Maybe Text
a -> UpdateInstance
s {$sel:instanceType:UpdateInstance' :: Maybe Text
instanceType = Maybe Text
a} :: UpdateInstance)
updateInstance_layerIds :: Lens.Lens' UpdateInstance (Prelude.Maybe [Prelude.Text])
updateInstance_layerIds :: Lens' UpdateInstance (Maybe [Text])
updateInstance_layerIds = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateInstance' {Maybe [Text]
layerIds :: Maybe [Text]
$sel:layerIds:UpdateInstance' :: UpdateInstance -> Maybe [Text]
layerIds} -> Maybe [Text]
layerIds) (\s :: UpdateInstance
s@UpdateInstance' {} Maybe [Text]
a -> UpdateInstance
s {$sel:layerIds:UpdateInstance' :: Maybe [Text]
layerIds = Maybe [Text]
a} :: UpdateInstance) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. 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 forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
updateInstance_os :: Lens.Lens' UpdateInstance (Prelude.Maybe Prelude.Text)
updateInstance_os :: Lens' UpdateInstance (Maybe Text)
updateInstance_os = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateInstance' {Maybe Text
os :: Maybe Text
$sel:os:UpdateInstance' :: UpdateInstance -> Maybe Text
os} -> Maybe Text
os) (\s :: UpdateInstance
s@UpdateInstance' {} Maybe Text
a -> UpdateInstance
s {$sel:os:UpdateInstance' :: Maybe Text
os = Maybe Text
a} :: UpdateInstance)
updateInstance_sshKeyName :: Lens.Lens' UpdateInstance (Prelude.Maybe Prelude.Text)
updateInstance_sshKeyName :: Lens' UpdateInstance (Maybe Text)
updateInstance_sshKeyName = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateInstance' {Maybe Text
sshKeyName :: Maybe Text
$sel:sshKeyName:UpdateInstance' :: UpdateInstance -> Maybe Text
sshKeyName} -> Maybe Text
sshKeyName) (\s :: UpdateInstance
s@UpdateInstance' {} Maybe Text
a -> UpdateInstance
s {$sel:sshKeyName:UpdateInstance' :: Maybe Text
sshKeyName = Maybe Text
a} :: UpdateInstance)
updateInstance_instanceId :: Lens.Lens' UpdateInstance Prelude.Text
updateInstance_instanceId :: Lens' UpdateInstance Text
updateInstance_instanceId = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateInstance' {Text
instanceId :: Text
$sel:instanceId:UpdateInstance' :: UpdateInstance -> Text
instanceId} -> Text
instanceId) (\s :: UpdateInstance
s@UpdateInstance' {} Text
a -> UpdateInstance
s {$sel:instanceId:UpdateInstance' :: Text
instanceId = Text
a} :: UpdateInstance)
instance Core.AWSRequest UpdateInstance where
type
AWSResponse UpdateInstance =
UpdateInstanceResponse
request :: (Service -> Service) -> UpdateInstance -> Request UpdateInstance
request Service -> Service
overrides =
forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.postJSON (Service -> Service
overrides Service
defaultService)
response :: forall (m :: * -> *).
MonadResource m =>
(ByteStringLazy -> IO ByteStringLazy)
-> Service
-> Proxy UpdateInstance
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse UpdateInstance)))
response =
forall (m :: * -> *) a.
MonadResource m =>
AWSResponse a
-> (ByteStringLazy -> IO ByteStringLazy)
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveNull UpdateInstanceResponse
UpdateInstanceResponse'
instance Prelude.Hashable UpdateInstance where
hashWithSalt :: Int -> UpdateInstance -> Int
hashWithSalt Int
_salt UpdateInstance' {Maybe Bool
Maybe [Text]
Maybe Text
Maybe Architecture
Maybe AutoScalingType
Text
instanceId :: Text
sshKeyName :: Maybe Text
os :: Maybe Text
layerIds :: Maybe [Text]
instanceType :: Maybe Text
installUpdatesOnBoot :: Maybe Bool
hostname :: Maybe Text
ebsOptimized :: Maybe Bool
autoScalingType :: Maybe AutoScalingType
architecture :: Maybe Architecture
amiId :: Maybe Text
agentVersion :: Maybe Text
$sel:instanceId:UpdateInstance' :: UpdateInstance -> Text
$sel:sshKeyName:UpdateInstance' :: UpdateInstance -> Maybe Text
$sel:os:UpdateInstance' :: UpdateInstance -> Maybe Text
$sel:layerIds:UpdateInstance' :: UpdateInstance -> Maybe [Text]
$sel:instanceType:UpdateInstance' :: UpdateInstance -> Maybe Text
$sel:installUpdatesOnBoot:UpdateInstance' :: UpdateInstance -> Maybe Bool
$sel:hostname:UpdateInstance' :: UpdateInstance -> Maybe Text
$sel:ebsOptimized:UpdateInstance' :: UpdateInstance -> Maybe Bool
$sel:autoScalingType:UpdateInstance' :: UpdateInstance -> Maybe AutoScalingType
$sel:architecture:UpdateInstance' :: UpdateInstance -> Maybe Architecture
$sel:amiId:UpdateInstance' :: UpdateInstance -> Maybe Text
$sel:agentVersion:UpdateInstance' :: UpdateInstance -> Maybe Text
..} =
Int
_salt
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
agentVersion
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
amiId
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Architecture
architecture
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe AutoScalingType
autoScalingType
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Bool
ebsOptimized
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
hostname
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Bool
installUpdatesOnBoot
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
instanceType
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe [Text]
layerIds
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
os
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
sshKeyName
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
instanceId
instance Prelude.NFData UpdateInstance where
rnf :: UpdateInstance -> ()
rnf UpdateInstance' {Maybe Bool
Maybe [Text]
Maybe Text
Maybe Architecture
Maybe AutoScalingType
Text
instanceId :: Text
sshKeyName :: Maybe Text
os :: Maybe Text
layerIds :: Maybe [Text]
instanceType :: Maybe Text
installUpdatesOnBoot :: Maybe Bool
hostname :: Maybe Text
ebsOptimized :: Maybe Bool
autoScalingType :: Maybe AutoScalingType
architecture :: Maybe Architecture
amiId :: Maybe Text
agentVersion :: Maybe Text
$sel:instanceId:UpdateInstance' :: UpdateInstance -> Text
$sel:sshKeyName:UpdateInstance' :: UpdateInstance -> Maybe Text
$sel:os:UpdateInstance' :: UpdateInstance -> Maybe Text
$sel:layerIds:UpdateInstance' :: UpdateInstance -> Maybe [Text]
$sel:instanceType:UpdateInstance' :: UpdateInstance -> Maybe Text
$sel:installUpdatesOnBoot:UpdateInstance' :: UpdateInstance -> Maybe Bool
$sel:hostname:UpdateInstance' :: UpdateInstance -> Maybe Text
$sel:ebsOptimized:UpdateInstance' :: UpdateInstance -> Maybe Bool
$sel:autoScalingType:UpdateInstance' :: UpdateInstance -> Maybe AutoScalingType
$sel:architecture:UpdateInstance' :: UpdateInstance -> Maybe Architecture
$sel:amiId:UpdateInstance' :: UpdateInstance -> Maybe Text
$sel:agentVersion:UpdateInstance' :: UpdateInstance -> Maybe Text
..} =
forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
agentVersion
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
amiId
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Architecture
architecture
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe AutoScalingType
autoScalingType
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Bool
ebsOptimized
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
hostname
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Bool
installUpdatesOnBoot
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
instanceType
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe [Text]
layerIds
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
os
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
sshKeyName
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
instanceId
instance Data.ToHeaders UpdateInstance where
toHeaders :: UpdateInstance -> [Header]
toHeaders =
forall a b. a -> b -> a
Prelude.const
( forall a. Monoid a => [a] -> a
Prelude.mconcat
[ HeaderName
"X-Amz-Target"
forall a. ToHeader a => HeaderName -> a -> [Header]
Data.=# ( ByteString
"OpsWorks_20130218.UpdateInstance" ::
Prelude.ByteString
),
HeaderName
"Content-Type"
forall a. ToHeader a => HeaderName -> a -> [Header]
Data.=# ( ByteString
"application/x-amz-json-1.1" ::
Prelude.ByteString
)
]
)
instance Data.ToJSON UpdateInstance where
toJSON :: UpdateInstance -> Value
toJSON UpdateInstance' {Maybe Bool
Maybe [Text]
Maybe Text
Maybe Architecture
Maybe AutoScalingType
Text
instanceId :: Text
sshKeyName :: Maybe Text
os :: Maybe Text
layerIds :: Maybe [Text]
instanceType :: Maybe Text
installUpdatesOnBoot :: Maybe Bool
hostname :: Maybe Text
ebsOptimized :: Maybe Bool
autoScalingType :: Maybe AutoScalingType
architecture :: Maybe Architecture
amiId :: Maybe Text
agentVersion :: Maybe Text
$sel:instanceId:UpdateInstance' :: UpdateInstance -> Text
$sel:sshKeyName:UpdateInstance' :: UpdateInstance -> Maybe Text
$sel:os:UpdateInstance' :: UpdateInstance -> Maybe Text
$sel:layerIds:UpdateInstance' :: UpdateInstance -> Maybe [Text]
$sel:instanceType:UpdateInstance' :: UpdateInstance -> Maybe Text
$sel:installUpdatesOnBoot:UpdateInstance' :: UpdateInstance -> Maybe Bool
$sel:hostname:UpdateInstance' :: UpdateInstance -> Maybe Text
$sel:ebsOptimized:UpdateInstance' :: UpdateInstance -> Maybe Bool
$sel:autoScalingType:UpdateInstance' :: UpdateInstance -> Maybe AutoScalingType
$sel:architecture:UpdateInstance' :: UpdateInstance -> Maybe Architecture
$sel:amiId:UpdateInstance' :: UpdateInstance -> Maybe Text
$sel:agentVersion:UpdateInstance' :: UpdateInstance -> Maybe Text
..} =
[Pair] -> Value
Data.object
( forall a. [Maybe a] -> [a]
Prelude.catMaybes
[ (Key
"AgentVersion" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
agentVersion,
(Key
"AmiId" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
amiId,
(Key
"Architecture" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Architecture
architecture,
(Key
"AutoScalingType" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe AutoScalingType
autoScalingType,
(Key
"EbsOptimized" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Bool
ebsOptimized,
(Key
"Hostname" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
hostname,
(Key
"InstallUpdatesOnBoot" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Bool
installUpdatesOnBoot,
(Key
"InstanceType" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
instanceType,
(Key
"LayerIds" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [Text]
layerIds,
(Key
"Os" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
os,
(Key
"SshKeyName" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..=) forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
sshKeyName,
forall a. a -> Maybe a
Prelude.Just (Key
"InstanceId" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..= Text
instanceId)
]
)
instance Data.ToPath UpdateInstance where
toPath :: UpdateInstance -> ByteString
toPath = forall a b. a -> b -> a
Prelude.const ByteString
"/"
instance Data.ToQuery UpdateInstance where
toQuery :: UpdateInstance -> QueryString
toQuery = forall a b. a -> b -> a
Prelude.const forall a. Monoid a => a
Prelude.mempty
data UpdateInstanceResponse = UpdateInstanceResponse'
{
}
deriving (UpdateInstanceResponse -> UpdateInstanceResponse -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: UpdateInstanceResponse -> UpdateInstanceResponse -> Bool
$c/= :: UpdateInstanceResponse -> UpdateInstanceResponse -> Bool
== :: UpdateInstanceResponse -> UpdateInstanceResponse -> Bool
$c== :: UpdateInstanceResponse -> UpdateInstanceResponse -> Bool
Prelude.Eq, ReadPrec [UpdateInstanceResponse]
ReadPrec UpdateInstanceResponse
Int -> ReadS UpdateInstanceResponse
ReadS [UpdateInstanceResponse]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [UpdateInstanceResponse]
$creadListPrec :: ReadPrec [UpdateInstanceResponse]
readPrec :: ReadPrec UpdateInstanceResponse
$creadPrec :: ReadPrec UpdateInstanceResponse
readList :: ReadS [UpdateInstanceResponse]
$creadList :: ReadS [UpdateInstanceResponse]
readsPrec :: Int -> ReadS UpdateInstanceResponse
$creadsPrec :: Int -> ReadS UpdateInstanceResponse
Prelude.Read, Int -> UpdateInstanceResponse -> ShowS
[UpdateInstanceResponse] -> ShowS
UpdateInstanceResponse -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [UpdateInstanceResponse] -> ShowS
$cshowList :: [UpdateInstanceResponse] -> ShowS
show :: UpdateInstanceResponse -> String
$cshow :: UpdateInstanceResponse -> String
showsPrec :: Int -> UpdateInstanceResponse -> ShowS
$cshowsPrec :: Int -> UpdateInstanceResponse -> ShowS
Prelude.Show, forall x. Rep UpdateInstanceResponse x -> UpdateInstanceResponse
forall x. UpdateInstanceResponse -> Rep UpdateInstanceResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep UpdateInstanceResponse x -> UpdateInstanceResponse
$cfrom :: forall x. UpdateInstanceResponse -> Rep UpdateInstanceResponse x
Prelude.Generic)
newUpdateInstanceResponse ::
UpdateInstanceResponse
newUpdateInstanceResponse :: UpdateInstanceResponse
newUpdateInstanceResponse = UpdateInstanceResponse
UpdateInstanceResponse'
instance Prelude.NFData UpdateInstanceResponse where
rnf :: UpdateInstanceResponse -> ()
rnf UpdateInstanceResponse
_ = ()