{-# 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.DataBrew.UpdateRecipeJob
(
UpdateRecipeJob (..),
newUpdateRecipeJob,
updateRecipeJob_dataCatalogOutputs,
updateRecipeJob_databaseOutputs,
updateRecipeJob_encryptionMode,
updateRecipeJob_outputs,
updateRecipeJob_logSubscription,
updateRecipeJob_maxRetries,
updateRecipeJob_encryptionKeyArn,
updateRecipeJob_maxCapacity,
updateRecipeJob_timeout,
updateRecipeJob_name,
updateRecipeJob_roleArn,
UpdateRecipeJobResponse (..),
newUpdateRecipeJobResponse,
updateRecipeJobResponse_httpStatus,
updateRecipeJobResponse_name,
)
where
import qualified Amazonka.Core as Core
import Amazonka.DataBrew.Types
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
import qualified Amazonka.Request as Request
import qualified Amazonka.Response as Response
data UpdateRecipeJob = UpdateRecipeJob'
{
UpdateRecipeJob -> Maybe (NonEmpty DataCatalogOutput)
dataCatalogOutputs :: Prelude.Maybe (Prelude.NonEmpty DataCatalogOutput),
UpdateRecipeJob -> Maybe (NonEmpty DatabaseOutput)
databaseOutputs :: Prelude.Maybe (Prelude.NonEmpty DatabaseOutput),
UpdateRecipeJob -> Maybe EncryptionMode
encryptionMode :: Prelude.Maybe EncryptionMode,
UpdateRecipeJob -> Maybe (NonEmpty Output)
outputs :: Prelude.Maybe (Prelude.NonEmpty Output),
UpdateRecipeJob -> Maybe LogSubscription
logSubscription :: Prelude.Maybe LogSubscription,
UpdateRecipeJob -> Maybe Natural
maxRetries :: Prelude.Maybe Prelude.Natural,
UpdateRecipeJob -> Maybe Text
encryptionKeyArn :: Prelude.Maybe Prelude.Text,
UpdateRecipeJob -> Maybe Int
maxCapacity :: Prelude.Maybe Prelude.Int,
UpdateRecipeJob -> Maybe Natural
timeout :: Prelude.Maybe Prelude.Natural,
UpdateRecipeJob -> Text
name :: Prelude.Text,
UpdateRecipeJob -> Text
roleArn :: Prelude.Text
}
deriving (UpdateRecipeJob -> UpdateRecipeJob -> Bool
(UpdateRecipeJob -> UpdateRecipeJob -> Bool)
-> (UpdateRecipeJob -> UpdateRecipeJob -> Bool)
-> Eq UpdateRecipeJob
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: UpdateRecipeJob -> UpdateRecipeJob -> Bool
$c/= :: UpdateRecipeJob -> UpdateRecipeJob -> Bool
== :: UpdateRecipeJob -> UpdateRecipeJob -> Bool
$c== :: UpdateRecipeJob -> UpdateRecipeJob -> Bool
Prelude.Eq, ReadPrec [UpdateRecipeJob]
ReadPrec UpdateRecipeJob
Int -> ReadS UpdateRecipeJob
ReadS [UpdateRecipeJob]
(Int -> ReadS UpdateRecipeJob)
-> ReadS [UpdateRecipeJob]
-> ReadPrec UpdateRecipeJob
-> ReadPrec [UpdateRecipeJob]
-> Read UpdateRecipeJob
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [UpdateRecipeJob]
$creadListPrec :: ReadPrec [UpdateRecipeJob]
readPrec :: ReadPrec UpdateRecipeJob
$creadPrec :: ReadPrec UpdateRecipeJob
readList :: ReadS [UpdateRecipeJob]
$creadList :: ReadS [UpdateRecipeJob]
readsPrec :: Int -> ReadS UpdateRecipeJob
$creadsPrec :: Int -> ReadS UpdateRecipeJob
Prelude.Read, Int -> UpdateRecipeJob -> ShowS
[UpdateRecipeJob] -> ShowS
UpdateRecipeJob -> String
(Int -> UpdateRecipeJob -> ShowS)
-> (UpdateRecipeJob -> String)
-> ([UpdateRecipeJob] -> ShowS)
-> Show UpdateRecipeJob
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [UpdateRecipeJob] -> ShowS
$cshowList :: [UpdateRecipeJob] -> ShowS
show :: UpdateRecipeJob -> String
$cshow :: UpdateRecipeJob -> String
showsPrec :: Int -> UpdateRecipeJob -> ShowS
$cshowsPrec :: Int -> UpdateRecipeJob -> ShowS
Prelude.Show, (forall x. UpdateRecipeJob -> Rep UpdateRecipeJob x)
-> (forall x. Rep UpdateRecipeJob x -> UpdateRecipeJob)
-> Generic UpdateRecipeJob
forall x. Rep UpdateRecipeJob x -> UpdateRecipeJob
forall x. UpdateRecipeJob -> Rep UpdateRecipeJob x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep UpdateRecipeJob x -> UpdateRecipeJob
$cfrom :: forall x. UpdateRecipeJob -> Rep UpdateRecipeJob x
Prelude.Generic)
newUpdateRecipeJob ::
Prelude.Text ->
Prelude.Text ->
UpdateRecipeJob
newUpdateRecipeJob :: Text -> Text -> UpdateRecipeJob
newUpdateRecipeJob Text
pName_ Text
pRoleArn_ =
UpdateRecipeJob' :: Maybe (NonEmpty DataCatalogOutput)
-> Maybe (NonEmpty DatabaseOutput)
-> Maybe EncryptionMode
-> Maybe (NonEmpty Output)
-> Maybe LogSubscription
-> Maybe Natural
-> Maybe Text
-> Maybe Int
-> Maybe Natural
-> Text
-> Text
-> UpdateRecipeJob
UpdateRecipeJob'
{ $sel:dataCatalogOutputs:UpdateRecipeJob' :: Maybe (NonEmpty DataCatalogOutput)
dataCatalogOutputs =
Maybe (NonEmpty DataCatalogOutput)
forall a. Maybe a
Prelude.Nothing,
$sel:databaseOutputs:UpdateRecipeJob' :: Maybe (NonEmpty DatabaseOutput)
databaseOutputs = Maybe (NonEmpty DatabaseOutput)
forall a. Maybe a
Prelude.Nothing,
$sel:encryptionMode:UpdateRecipeJob' :: Maybe EncryptionMode
encryptionMode = Maybe EncryptionMode
forall a. Maybe a
Prelude.Nothing,
$sel:outputs:UpdateRecipeJob' :: Maybe (NonEmpty Output)
outputs = Maybe (NonEmpty Output)
forall a. Maybe a
Prelude.Nothing,
$sel:logSubscription:UpdateRecipeJob' :: Maybe LogSubscription
logSubscription = Maybe LogSubscription
forall a. Maybe a
Prelude.Nothing,
$sel:maxRetries:UpdateRecipeJob' :: Maybe Natural
maxRetries = Maybe Natural
forall a. Maybe a
Prelude.Nothing,
$sel:encryptionKeyArn:UpdateRecipeJob' :: Maybe Text
encryptionKeyArn = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:maxCapacity:UpdateRecipeJob' :: Maybe Int
maxCapacity = Maybe Int
forall a. Maybe a
Prelude.Nothing,
$sel:timeout:UpdateRecipeJob' :: Maybe Natural
timeout = Maybe Natural
forall a. Maybe a
Prelude.Nothing,
$sel:name:UpdateRecipeJob' :: Text
name = Text
pName_,
$sel:roleArn:UpdateRecipeJob' :: Text
roleArn = Text
pRoleArn_
}
updateRecipeJob_dataCatalogOutputs :: Lens.Lens' UpdateRecipeJob (Prelude.Maybe (Prelude.NonEmpty DataCatalogOutput))
updateRecipeJob_dataCatalogOutputs :: (Maybe (NonEmpty DataCatalogOutput)
-> f (Maybe (NonEmpty DataCatalogOutput)))
-> UpdateRecipeJob -> f UpdateRecipeJob
updateRecipeJob_dataCatalogOutputs = (UpdateRecipeJob -> Maybe (NonEmpty DataCatalogOutput))
-> (UpdateRecipeJob
-> Maybe (NonEmpty DataCatalogOutput) -> UpdateRecipeJob)
-> Lens
UpdateRecipeJob
UpdateRecipeJob
(Maybe (NonEmpty DataCatalogOutput))
(Maybe (NonEmpty DataCatalogOutput))
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateRecipeJob' {Maybe (NonEmpty DataCatalogOutput)
dataCatalogOutputs :: Maybe (NonEmpty DataCatalogOutput)
$sel:dataCatalogOutputs:UpdateRecipeJob' :: UpdateRecipeJob -> Maybe (NonEmpty DataCatalogOutput)
dataCatalogOutputs} -> Maybe (NonEmpty DataCatalogOutput)
dataCatalogOutputs) (\s :: UpdateRecipeJob
s@UpdateRecipeJob' {} Maybe (NonEmpty DataCatalogOutput)
a -> UpdateRecipeJob
s {$sel:dataCatalogOutputs:UpdateRecipeJob' :: Maybe (NonEmpty DataCatalogOutput)
dataCatalogOutputs = Maybe (NonEmpty DataCatalogOutput)
a} :: UpdateRecipeJob) ((Maybe (NonEmpty DataCatalogOutput)
-> f (Maybe (NonEmpty DataCatalogOutput)))
-> UpdateRecipeJob -> f UpdateRecipeJob)
-> ((Maybe (NonEmpty DataCatalogOutput)
-> f (Maybe (NonEmpty DataCatalogOutput)))
-> Maybe (NonEmpty DataCatalogOutput)
-> f (Maybe (NonEmpty DataCatalogOutput)))
-> (Maybe (NonEmpty DataCatalogOutput)
-> f (Maybe (NonEmpty DataCatalogOutput)))
-> UpdateRecipeJob
-> f UpdateRecipeJob
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
(NonEmpty DataCatalogOutput)
(NonEmpty DataCatalogOutput)
(NonEmpty DataCatalogOutput)
(NonEmpty DataCatalogOutput)
-> Iso
(Maybe (NonEmpty DataCatalogOutput))
(Maybe (NonEmpty DataCatalogOutput))
(Maybe (NonEmpty DataCatalogOutput))
(Maybe (NonEmpty DataCatalogOutput))
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
(NonEmpty DataCatalogOutput)
(NonEmpty DataCatalogOutput)
(NonEmpty DataCatalogOutput)
(NonEmpty DataCatalogOutput)
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
updateRecipeJob_databaseOutputs :: Lens.Lens' UpdateRecipeJob (Prelude.Maybe (Prelude.NonEmpty DatabaseOutput))
updateRecipeJob_databaseOutputs :: (Maybe (NonEmpty DatabaseOutput)
-> f (Maybe (NonEmpty DatabaseOutput)))
-> UpdateRecipeJob -> f UpdateRecipeJob
updateRecipeJob_databaseOutputs = (UpdateRecipeJob -> Maybe (NonEmpty DatabaseOutput))
-> (UpdateRecipeJob
-> Maybe (NonEmpty DatabaseOutput) -> UpdateRecipeJob)
-> Lens
UpdateRecipeJob
UpdateRecipeJob
(Maybe (NonEmpty DatabaseOutput))
(Maybe (NonEmpty DatabaseOutput))
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateRecipeJob' {Maybe (NonEmpty DatabaseOutput)
databaseOutputs :: Maybe (NonEmpty DatabaseOutput)
$sel:databaseOutputs:UpdateRecipeJob' :: UpdateRecipeJob -> Maybe (NonEmpty DatabaseOutput)
databaseOutputs} -> Maybe (NonEmpty DatabaseOutput)
databaseOutputs) (\s :: UpdateRecipeJob
s@UpdateRecipeJob' {} Maybe (NonEmpty DatabaseOutput)
a -> UpdateRecipeJob
s {$sel:databaseOutputs:UpdateRecipeJob' :: Maybe (NonEmpty DatabaseOutput)
databaseOutputs = Maybe (NonEmpty DatabaseOutput)
a} :: UpdateRecipeJob) ((Maybe (NonEmpty DatabaseOutput)
-> f (Maybe (NonEmpty DatabaseOutput)))
-> UpdateRecipeJob -> f UpdateRecipeJob)
-> ((Maybe (NonEmpty DatabaseOutput)
-> f (Maybe (NonEmpty DatabaseOutput)))
-> Maybe (NonEmpty DatabaseOutput)
-> f (Maybe (NonEmpty DatabaseOutput)))
-> (Maybe (NonEmpty DatabaseOutput)
-> f (Maybe (NonEmpty DatabaseOutput)))
-> UpdateRecipeJob
-> f UpdateRecipeJob
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
(NonEmpty DatabaseOutput)
(NonEmpty DatabaseOutput)
(NonEmpty DatabaseOutput)
(NonEmpty DatabaseOutput)
-> Iso
(Maybe (NonEmpty DatabaseOutput))
(Maybe (NonEmpty DatabaseOutput))
(Maybe (NonEmpty DatabaseOutput))
(Maybe (NonEmpty DatabaseOutput))
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
(NonEmpty DatabaseOutput)
(NonEmpty DatabaseOutput)
(NonEmpty DatabaseOutput)
(NonEmpty DatabaseOutput)
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
updateRecipeJob_encryptionMode :: Lens.Lens' UpdateRecipeJob (Prelude.Maybe EncryptionMode)
updateRecipeJob_encryptionMode :: (Maybe EncryptionMode -> f (Maybe EncryptionMode))
-> UpdateRecipeJob -> f UpdateRecipeJob
updateRecipeJob_encryptionMode = (UpdateRecipeJob -> Maybe EncryptionMode)
-> (UpdateRecipeJob -> Maybe EncryptionMode -> UpdateRecipeJob)
-> Lens
UpdateRecipeJob
UpdateRecipeJob
(Maybe EncryptionMode)
(Maybe EncryptionMode)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateRecipeJob' {Maybe EncryptionMode
encryptionMode :: Maybe EncryptionMode
$sel:encryptionMode:UpdateRecipeJob' :: UpdateRecipeJob -> Maybe EncryptionMode
encryptionMode} -> Maybe EncryptionMode
encryptionMode) (\s :: UpdateRecipeJob
s@UpdateRecipeJob' {} Maybe EncryptionMode
a -> UpdateRecipeJob
s {$sel:encryptionMode:UpdateRecipeJob' :: Maybe EncryptionMode
encryptionMode = Maybe EncryptionMode
a} :: UpdateRecipeJob)
updateRecipeJob_outputs :: Lens.Lens' UpdateRecipeJob (Prelude.Maybe (Prelude.NonEmpty Output))
updateRecipeJob_outputs :: (Maybe (NonEmpty Output) -> f (Maybe (NonEmpty Output)))
-> UpdateRecipeJob -> f UpdateRecipeJob
updateRecipeJob_outputs = (UpdateRecipeJob -> Maybe (NonEmpty Output))
-> (UpdateRecipeJob -> Maybe (NonEmpty Output) -> UpdateRecipeJob)
-> Lens
UpdateRecipeJob
UpdateRecipeJob
(Maybe (NonEmpty Output))
(Maybe (NonEmpty Output))
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateRecipeJob' {Maybe (NonEmpty Output)
outputs :: Maybe (NonEmpty Output)
$sel:outputs:UpdateRecipeJob' :: UpdateRecipeJob -> Maybe (NonEmpty Output)
outputs} -> Maybe (NonEmpty Output)
outputs) (\s :: UpdateRecipeJob
s@UpdateRecipeJob' {} Maybe (NonEmpty Output)
a -> UpdateRecipeJob
s {$sel:outputs:UpdateRecipeJob' :: Maybe (NonEmpty Output)
outputs = Maybe (NonEmpty Output)
a} :: UpdateRecipeJob) ((Maybe (NonEmpty Output) -> f (Maybe (NonEmpty Output)))
-> UpdateRecipeJob -> f UpdateRecipeJob)
-> ((Maybe (NonEmpty Output) -> f (Maybe (NonEmpty Output)))
-> Maybe (NonEmpty Output) -> f (Maybe (NonEmpty Output)))
-> (Maybe (NonEmpty Output) -> f (Maybe (NonEmpty Output)))
-> UpdateRecipeJob
-> f UpdateRecipeJob
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
(NonEmpty Output)
(NonEmpty Output)
(NonEmpty Output)
(NonEmpty Output)
-> Iso
(Maybe (NonEmpty Output))
(Maybe (NonEmpty Output))
(Maybe (NonEmpty Output))
(Maybe (NonEmpty Output))
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
(NonEmpty Output)
(NonEmpty Output)
(NonEmpty Output)
(NonEmpty Output)
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
updateRecipeJob_logSubscription :: Lens.Lens' UpdateRecipeJob (Prelude.Maybe LogSubscription)
updateRecipeJob_logSubscription :: (Maybe LogSubscription -> f (Maybe LogSubscription))
-> UpdateRecipeJob -> f UpdateRecipeJob
updateRecipeJob_logSubscription = (UpdateRecipeJob -> Maybe LogSubscription)
-> (UpdateRecipeJob -> Maybe LogSubscription -> UpdateRecipeJob)
-> Lens
UpdateRecipeJob
UpdateRecipeJob
(Maybe LogSubscription)
(Maybe LogSubscription)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateRecipeJob' {Maybe LogSubscription
logSubscription :: Maybe LogSubscription
$sel:logSubscription:UpdateRecipeJob' :: UpdateRecipeJob -> Maybe LogSubscription
logSubscription} -> Maybe LogSubscription
logSubscription) (\s :: UpdateRecipeJob
s@UpdateRecipeJob' {} Maybe LogSubscription
a -> UpdateRecipeJob
s {$sel:logSubscription:UpdateRecipeJob' :: Maybe LogSubscription
logSubscription = Maybe LogSubscription
a} :: UpdateRecipeJob)
updateRecipeJob_maxRetries :: Lens.Lens' UpdateRecipeJob (Prelude.Maybe Prelude.Natural)
updateRecipeJob_maxRetries :: (Maybe Natural -> f (Maybe Natural))
-> UpdateRecipeJob -> f UpdateRecipeJob
updateRecipeJob_maxRetries = (UpdateRecipeJob -> Maybe Natural)
-> (UpdateRecipeJob -> Maybe Natural -> UpdateRecipeJob)
-> Lens
UpdateRecipeJob UpdateRecipeJob (Maybe Natural) (Maybe Natural)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateRecipeJob' {Maybe Natural
maxRetries :: Maybe Natural
$sel:maxRetries:UpdateRecipeJob' :: UpdateRecipeJob -> Maybe Natural
maxRetries} -> Maybe Natural
maxRetries) (\s :: UpdateRecipeJob
s@UpdateRecipeJob' {} Maybe Natural
a -> UpdateRecipeJob
s {$sel:maxRetries:UpdateRecipeJob' :: Maybe Natural
maxRetries = Maybe Natural
a} :: UpdateRecipeJob)
updateRecipeJob_encryptionKeyArn :: Lens.Lens' UpdateRecipeJob (Prelude.Maybe Prelude.Text)
updateRecipeJob_encryptionKeyArn :: (Maybe Text -> f (Maybe Text))
-> UpdateRecipeJob -> f UpdateRecipeJob
updateRecipeJob_encryptionKeyArn = (UpdateRecipeJob -> Maybe Text)
-> (UpdateRecipeJob -> Maybe Text -> UpdateRecipeJob)
-> Lens UpdateRecipeJob UpdateRecipeJob (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateRecipeJob' {Maybe Text
encryptionKeyArn :: Maybe Text
$sel:encryptionKeyArn:UpdateRecipeJob' :: UpdateRecipeJob -> Maybe Text
encryptionKeyArn} -> Maybe Text
encryptionKeyArn) (\s :: UpdateRecipeJob
s@UpdateRecipeJob' {} Maybe Text
a -> UpdateRecipeJob
s {$sel:encryptionKeyArn:UpdateRecipeJob' :: Maybe Text
encryptionKeyArn = Maybe Text
a} :: UpdateRecipeJob)
updateRecipeJob_maxCapacity :: Lens.Lens' UpdateRecipeJob (Prelude.Maybe Prelude.Int)
updateRecipeJob_maxCapacity :: (Maybe Int -> f (Maybe Int))
-> UpdateRecipeJob -> f UpdateRecipeJob
updateRecipeJob_maxCapacity = (UpdateRecipeJob -> Maybe Int)
-> (UpdateRecipeJob -> Maybe Int -> UpdateRecipeJob)
-> Lens UpdateRecipeJob UpdateRecipeJob (Maybe Int) (Maybe Int)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateRecipeJob' {Maybe Int
maxCapacity :: Maybe Int
$sel:maxCapacity:UpdateRecipeJob' :: UpdateRecipeJob -> Maybe Int
maxCapacity} -> Maybe Int
maxCapacity) (\s :: UpdateRecipeJob
s@UpdateRecipeJob' {} Maybe Int
a -> UpdateRecipeJob
s {$sel:maxCapacity:UpdateRecipeJob' :: Maybe Int
maxCapacity = Maybe Int
a} :: UpdateRecipeJob)
updateRecipeJob_timeout :: Lens.Lens' UpdateRecipeJob (Prelude.Maybe Prelude.Natural)
updateRecipeJob_timeout :: (Maybe Natural -> f (Maybe Natural))
-> UpdateRecipeJob -> f UpdateRecipeJob
updateRecipeJob_timeout = (UpdateRecipeJob -> Maybe Natural)
-> (UpdateRecipeJob -> Maybe Natural -> UpdateRecipeJob)
-> Lens
UpdateRecipeJob UpdateRecipeJob (Maybe Natural) (Maybe Natural)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateRecipeJob' {Maybe Natural
timeout :: Maybe Natural
$sel:timeout:UpdateRecipeJob' :: UpdateRecipeJob -> Maybe Natural
timeout} -> Maybe Natural
timeout) (\s :: UpdateRecipeJob
s@UpdateRecipeJob' {} Maybe Natural
a -> UpdateRecipeJob
s {$sel:timeout:UpdateRecipeJob' :: Maybe Natural
timeout = Maybe Natural
a} :: UpdateRecipeJob)
updateRecipeJob_name :: Lens.Lens' UpdateRecipeJob Prelude.Text
updateRecipeJob_name :: (Text -> f Text) -> UpdateRecipeJob -> f UpdateRecipeJob
updateRecipeJob_name = (UpdateRecipeJob -> Text)
-> (UpdateRecipeJob -> Text -> UpdateRecipeJob)
-> Lens UpdateRecipeJob UpdateRecipeJob Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateRecipeJob' {Text
name :: Text
$sel:name:UpdateRecipeJob' :: UpdateRecipeJob -> Text
name} -> Text
name) (\s :: UpdateRecipeJob
s@UpdateRecipeJob' {} Text
a -> UpdateRecipeJob
s {$sel:name:UpdateRecipeJob' :: Text
name = Text
a} :: UpdateRecipeJob)
updateRecipeJob_roleArn :: Lens.Lens' UpdateRecipeJob Prelude.Text
updateRecipeJob_roleArn :: (Text -> f Text) -> UpdateRecipeJob -> f UpdateRecipeJob
updateRecipeJob_roleArn = (UpdateRecipeJob -> Text)
-> (UpdateRecipeJob -> Text -> UpdateRecipeJob)
-> Lens UpdateRecipeJob UpdateRecipeJob Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateRecipeJob' {Text
roleArn :: Text
$sel:roleArn:UpdateRecipeJob' :: UpdateRecipeJob -> Text
roleArn} -> Text
roleArn) (\s :: UpdateRecipeJob
s@UpdateRecipeJob' {} Text
a -> UpdateRecipeJob
s {$sel:roleArn:UpdateRecipeJob' :: Text
roleArn = Text
a} :: UpdateRecipeJob)
instance Core.AWSRequest UpdateRecipeJob where
type
AWSResponse UpdateRecipeJob =
UpdateRecipeJobResponse
request :: UpdateRecipeJob -> Request UpdateRecipeJob
request = Service -> UpdateRecipeJob -> Request UpdateRecipeJob
forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.putJSON Service
defaultService
response :: Logger
-> Service
-> Proxy UpdateRecipeJob
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse UpdateRecipeJob)))
response =
(Int
-> ResponseHeaders
-> Object
-> Either String (AWSResponse UpdateRecipeJob))
-> Logger
-> Service
-> Proxy UpdateRecipeJob
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse UpdateRecipeJob)))
forall (m :: * -> *) a.
MonadResource m =>
(Int -> ResponseHeaders -> Object -> Either String (AWSResponse a))
-> Logger
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveJSON
( \Int
s ResponseHeaders
h Object
x ->
Int -> Text -> UpdateRecipeJobResponse
UpdateRecipeJobResponse'
(Int -> Text -> UpdateRecipeJobResponse)
-> Either String Int
-> Either String (Text -> UpdateRecipeJobResponse)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Int -> Either String Int
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure (Int -> Int
forall a. Enum a => a -> Int
Prelude.fromEnum Int
s))
Either String (Text -> UpdateRecipeJobResponse)
-> Either String Text -> Either String UpdateRecipeJobResponse
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String Text
forall a. FromJSON a => Object -> Text -> Either String a
Core..:> Text
"Name")
)
instance Prelude.Hashable UpdateRecipeJob
instance Prelude.NFData UpdateRecipeJob
instance Core.ToHeaders UpdateRecipeJob where
toHeaders :: UpdateRecipeJob -> ResponseHeaders
toHeaders =
ResponseHeaders -> UpdateRecipeJob -> ResponseHeaders
forall a b. a -> b -> a
Prelude.const
( [ResponseHeaders] -> ResponseHeaders
forall a. Monoid a => [a] -> a
Prelude.mconcat
[ HeaderName
"Content-Type"
HeaderName -> ByteString -> ResponseHeaders
forall a. ToHeader a => HeaderName -> a -> ResponseHeaders
Core.=# ( ByteString
"application/x-amz-json-1.1" ::
Prelude.ByteString
)
]
)
instance Core.ToJSON UpdateRecipeJob where
toJSON :: UpdateRecipeJob -> Value
toJSON UpdateRecipeJob' {Maybe Int
Maybe Natural
Maybe (NonEmpty Output)
Maybe (NonEmpty DatabaseOutput)
Maybe (NonEmpty DataCatalogOutput)
Maybe Text
Maybe EncryptionMode
Maybe LogSubscription
Text
roleArn :: Text
name :: Text
timeout :: Maybe Natural
maxCapacity :: Maybe Int
encryptionKeyArn :: Maybe Text
maxRetries :: Maybe Natural
logSubscription :: Maybe LogSubscription
outputs :: Maybe (NonEmpty Output)
encryptionMode :: Maybe EncryptionMode
databaseOutputs :: Maybe (NonEmpty DatabaseOutput)
dataCatalogOutputs :: Maybe (NonEmpty DataCatalogOutput)
$sel:roleArn:UpdateRecipeJob' :: UpdateRecipeJob -> Text
$sel:name:UpdateRecipeJob' :: UpdateRecipeJob -> Text
$sel:timeout:UpdateRecipeJob' :: UpdateRecipeJob -> Maybe Natural
$sel:maxCapacity:UpdateRecipeJob' :: UpdateRecipeJob -> Maybe Int
$sel:encryptionKeyArn:UpdateRecipeJob' :: UpdateRecipeJob -> Maybe Text
$sel:maxRetries:UpdateRecipeJob' :: UpdateRecipeJob -> Maybe Natural
$sel:logSubscription:UpdateRecipeJob' :: UpdateRecipeJob -> Maybe LogSubscription
$sel:outputs:UpdateRecipeJob' :: UpdateRecipeJob -> Maybe (NonEmpty Output)
$sel:encryptionMode:UpdateRecipeJob' :: UpdateRecipeJob -> Maybe EncryptionMode
$sel:databaseOutputs:UpdateRecipeJob' :: UpdateRecipeJob -> Maybe (NonEmpty DatabaseOutput)
$sel:dataCatalogOutputs:UpdateRecipeJob' :: UpdateRecipeJob -> Maybe (NonEmpty DataCatalogOutput)
..} =
[Pair] -> Value
Core.object
( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
[ (Text
"DataCatalogOutputs" Text -> NonEmpty DataCatalogOutput -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
(NonEmpty DataCatalogOutput -> Pair)
-> Maybe (NonEmpty DataCatalogOutput) -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (NonEmpty DataCatalogOutput)
dataCatalogOutputs,
(Text
"DatabaseOutputs" Text -> NonEmpty DatabaseOutput -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
(NonEmpty DatabaseOutput -> Pair)
-> Maybe (NonEmpty DatabaseOutput) -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (NonEmpty DatabaseOutput)
databaseOutputs,
(Text
"EncryptionMode" Text -> EncryptionMode -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
(EncryptionMode -> Pair) -> Maybe EncryptionMode -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe EncryptionMode
encryptionMode,
(Text
"Outputs" Text -> NonEmpty Output -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (NonEmpty Output -> Pair) -> Maybe (NonEmpty Output) -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (NonEmpty Output)
outputs,
(Text
"LogSubscription" Text -> LogSubscription -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
(LogSubscription -> Pair) -> Maybe LogSubscription -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe LogSubscription
logSubscription,
(Text
"MaxRetries" Text -> Natural -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Natural -> Pair) -> Maybe Natural -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Natural
maxRetries,
(Text
"EncryptionKeyArn" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
(Text -> Pair) -> Maybe Text -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
encryptionKeyArn,
(Text
"MaxCapacity" Text -> Int -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Int -> Pair) -> Maybe Int -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Int
maxCapacity,
(Text
"Timeout" Text -> Natural -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Natural -> Pair) -> Maybe Natural -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Natural
timeout,
Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"RoleArn" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
roleArn)
]
)
instance Core.ToPath UpdateRecipeJob where
toPath :: UpdateRecipeJob -> ByteString
toPath UpdateRecipeJob' {Maybe Int
Maybe Natural
Maybe (NonEmpty Output)
Maybe (NonEmpty DatabaseOutput)
Maybe (NonEmpty DataCatalogOutput)
Maybe Text
Maybe EncryptionMode
Maybe LogSubscription
Text
roleArn :: Text
name :: Text
timeout :: Maybe Natural
maxCapacity :: Maybe Int
encryptionKeyArn :: Maybe Text
maxRetries :: Maybe Natural
logSubscription :: Maybe LogSubscription
outputs :: Maybe (NonEmpty Output)
encryptionMode :: Maybe EncryptionMode
databaseOutputs :: Maybe (NonEmpty DatabaseOutput)
dataCatalogOutputs :: Maybe (NonEmpty DataCatalogOutput)
$sel:roleArn:UpdateRecipeJob' :: UpdateRecipeJob -> Text
$sel:name:UpdateRecipeJob' :: UpdateRecipeJob -> Text
$sel:timeout:UpdateRecipeJob' :: UpdateRecipeJob -> Maybe Natural
$sel:maxCapacity:UpdateRecipeJob' :: UpdateRecipeJob -> Maybe Int
$sel:encryptionKeyArn:UpdateRecipeJob' :: UpdateRecipeJob -> Maybe Text
$sel:maxRetries:UpdateRecipeJob' :: UpdateRecipeJob -> Maybe Natural
$sel:logSubscription:UpdateRecipeJob' :: UpdateRecipeJob -> Maybe LogSubscription
$sel:outputs:UpdateRecipeJob' :: UpdateRecipeJob -> Maybe (NonEmpty Output)
$sel:encryptionMode:UpdateRecipeJob' :: UpdateRecipeJob -> Maybe EncryptionMode
$sel:databaseOutputs:UpdateRecipeJob' :: UpdateRecipeJob -> Maybe (NonEmpty DatabaseOutput)
$sel:dataCatalogOutputs:UpdateRecipeJob' :: UpdateRecipeJob -> Maybe (NonEmpty DataCatalogOutput)
..} =
[ByteString] -> ByteString
forall a. Monoid a => [a] -> a
Prelude.mconcat [ByteString
"/recipeJobs/", Text -> ByteString
forall a. ToByteString a => a -> ByteString
Core.toBS Text
name]
instance Core.ToQuery UpdateRecipeJob where
toQuery :: UpdateRecipeJob -> QueryString
toQuery = QueryString -> UpdateRecipeJob -> QueryString
forall a b. a -> b -> a
Prelude.const QueryString
forall a. Monoid a => a
Prelude.mempty
data UpdateRecipeJobResponse = UpdateRecipeJobResponse'
{
UpdateRecipeJobResponse -> Int
httpStatus :: Prelude.Int,
UpdateRecipeJobResponse -> Text
name :: Prelude.Text
}
deriving (UpdateRecipeJobResponse -> UpdateRecipeJobResponse -> Bool
(UpdateRecipeJobResponse -> UpdateRecipeJobResponse -> Bool)
-> (UpdateRecipeJobResponse -> UpdateRecipeJobResponse -> Bool)
-> Eq UpdateRecipeJobResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: UpdateRecipeJobResponse -> UpdateRecipeJobResponse -> Bool
$c/= :: UpdateRecipeJobResponse -> UpdateRecipeJobResponse -> Bool
== :: UpdateRecipeJobResponse -> UpdateRecipeJobResponse -> Bool
$c== :: UpdateRecipeJobResponse -> UpdateRecipeJobResponse -> Bool
Prelude.Eq, ReadPrec [UpdateRecipeJobResponse]
ReadPrec UpdateRecipeJobResponse
Int -> ReadS UpdateRecipeJobResponse
ReadS [UpdateRecipeJobResponse]
(Int -> ReadS UpdateRecipeJobResponse)
-> ReadS [UpdateRecipeJobResponse]
-> ReadPrec UpdateRecipeJobResponse
-> ReadPrec [UpdateRecipeJobResponse]
-> Read UpdateRecipeJobResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [UpdateRecipeJobResponse]
$creadListPrec :: ReadPrec [UpdateRecipeJobResponse]
readPrec :: ReadPrec UpdateRecipeJobResponse
$creadPrec :: ReadPrec UpdateRecipeJobResponse
readList :: ReadS [UpdateRecipeJobResponse]
$creadList :: ReadS [UpdateRecipeJobResponse]
readsPrec :: Int -> ReadS UpdateRecipeJobResponse
$creadsPrec :: Int -> ReadS UpdateRecipeJobResponse
Prelude.Read, Int -> UpdateRecipeJobResponse -> ShowS
[UpdateRecipeJobResponse] -> ShowS
UpdateRecipeJobResponse -> String
(Int -> UpdateRecipeJobResponse -> ShowS)
-> (UpdateRecipeJobResponse -> String)
-> ([UpdateRecipeJobResponse] -> ShowS)
-> Show UpdateRecipeJobResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [UpdateRecipeJobResponse] -> ShowS
$cshowList :: [UpdateRecipeJobResponse] -> ShowS
show :: UpdateRecipeJobResponse -> String
$cshow :: UpdateRecipeJobResponse -> String
showsPrec :: Int -> UpdateRecipeJobResponse -> ShowS
$cshowsPrec :: Int -> UpdateRecipeJobResponse -> ShowS
Prelude.Show, (forall x.
UpdateRecipeJobResponse -> Rep UpdateRecipeJobResponse x)
-> (forall x.
Rep UpdateRecipeJobResponse x -> UpdateRecipeJobResponse)
-> Generic UpdateRecipeJobResponse
forall x. Rep UpdateRecipeJobResponse x -> UpdateRecipeJobResponse
forall x. UpdateRecipeJobResponse -> Rep UpdateRecipeJobResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep UpdateRecipeJobResponse x -> UpdateRecipeJobResponse
$cfrom :: forall x. UpdateRecipeJobResponse -> Rep UpdateRecipeJobResponse x
Prelude.Generic)
newUpdateRecipeJobResponse ::
Prelude.Int ->
Prelude.Text ->
UpdateRecipeJobResponse
newUpdateRecipeJobResponse :: Int -> Text -> UpdateRecipeJobResponse
newUpdateRecipeJobResponse Int
pHttpStatus_ Text
pName_ =
UpdateRecipeJobResponse' :: Int -> Text -> UpdateRecipeJobResponse
UpdateRecipeJobResponse'
{ $sel:httpStatus:UpdateRecipeJobResponse' :: Int
httpStatus = Int
pHttpStatus_,
$sel:name:UpdateRecipeJobResponse' :: Text
name = Text
pName_
}
updateRecipeJobResponse_httpStatus :: Lens.Lens' UpdateRecipeJobResponse Prelude.Int
updateRecipeJobResponse_httpStatus :: (Int -> f Int)
-> UpdateRecipeJobResponse -> f UpdateRecipeJobResponse
updateRecipeJobResponse_httpStatus = (UpdateRecipeJobResponse -> Int)
-> (UpdateRecipeJobResponse -> Int -> UpdateRecipeJobResponse)
-> Lens UpdateRecipeJobResponse UpdateRecipeJobResponse Int Int
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateRecipeJobResponse' {Int
httpStatus :: Int
$sel:httpStatus:UpdateRecipeJobResponse' :: UpdateRecipeJobResponse -> Int
httpStatus} -> Int
httpStatus) (\s :: UpdateRecipeJobResponse
s@UpdateRecipeJobResponse' {} Int
a -> UpdateRecipeJobResponse
s {$sel:httpStatus:UpdateRecipeJobResponse' :: Int
httpStatus = Int
a} :: UpdateRecipeJobResponse)
updateRecipeJobResponse_name :: Lens.Lens' UpdateRecipeJobResponse Prelude.Text
updateRecipeJobResponse_name :: (Text -> f Text)
-> UpdateRecipeJobResponse -> f UpdateRecipeJobResponse
updateRecipeJobResponse_name = (UpdateRecipeJobResponse -> Text)
-> (UpdateRecipeJobResponse -> Text -> UpdateRecipeJobResponse)
-> Lens UpdateRecipeJobResponse UpdateRecipeJobResponse Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpdateRecipeJobResponse' {Text
name :: Text
$sel:name:UpdateRecipeJobResponse' :: UpdateRecipeJobResponse -> Text
name} -> Text
name) (\s :: UpdateRecipeJobResponse
s@UpdateRecipeJobResponse' {} Text
a -> UpdateRecipeJobResponse
s {$sel:name:UpdateRecipeJobResponse' :: Text
name = Text
a} :: UpdateRecipeJobResponse)
instance Prelude.NFData UpdateRecipeJobResponse