{-# 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.Glue.CreateJob
(
CreateJob (..),
newCreateJob,
createJob_allocatedCapacity,
createJob_codeGenConfigurationNodes,
createJob_connections,
createJob_defaultArguments,
createJob_description,
createJob_executionClass,
createJob_executionProperty,
createJob_glueVersion,
createJob_logUri,
createJob_maxCapacity,
createJob_maxRetries,
createJob_nonOverridableArguments,
createJob_notificationProperty,
createJob_numberOfWorkers,
createJob_securityConfiguration,
createJob_sourceControlDetails,
createJob_tags,
createJob_timeout,
createJob_workerType,
createJob_name,
createJob_role,
createJob_command,
CreateJobResponse (..),
newCreateJobResponse,
createJobResponse_name,
createJobResponse_httpStatus,
)
where
import qualified Amazonka.Core as Core
import qualified Amazonka.Core.Lens.Internal as Lens
import qualified Amazonka.Data as Data
import Amazonka.Glue.Types
import qualified Amazonka.Prelude as Prelude
import qualified Amazonka.Request as Request
import qualified Amazonka.Response as Response
data CreateJob = CreateJob'
{
CreateJob -> Maybe Int
allocatedCapacity :: Prelude.Maybe Prelude.Int,
CreateJob
-> Maybe (Sensitive (HashMap Text CodeGenConfigurationNode))
codeGenConfigurationNodes :: Prelude.Maybe (Data.Sensitive (Prelude.HashMap Prelude.Text CodeGenConfigurationNode)),
CreateJob -> Maybe ConnectionsList
connections :: Prelude.Maybe ConnectionsList,
CreateJob -> Maybe (HashMap Text Text)
defaultArguments :: Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text),
CreateJob -> Maybe Text
description :: Prelude.Maybe Prelude.Text,
CreateJob -> Maybe ExecutionClass
executionClass :: Prelude.Maybe ExecutionClass,
CreateJob -> Maybe ExecutionProperty
executionProperty :: Prelude.Maybe ExecutionProperty,
CreateJob -> Maybe Text
glueVersion :: Prelude.Maybe Prelude.Text,
CreateJob -> Maybe Text
logUri :: Prelude.Maybe Prelude.Text,
CreateJob -> Maybe Double
maxCapacity :: Prelude.Maybe Prelude.Double,
CreateJob -> Maybe Int
maxRetries :: Prelude.Maybe Prelude.Int,
CreateJob -> Maybe (HashMap Text Text)
nonOverridableArguments :: Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text),
CreateJob -> Maybe NotificationProperty
notificationProperty :: Prelude.Maybe NotificationProperty,
CreateJob -> Maybe Int
numberOfWorkers :: Prelude.Maybe Prelude.Int,
CreateJob -> Maybe Text
securityConfiguration :: Prelude.Maybe Prelude.Text,
CreateJob -> Maybe SourceControlDetails
sourceControlDetails :: Prelude.Maybe SourceControlDetails,
CreateJob -> Maybe (HashMap Text Text)
tags :: Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text),
CreateJob -> Maybe Natural
timeout :: Prelude.Maybe Prelude.Natural,
CreateJob -> Maybe WorkerType
workerType :: Prelude.Maybe WorkerType,
CreateJob -> Text
name :: Prelude.Text,
CreateJob -> Text
role' :: Prelude.Text,
CreateJob -> JobCommand
command :: JobCommand
}
deriving (CreateJob -> CreateJob -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: CreateJob -> CreateJob -> Bool
$c/= :: CreateJob -> CreateJob -> Bool
== :: CreateJob -> CreateJob -> Bool
$c== :: CreateJob -> CreateJob -> Bool
Prelude.Eq, Int -> CreateJob -> ShowS
[CreateJob] -> ShowS
CreateJob -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [CreateJob] -> ShowS
$cshowList :: [CreateJob] -> ShowS
show :: CreateJob -> String
$cshow :: CreateJob -> String
showsPrec :: Int -> CreateJob -> ShowS
$cshowsPrec :: Int -> CreateJob -> ShowS
Prelude.Show, forall x. Rep CreateJob x -> CreateJob
forall x. CreateJob -> Rep CreateJob x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep CreateJob x -> CreateJob
$cfrom :: forall x. CreateJob -> Rep CreateJob x
Prelude.Generic)
newCreateJob ::
Prelude.Text ->
Prelude.Text ->
JobCommand ->
CreateJob
newCreateJob :: Text -> Text -> JobCommand -> CreateJob
newCreateJob Text
pName_ Text
pRole_ JobCommand
pCommand_ =
CreateJob'
{ $sel:allocatedCapacity:CreateJob' :: Maybe Int
allocatedCapacity = forall a. Maybe a
Prelude.Nothing,
$sel:codeGenConfigurationNodes:CreateJob' :: Maybe (Sensitive (HashMap Text CodeGenConfigurationNode))
codeGenConfigurationNodes = forall a. Maybe a
Prelude.Nothing,
$sel:connections:CreateJob' :: Maybe ConnectionsList
connections = forall a. Maybe a
Prelude.Nothing,
$sel:defaultArguments:CreateJob' :: Maybe (HashMap Text Text)
defaultArguments = forall a. Maybe a
Prelude.Nothing,
$sel:description:CreateJob' :: Maybe Text
description = forall a. Maybe a
Prelude.Nothing,
$sel:executionClass:CreateJob' :: Maybe ExecutionClass
executionClass = forall a. Maybe a
Prelude.Nothing,
$sel:executionProperty:CreateJob' :: Maybe ExecutionProperty
executionProperty = forall a. Maybe a
Prelude.Nothing,
$sel:glueVersion:CreateJob' :: Maybe Text
glueVersion = forall a. Maybe a
Prelude.Nothing,
$sel:logUri:CreateJob' :: Maybe Text
logUri = forall a. Maybe a
Prelude.Nothing,
$sel:maxCapacity:CreateJob' :: Maybe Double
maxCapacity = forall a. Maybe a
Prelude.Nothing,
$sel:maxRetries:CreateJob' :: Maybe Int
maxRetries = forall a. Maybe a
Prelude.Nothing,
$sel:nonOverridableArguments:CreateJob' :: Maybe (HashMap Text Text)
nonOverridableArguments = forall a. Maybe a
Prelude.Nothing,
$sel:notificationProperty:CreateJob' :: Maybe NotificationProperty
notificationProperty = forall a. Maybe a
Prelude.Nothing,
$sel:numberOfWorkers:CreateJob' :: Maybe Int
numberOfWorkers = forall a. Maybe a
Prelude.Nothing,
$sel:securityConfiguration:CreateJob' :: Maybe Text
securityConfiguration = forall a. Maybe a
Prelude.Nothing,
$sel:sourceControlDetails:CreateJob' :: Maybe SourceControlDetails
sourceControlDetails = forall a. Maybe a
Prelude.Nothing,
$sel:tags:CreateJob' :: Maybe (HashMap Text Text)
tags = forall a. Maybe a
Prelude.Nothing,
$sel:timeout:CreateJob' :: Maybe Natural
timeout = forall a. Maybe a
Prelude.Nothing,
$sel:workerType:CreateJob' :: Maybe WorkerType
workerType = forall a. Maybe a
Prelude.Nothing,
$sel:name:CreateJob' :: Text
name = Text
pName_,
$sel:role':CreateJob' :: Text
role' = Text
pRole_,
$sel:command:CreateJob' :: JobCommand
command = JobCommand
pCommand_
}
createJob_allocatedCapacity :: Lens.Lens' CreateJob (Prelude.Maybe Prelude.Int)
createJob_allocatedCapacity :: Lens' CreateJob (Maybe Int)
createJob_allocatedCapacity = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateJob' {Maybe Int
allocatedCapacity :: Maybe Int
$sel:allocatedCapacity:CreateJob' :: CreateJob -> Maybe Int
allocatedCapacity} -> Maybe Int
allocatedCapacity) (\s :: CreateJob
s@CreateJob' {} Maybe Int
a -> CreateJob
s {$sel:allocatedCapacity:CreateJob' :: Maybe Int
allocatedCapacity = Maybe Int
a} :: CreateJob)
createJob_codeGenConfigurationNodes :: Lens.Lens' CreateJob (Prelude.Maybe (Prelude.HashMap Prelude.Text CodeGenConfigurationNode))
createJob_codeGenConfigurationNodes :: Lens' CreateJob (Maybe (HashMap Text CodeGenConfigurationNode))
createJob_codeGenConfigurationNodes = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateJob' {Maybe (Sensitive (HashMap Text CodeGenConfigurationNode))
codeGenConfigurationNodes :: Maybe (Sensitive (HashMap Text CodeGenConfigurationNode))
$sel:codeGenConfigurationNodes:CreateJob' :: CreateJob
-> Maybe (Sensitive (HashMap Text CodeGenConfigurationNode))
codeGenConfigurationNodes} -> Maybe (Sensitive (HashMap Text CodeGenConfigurationNode))
codeGenConfigurationNodes) (\s :: CreateJob
s@CreateJob' {} Maybe (Sensitive (HashMap Text CodeGenConfigurationNode))
a -> CreateJob
s {$sel:codeGenConfigurationNodes:CreateJob' :: Maybe (Sensitive (HashMap Text CodeGenConfigurationNode))
codeGenConfigurationNodes = Maybe (Sensitive (HashMap Text CodeGenConfigurationNode))
a} :: CreateJob) 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 a. Iso' (Sensitive a) a
Data._Sensitive forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced)
createJob_connections :: Lens.Lens' CreateJob (Prelude.Maybe ConnectionsList)
createJob_connections :: Lens' CreateJob (Maybe ConnectionsList)
createJob_connections = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateJob' {Maybe ConnectionsList
connections :: Maybe ConnectionsList
$sel:connections:CreateJob' :: CreateJob -> Maybe ConnectionsList
connections} -> Maybe ConnectionsList
connections) (\s :: CreateJob
s@CreateJob' {} Maybe ConnectionsList
a -> CreateJob
s {$sel:connections:CreateJob' :: Maybe ConnectionsList
connections = Maybe ConnectionsList
a} :: CreateJob)
createJob_defaultArguments :: Lens.Lens' CreateJob (Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text))
createJob_defaultArguments :: Lens' CreateJob (Maybe (HashMap Text Text))
createJob_defaultArguments = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateJob' {Maybe (HashMap Text Text)
defaultArguments :: Maybe (HashMap Text Text)
$sel:defaultArguments:CreateJob' :: CreateJob -> Maybe (HashMap Text Text)
defaultArguments} -> Maybe (HashMap Text Text)
defaultArguments) (\s :: CreateJob
s@CreateJob' {} Maybe (HashMap Text Text)
a -> CreateJob
s {$sel:defaultArguments:CreateJob' :: Maybe (HashMap Text Text)
defaultArguments = Maybe (HashMap Text Text)
a} :: CreateJob) 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
createJob_description :: Lens.Lens' CreateJob (Prelude.Maybe Prelude.Text)
createJob_description :: Lens' CreateJob (Maybe Text)
createJob_description = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateJob' {Maybe Text
description :: Maybe Text
$sel:description:CreateJob' :: CreateJob -> Maybe Text
description} -> Maybe Text
description) (\s :: CreateJob
s@CreateJob' {} Maybe Text
a -> CreateJob
s {$sel:description:CreateJob' :: Maybe Text
description = Maybe Text
a} :: CreateJob)
createJob_executionClass :: Lens.Lens' CreateJob (Prelude.Maybe ExecutionClass)
createJob_executionClass :: Lens' CreateJob (Maybe ExecutionClass)
createJob_executionClass = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateJob' {Maybe ExecutionClass
executionClass :: Maybe ExecutionClass
$sel:executionClass:CreateJob' :: CreateJob -> Maybe ExecutionClass
executionClass} -> Maybe ExecutionClass
executionClass) (\s :: CreateJob
s@CreateJob' {} Maybe ExecutionClass
a -> CreateJob
s {$sel:executionClass:CreateJob' :: Maybe ExecutionClass
executionClass = Maybe ExecutionClass
a} :: CreateJob)
createJob_executionProperty :: Lens.Lens' CreateJob (Prelude.Maybe ExecutionProperty)
createJob_executionProperty :: Lens' CreateJob (Maybe ExecutionProperty)
createJob_executionProperty = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateJob' {Maybe ExecutionProperty
executionProperty :: Maybe ExecutionProperty
$sel:executionProperty:CreateJob' :: CreateJob -> Maybe ExecutionProperty
executionProperty} -> Maybe ExecutionProperty
executionProperty) (\s :: CreateJob
s@CreateJob' {} Maybe ExecutionProperty
a -> CreateJob
s {$sel:executionProperty:CreateJob' :: Maybe ExecutionProperty
executionProperty = Maybe ExecutionProperty
a} :: CreateJob)
createJob_glueVersion :: Lens.Lens' CreateJob (Prelude.Maybe Prelude.Text)
createJob_glueVersion :: Lens' CreateJob (Maybe Text)
createJob_glueVersion = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateJob' {Maybe Text
glueVersion :: Maybe Text
$sel:glueVersion:CreateJob' :: CreateJob -> Maybe Text
glueVersion} -> Maybe Text
glueVersion) (\s :: CreateJob
s@CreateJob' {} Maybe Text
a -> CreateJob
s {$sel:glueVersion:CreateJob' :: Maybe Text
glueVersion = Maybe Text
a} :: CreateJob)
createJob_logUri :: Lens.Lens' CreateJob (Prelude.Maybe Prelude.Text)
createJob_logUri :: Lens' CreateJob (Maybe Text)
createJob_logUri = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateJob' {Maybe Text
logUri :: Maybe Text
$sel:logUri:CreateJob' :: CreateJob -> Maybe Text
logUri} -> Maybe Text
logUri) (\s :: CreateJob
s@CreateJob' {} Maybe Text
a -> CreateJob
s {$sel:logUri:CreateJob' :: Maybe Text
logUri = Maybe Text
a} :: CreateJob)
createJob_maxCapacity :: Lens.Lens' CreateJob (Prelude.Maybe Prelude.Double)
createJob_maxCapacity :: Lens' CreateJob (Maybe Double)
createJob_maxCapacity = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateJob' {Maybe Double
maxCapacity :: Maybe Double
$sel:maxCapacity:CreateJob' :: CreateJob -> Maybe Double
maxCapacity} -> Maybe Double
maxCapacity) (\s :: CreateJob
s@CreateJob' {} Maybe Double
a -> CreateJob
s {$sel:maxCapacity:CreateJob' :: Maybe Double
maxCapacity = Maybe Double
a} :: CreateJob)
createJob_maxRetries :: Lens.Lens' CreateJob (Prelude.Maybe Prelude.Int)
createJob_maxRetries :: Lens' CreateJob (Maybe Int)
createJob_maxRetries = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateJob' {Maybe Int
maxRetries :: Maybe Int
$sel:maxRetries:CreateJob' :: CreateJob -> Maybe Int
maxRetries} -> Maybe Int
maxRetries) (\s :: CreateJob
s@CreateJob' {} Maybe Int
a -> CreateJob
s {$sel:maxRetries:CreateJob' :: Maybe Int
maxRetries = Maybe Int
a} :: CreateJob)
createJob_nonOverridableArguments :: Lens.Lens' CreateJob (Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text))
createJob_nonOverridableArguments :: Lens' CreateJob (Maybe (HashMap Text Text))
createJob_nonOverridableArguments = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateJob' {Maybe (HashMap Text Text)
nonOverridableArguments :: Maybe (HashMap Text Text)
$sel:nonOverridableArguments:CreateJob' :: CreateJob -> Maybe (HashMap Text Text)
nonOverridableArguments} -> Maybe (HashMap Text Text)
nonOverridableArguments) (\s :: CreateJob
s@CreateJob' {} Maybe (HashMap Text Text)
a -> CreateJob
s {$sel:nonOverridableArguments:CreateJob' :: Maybe (HashMap Text Text)
nonOverridableArguments = Maybe (HashMap Text Text)
a} :: CreateJob) 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
createJob_notificationProperty :: Lens.Lens' CreateJob (Prelude.Maybe NotificationProperty)
createJob_notificationProperty :: Lens' CreateJob (Maybe NotificationProperty)
createJob_notificationProperty = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateJob' {Maybe NotificationProperty
notificationProperty :: Maybe NotificationProperty
$sel:notificationProperty:CreateJob' :: CreateJob -> Maybe NotificationProperty
notificationProperty} -> Maybe NotificationProperty
notificationProperty) (\s :: CreateJob
s@CreateJob' {} Maybe NotificationProperty
a -> CreateJob
s {$sel:notificationProperty:CreateJob' :: Maybe NotificationProperty
notificationProperty = Maybe NotificationProperty
a} :: CreateJob)
createJob_numberOfWorkers :: Lens.Lens' CreateJob (Prelude.Maybe Prelude.Int)
createJob_numberOfWorkers :: Lens' CreateJob (Maybe Int)
createJob_numberOfWorkers = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateJob' {Maybe Int
numberOfWorkers :: Maybe Int
$sel:numberOfWorkers:CreateJob' :: CreateJob -> Maybe Int
numberOfWorkers} -> Maybe Int
numberOfWorkers) (\s :: CreateJob
s@CreateJob' {} Maybe Int
a -> CreateJob
s {$sel:numberOfWorkers:CreateJob' :: Maybe Int
numberOfWorkers = Maybe Int
a} :: CreateJob)
createJob_securityConfiguration :: Lens.Lens' CreateJob (Prelude.Maybe Prelude.Text)
createJob_securityConfiguration :: Lens' CreateJob (Maybe Text)
createJob_securityConfiguration = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateJob' {Maybe Text
securityConfiguration :: Maybe Text
$sel:securityConfiguration:CreateJob' :: CreateJob -> Maybe Text
securityConfiguration} -> Maybe Text
securityConfiguration) (\s :: CreateJob
s@CreateJob' {} Maybe Text
a -> CreateJob
s {$sel:securityConfiguration:CreateJob' :: Maybe Text
securityConfiguration = Maybe Text
a} :: CreateJob)
createJob_sourceControlDetails :: Lens.Lens' CreateJob (Prelude.Maybe SourceControlDetails)
createJob_sourceControlDetails :: Lens' CreateJob (Maybe SourceControlDetails)
createJob_sourceControlDetails = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateJob' {Maybe SourceControlDetails
sourceControlDetails :: Maybe SourceControlDetails
$sel:sourceControlDetails:CreateJob' :: CreateJob -> Maybe SourceControlDetails
sourceControlDetails} -> Maybe SourceControlDetails
sourceControlDetails) (\s :: CreateJob
s@CreateJob' {} Maybe SourceControlDetails
a -> CreateJob
s {$sel:sourceControlDetails:CreateJob' :: Maybe SourceControlDetails
sourceControlDetails = Maybe SourceControlDetails
a} :: CreateJob)
createJob_tags :: Lens.Lens' CreateJob (Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text))
createJob_tags :: Lens' CreateJob (Maybe (HashMap Text Text))
createJob_tags = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateJob' {Maybe (HashMap Text Text)
tags :: Maybe (HashMap Text Text)
$sel:tags:CreateJob' :: CreateJob -> Maybe (HashMap Text Text)
tags} -> Maybe (HashMap Text Text)
tags) (\s :: CreateJob
s@CreateJob' {} Maybe (HashMap Text Text)
a -> CreateJob
s {$sel:tags:CreateJob' :: Maybe (HashMap Text Text)
tags = Maybe (HashMap Text Text)
a} :: CreateJob) 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
createJob_timeout :: Lens.Lens' CreateJob (Prelude.Maybe Prelude.Natural)
createJob_timeout :: Lens' CreateJob (Maybe Natural)
createJob_timeout = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateJob' {Maybe Natural
timeout :: Maybe Natural
$sel:timeout:CreateJob' :: CreateJob -> Maybe Natural
timeout} -> Maybe Natural
timeout) (\s :: CreateJob
s@CreateJob' {} Maybe Natural
a -> CreateJob
s {$sel:timeout:CreateJob' :: Maybe Natural
timeout = Maybe Natural
a} :: CreateJob)
createJob_workerType :: Lens.Lens' CreateJob (Prelude.Maybe WorkerType)
createJob_workerType :: Lens' CreateJob (Maybe WorkerType)
createJob_workerType = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateJob' {Maybe WorkerType
workerType :: Maybe WorkerType
$sel:workerType:CreateJob' :: CreateJob -> Maybe WorkerType
workerType} -> Maybe WorkerType
workerType) (\s :: CreateJob
s@CreateJob' {} Maybe WorkerType
a -> CreateJob
s {$sel:workerType:CreateJob' :: Maybe WorkerType
workerType = Maybe WorkerType
a} :: CreateJob)
createJob_name :: Lens.Lens' CreateJob Prelude.Text
createJob_name :: Lens' CreateJob Text
createJob_name = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateJob' {Text
name :: Text
$sel:name:CreateJob' :: CreateJob -> Text
name} -> Text
name) (\s :: CreateJob
s@CreateJob' {} Text
a -> CreateJob
s {$sel:name:CreateJob' :: Text
name = Text
a} :: CreateJob)
createJob_role :: Lens.Lens' CreateJob Prelude.Text
createJob_role :: Lens' CreateJob Text
createJob_role = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateJob' {Text
role' :: Text
$sel:role':CreateJob' :: CreateJob -> Text
role'} -> Text
role') (\s :: CreateJob
s@CreateJob' {} Text
a -> CreateJob
s {$sel:role':CreateJob' :: Text
role' = Text
a} :: CreateJob)
createJob_command :: Lens.Lens' CreateJob JobCommand
createJob_command :: Lens' CreateJob JobCommand
createJob_command = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateJob' {JobCommand
command :: JobCommand
$sel:command:CreateJob' :: CreateJob -> JobCommand
command} -> JobCommand
command) (\s :: CreateJob
s@CreateJob' {} JobCommand
a -> CreateJob
s {$sel:command:CreateJob' :: JobCommand
command = JobCommand
a} :: CreateJob)
instance Core.AWSRequest CreateJob where
type AWSResponse CreateJob = CreateJobResponse
request :: (Service -> Service) -> CreateJob -> Request CreateJob
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 CreateJob
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse CreateJob)))
response =
forall (m :: * -> *) a.
MonadResource m =>
(Int -> ResponseHeaders -> Object -> Either String (AWSResponse a))
-> (ByteStringLazy -> IO ByteStringLazy)
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveJSON
( \Int
s ResponseHeaders
h Object
x ->
Maybe Text -> Int -> CreateJobResponse
CreateJobResponse'
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x forall a. FromJSON a => Object -> Key -> Either String (Maybe a)
Data..?> Key
"Name")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure (forall a. Enum a => a -> Int
Prelude.fromEnum Int
s))
)
instance Prelude.Hashable CreateJob where
hashWithSalt :: Int -> CreateJob -> Int
hashWithSalt Int
_salt CreateJob' {Maybe Double
Maybe Int
Maybe Natural
Maybe Text
Maybe (HashMap Text Text)
Maybe (Sensitive (HashMap Text CodeGenConfigurationNode))
Maybe ConnectionsList
Maybe ExecutionClass
Maybe ExecutionProperty
Maybe NotificationProperty
Maybe SourceControlDetails
Maybe WorkerType
Text
JobCommand
command :: JobCommand
role' :: Text
name :: Text
workerType :: Maybe WorkerType
timeout :: Maybe Natural
tags :: Maybe (HashMap Text Text)
sourceControlDetails :: Maybe SourceControlDetails
securityConfiguration :: Maybe Text
numberOfWorkers :: Maybe Int
notificationProperty :: Maybe NotificationProperty
nonOverridableArguments :: Maybe (HashMap Text Text)
maxRetries :: Maybe Int
maxCapacity :: Maybe Double
logUri :: Maybe Text
glueVersion :: Maybe Text
executionProperty :: Maybe ExecutionProperty
executionClass :: Maybe ExecutionClass
description :: Maybe Text
defaultArguments :: Maybe (HashMap Text Text)
connections :: Maybe ConnectionsList
codeGenConfigurationNodes :: Maybe (Sensitive (HashMap Text CodeGenConfigurationNode))
allocatedCapacity :: Maybe Int
$sel:command:CreateJob' :: CreateJob -> JobCommand
$sel:role':CreateJob' :: CreateJob -> Text
$sel:name:CreateJob' :: CreateJob -> Text
$sel:workerType:CreateJob' :: CreateJob -> Maybe WorkerType
$sel:timeout:CreateJob' :: CreateJob -> Maybe Natural
$sel:tags:CreateJob' :: CreateJob -> Maybe (HashMap Text Text)
$sel:sourceControlDetails:CreateJob' :: CreateJob -> Maybe SourceControlDetails
$sel:securityConfiguration:CreateJob' :: CreateJob -> Maybe Text
$sel:numberOfWorkers:CreateJob' :: CreateJob -> Maybe Int
$sel:notificationProperty:CreateJob' :: CreateJob -> Maybe NotificationProperty
$sel:nonOverridableArguments:CreateJob' :: CreateJob -> Maybe (HashMap Text Text)
$sel:maxRetries:CreateJob' :: CreateJob -> Maybe Int
$sel:maxCapacity:CreateJob' :: CreateJob -> Maybe Double
$sel:logUri:CreateJob' :: CreateJob -> Maybe Text
$sel:glueVersion:CreateJob' :: CreateJob -> Maybe Text
$sel:executionProperty:CreateJob' :: CreateJob -> Maybe ExecutionProperty
$sel:executionClass:CreateJob' :: CreateJob -> Maybe ExecutionClass
$sel:description:CreateJob' :: CreateJob -> Maybe Text
$sel:defaultArguments:CreateJob' :: CreateJob -> Maybe (HashMap Text Text)
$sel:connections:CreateJob' :: CreateJob -> Maybe ConnectionsList
$sel:codeGenConfigurationNodes:CreateJob' :: CreateJob
-> Maybe (Sensitive (HashMap Text CodeGenConfigurationNode))
$sel:allocatedCapacity:CreateJob' :: CreateJob -> Maybe Int
..} =
Int
_salt
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Int
allocatedCapacity
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe (Sensitive (HashMap Text CodeGenConfigurationNode))
codeGenConfigurationNodes
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe ConnectionsList
connections
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe (HashMap Text Text)
defaultArguments
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
description
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe ExecutionClass
executionClass
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe ExecutionProperty
executionProperty
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
glueVersion
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
logUri
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Double
maxCapacity
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Int
maxRetries
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe (HashMap Text Text)
nonOverridableArguments
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe NotificationProperty
notificationProperty
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Int
numberOfWorkers
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
securityConfiguration
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe SourceControlDetails
sourceControlDetails
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe (HashMap Text Text)
tags
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Natural
timeout
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe WorkerType
workerType
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
name
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
role'
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` JobCommand
command
instance Prelude.NFData CreateJob where
rnf :: CreateJob -> ()
rnf CreateJob' {Maybe Double
Maybe Int
Maybe Natural
Maybe Text
Maybe (HashMap Text Text)
Maybe (Sensitive (HashMap Text CodeGenConfigurationNode))
Maybe ConnectionsList
Maybe ExecutionClass
Maybe ExecutionProperty
Maybe NotificationProperty
Maybe SourceControlDetails
Maybe WorkerType
Text
JobCommand
command :: JobCommand
role' :: Text
name :: Text
workerType :: Maybe WorkerType
timeout :: Maybe Natural
tags :: Maybe (HashMap Text Text)
sourceControlDetails :: Maybe SourceControlDetails
securityConfiguration :: Maybe Text
numberOfWorkers :: Maybe Int
notificationProperty :: Maybe NotificationProperty
nonOverridableArguments :: Maybe (HashMap Text Text)
maxRetries :: Maybe Int
maxCapacity :: Maybe Double
logUri :: Maybe Text
glueVersion :: Maybe Text
executionProperty :: Maybe ExecutionProperty
executionClass :: Maybe ExecutionClass
description :: Maybe Text
defaultArguments :: Maybe (HashMap Text Text)
connections :: Maybe ConnectionsList
codeGenConfigurationNodes :: Maybe (Sensitive (HashMap Text CodeGenConfigurationNode))
allocatedCapacity :: Maybe Int
$sel:command:CreateJob' :: CreateJob -> JobCommand
$sel:role':CreateJob' :: CreateJob -> Text
$sel:name:CreateJob' :: CreateJob -> Text
$sel:workerType:CreateJob' :: CreateJob -> Maybe WorkerType
$sel:timeout:CreateJob' :: CreateJob -> Maybe Natural
$sel:tags:CreateJob' :: CreateJob -> Maybe (HashMap Text Text)
$sel:sourceControlDetails:CreateJob' :: CreateJob -> Maybe SourceControlDetails
$sel:securityConfiguration:CreateJob' :: CreateJob -> Maybe Text
$sel:numberOfWorkers:CreateJob' :: CreateJob -> Maybe Int
$sel:notificationProperty:CreateJob' :: CreateJob -> Maybe NotificationProperty
$sel:nonOverridableArguments:CreateJob' :: CreateJob -> Maybe (HashMap Text Text)
$sel:maxRetries:CreateJob' :: CreateJob -> Maybe Int
$sel:maxCapacity:CreateJob' :: CreateJob -> Maybe Double
$sel:logUri:CreateJob' :: CreateJob -> Maybe Text
$sel:glueVersion:CreateJob' :: CreateJob -> Maybe Text
$sel:executionProperty:CreateJob' :: CreateJob -> Maybe ExecutionProperty
$sel:executionClass:CreateJob' :: CreateJob -> Maybe ExecutionClass
$sel:description:CreateJob' :: CreateJob -> Maybe Text
$sel:defaultArguments:CreateJob' :: CreateJob -> Maybe (HashMap Text Text)
$sel:connections:CreateJob' :: CreateJob -> Maybe ConnectionsList
$sel:codeGenConfigurationNodes:CreateJob' :: CreateJob
-> Maybe (Sensitive (HashMap Text CodeGenConfigurationNode))
$sel:allocatedCapacity:CreateJob' :: CreateJob -> Maybe Int
..} =
forall a. NFData a => a -> ()
Prelude.rnf Maybe Int
allocatedCapacity
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe (Sensitive (HashMap Text CodeGenConfigurationNode))
codeGenConfigurationNodes
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe ConnectionsList
connections
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe (HashMap Text Text)
defaultArguments
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
description
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe ExecutionClass
executionClass
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe ExecutionProperty
executionProperty
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
glueVersion
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
logUri
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Double
maxCapacity
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Int
maxRetries
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe (HashMap Text Text)
nonOverridableArguments
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe NotificationProperty
notificationProperty
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Int
numberOfWorkers
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
securityConfiguration
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe SourceControlDetails
sourceControlDetails
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe (HashMap Text Text)
tags
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Natural
timeout
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe WorkerType
workerType
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
name
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
role'
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf JobCommand
command
instance Data.ToHeaders CreateJob where
toHeaders :: CreateJob -> ResponseHeaders
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 -> ResponseHeaders
Data.=# (ByteString
"AWSGlue.CreateJob" :: Prelude.ByteString),
HeaderName
"Content-Type"
forall a. ToHeader a => HeaderName -> a -> ResponseHeaders
Data.=# ( ByteString
"application/x-amz-json-1.1" ::
Prelude.ByteString
)
]
)
instance Data.ToJSON CreateJob where
toJSON :: CreateJob -> Value
toJSON CreateJob' {Maybe Double
Maybe Int
Maybe Natural
Maybe Text
Maybe (HashMap Text Text)
Maybe (Sensitive (HashMap Text CodeGenConfigurationNode))
Maybe ConnectionsList
Maybe ExecutionClass
Maybe ExecutionProperty
Maybe NotificationProperty
Maybe SourceControlDetails
Maybe WorkerType
Text
JobCommand
command :: JobCommand
role' :: Text
name :: Text
workerType :: Maybe WorkerType
timeout :: Maybe Natural
tags :: Maybe (HashMap Text Text)
sourceControlDetails :: Maybe SourceControlDetails
securityConfiguration :: Maybe Text
numberOfWorkers :: Maybe Int
notificationProperty :: Maybe NotificationProperty
nonOverridableArguments :: Maybe (HashMap Text Text)
maxRetries :: Maybe Int
maxCapacity :: Maybe Double
logUri :: Maybe Text
glueVersion :: Maybe Text
executionProperty :: Maybe ExecutionProperty
executionClass :: Maybe ExecutionClass
description :: Maybe Text
defaultArguments :: Maybe (HashMap Text Text)
connections :: Maybe ConnectionsList
codeGenConfigurationNodes :: Maybe (Sensitive (HashMap Text CodeGenConfigurationNode))
allocatedCapacity :: Maybe Int
$sel:command:CreateJob' :: CreateJob -> JobCommand
$sel:role':CreateJob' :: CreateJob -> Text
$sel:name:CreateJob' :: CreateJob -> Text
$sel:workerType:CreateJob' :: CreateJob -> Maybe WorkerType
$sel:timeout:CreateJob' :: CreateJob -> Maybe Natural
$sel:tags:CreateJob' :: CreateJob -> Maybe (HashMap Text Text)
$sel:sourceControlDetails:CreateJob' :: CreateJob -> Maybe SourceControlDetails
$sel:securityConfiguration:CreateJob' :: CreateJob -> Maybe Text
$sel:numberOfWorkers:CreateJob' :: CreateJob -> Maybe Int
$sel:notificationProperty:CreateJob' :: CreateJob -> Maybe NotificationProperty
$sel:nonOverridableArguments:CreateJob' :: CreateJob -> Maybe (HashMap Text Text)
$sel:maxRetries:CreateJob' :: CreateJob -> Maybe Int
$sel:maxCapacity:CreateJob' :: CreateJob -> Maybe Double
$sel:logUri:CreateJob' :: CreateJob -> Maybe Text
$sel:glueVersion:CreateJob' :: CreateJob -> Maybe Text
$sel:executionProperty:CreateJob' :: CreateJob -> Maybe ExecutionProperty
$sel:executionClass:CreateJob' :: CreateJob -> Maybe ExecutionClass
$sel:description:CreateJob' :: CreateJob -> Maybe Text
$sel:defaultArguments:CreateJob' :: CreateJob -> Maybe (HashMap Text Text)
$sel:connections:CreateJob' :: CreateJob -> Maybe ConnectionsList
$sel:codeGenConfigurationNodes:CreateJob' :: CreateJob
-> Maybe (Sensitive (HashMap Text CodeGenConfigurationNode))
$sel:allocatedCapacity:CreateJob' :: CreateJob -> Maybe Int
..} =
[Pair] -> Value
Data.object
( forall a. [Maybe a] -> [a]
Prelude.catMaybes
[ (Key
"AllocatedCapacity" 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 Int
allocatedCapacity,
(Key
"CodeGenConfigurationNodes" 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 (Sensitive (HashMap Text CodeGenConfigurationNode))
codeGenConfigurationNodes,
(Key
"Connections" 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 ConnectionsList
connections,
(Key
"DefaultArguments" 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 (HashMap Text Text)
defaultArguments,
(Key
"Description" 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
description,
(Key
"ExecutionClass" 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 ExecutionClass
executionClass,
(Key
"ExecutionProperty" 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 ExecutionProperty
executionProperty,
(Key
"GlueVersion" 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
glueVersion,
(Key
"LogUri" 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
logUri,
(Key
"MaxCapacity" 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 Double
maxCapacity,
(Key
"MaxRetries" 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 Int
maxRetries,
(Key
"NonOverridableArguments" 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 (HashMap Text Text)
nonOverridableArguments,
(Key
"NotificationProperty" 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 NotificationProperty
notificationProperty,
(Key
"NumberOfWorkers" 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 Int
numberOfWorkers,
(Key
"SecurityConfiguration" 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
securityConfiguration,
(Key
"SourceControlDetails" 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 SourceControlDetails
sourceControlDetails,
(Key
"Tags" 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 (HashMap Text Text)
tags,
(Key
"Timeout" 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 Natural
timeout,
(Key
"WorkerType" 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 WorkerType
workerType,
forall a. a -> Maybe a
Prelude.Just (Key
"Name" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..= Text
name),
forall a. a -> Maybe a
Prelude.Just (Key
"Role" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..= Text
role'),
forall a. a -> Maybe a
Prelude.Just (Key
"Command" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..= JobCommand
command)
]
)
instance Data.ToPath CreateJob where
toPath :: CreateJob -> ByteString
toPath = forall a b. a -> b -> a
Prelude.const ByteString
"/"
instance Data.ToQuery CreateJob where
toQuery :: CreateJob -> QueryString
toQuery = forall a b. a -> b -> a
Prelude.const forall a. Monoid a => a
Prelude.mempty
data CreateJobResponse = CreateJobResponse'
{
CreateJobResponse -> Maybe Text
name :: Prelude.Maybe Prelude.Text,
CreateJobResponse -> Int
httpStatus :: Prelude.Int
}
deriving (CreateJobResponse -> CreateJobResponse -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: CreateJobResponse -> CreateJobResponse -> Bool
$c/= :: CreateJobResponse -> CreateJobResponse -> Bool
== :: CreateJobResponse -> CreateJobResponse -> Bool
$c== :: CreateJobResponse -> CreateJobResponse -> Bool
Prelude.Eq, ReadPrec [CreateJobResponse]
ReadPrec CreateJobResponse
Int -> ReadS CreateJobResponse
ReadS [CreateJobResponse]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [CreateJobResponse]
$creadListPrec :: ReadPrec [CreateJobResponse]
readPrec :: ReadPrec CreateJobResponse
$creadPrec :: ReadPrec CreateJobResponse
readList :: ReadS [CreateJobResponse]
$creadList :: ReadS [CreateJobResponse]
readsPrec :: Int -> ReadS CreateJobResponse
$creadsPrec :: Int -> ReadS CreateJobResponse
Prelude.Read, Int -> CreateJobResponse -> ShowS
[CreateJobResponse] -> ShowS
CreateJobResponse -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [CreateJobResponse] -> ShowS
$cshowList :: [CreateJobResponse] -> ShowS
show :: CreateJobResponse -> String
$cshow :: CreateJobResponse -> String
showsPrec :: Int -> CreateJobResponse -> ShowS
$cshowsPrec :: Int -> CreateJobResponse -> ShowS
Prelude.Show, forall x. Rep CreateJobResponse x -> CreateJobResponse
forall x. CreateJobResponse -> Rep CreateJobResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep CreateJobResponse x -> CreateJobResponse
$cfrom :: forall x. CreateJobResponse -> Rep CreateJobResponse x
Prelude.Generic)
newCreateJobResponse ::
Prelude.Int ->
CreateJobResponse
newCreateJobResponse :: Int -> CreateJobResponse
newCreateJobResponse Int
pHttpStatus_ =
CreateJobResponse'
{ $sel:name:CreateJobResponse' :: Maybe Text
name = forall a. Maybe a
Prelude.Nothing,
$sel:httpStatus:CreateJobResponse' :: Int
httpStatus = Int
pHttpStatus_
}
createJobResponse_name :: Lens.Lens' CreateJobResponse (Prelude.Maybe Prelude.Text)
createJobResponse_name :: Lens' CreateJobResponse (Maybe Text)
createJobResponse_name = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateJobResponse' {Maybe Text
name :: Maybe Text
$sel:name:CreateJobResponse' :: CreateJobResponse -> Maybe Text
name} -> Maybe Text
name) (\s :: CreateJobResponse
s@CreateJobResponse' {} Maybe Text
a -> CreateJobResponse
s {$sel:name:CreateJobResponse' :: Maybe Text
name = Maybe Text
a} :: CreateJobResponse)
createJobResponse_httpStatus :: Lens.Lens' CreateJobResponse Prelude.Int
createJobResponse_httpStatus :: Lens' CreateJobResponse Int
createJobResponse_httpStatus = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateJobResponse' {Int
httpStatus :: Int
$sel:httpStatus:CreateJobResponse' :: CreateJobResponse -> Int
httpStatus} -> Int
httpStatus) (\s :: CreateJobResponse
s@CreateJobResponse' {} Int
a -> CreateJobResponse
s {$sel:httpStatus:CreateJobResponse' :: Int
httpStatus = Int
a} :: CreateJobResponse)
instance Prelude.NFData CreateJobResponse where
rnf :: CreateJobResponse -> ()
rnf CreateJobResponse' {Int
Maybe Text
httpStatus :: Int
name :: Maybe Text
$sel:httpStatus:CreateJobResponse' :: CreateJobResponse -> Int
$sel:name:CreateJobResponse' :: CreateJobResponse -> Maybe Text
..} =
forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
name
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Int
httpStatus