{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE DuplicateRecordFields #-}
{-# LANGUAGE NamedFieldPuns #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE StrictData #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-unused-matches #-}
module Amazonka.SWF.Types.WorkflowExecutionConfiguration where
import qualified Amazonka.Core as Core
import qualified Amazonka.Core.Lens.Internal as Lens
import qualified Amazonka.Data as Data
import qualified Amazonka.Prelude as Prelude
import Amazonka.SWF.Types.ChildPolicy
import Amazonka.SWF.Types.TaskList
data WorkflowExecutionConfiguration = WorkflowExecutionConfiguration'
{
WorkflowExecutionConfiguration -> Maybe Text
lambdaRole :: Prelude.Maybe Prelude.Text,
WorkflowExecutionConfiguration -> Maybe Text
taskPriority :: Prelude.Maybe Prelude.Text,
WorkflowExecutionConfiguration -> Text
taskStartToCloseTimeout :: Prelude.Text,
WorkflowExecutionConfiguration -> Text
executionStartToCloseTimeout :: Prelude.Text,
WorkflowExecutionConfiguration -> TaskList
taskList :: TaskList,
WorkflowExecutionConfiguration -> ChildPolicy
childPolicy :: ChildPolicy
}
deriving (WorkflowExecutionConfiguration
-> WorkflowExecutionConfiguration -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: WorkflowExecutionConfiguration
-> WorkflowExecutionConfiguration -> Bool
$c/= :: WorkflowExecutionConfiguration
-> WorkflowExecutionConfiguration -> Bool
== :: WorkflowExecutionConfiguration
-> WorkflowExecutionConfiguration -> Bool
$c== :: WorkflowExecutionConfiguration
-> WorkflowExecutionConfiguration -> Bool
Prelude.Eq, ReadPrec [WorkflowExecutionConfiguration]
ReadPrec WorkflowExecutionConfiguration
Int -> ReadS WorkflowExecutionConfiguration
ReadS [WorkflowExecutionConfiguration]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [WorkflowExecutionConfiguration]
$creadListPrec :: ReadPrec [WorkflowExecutionConfiguration]
readPrec :: ReadPrec WorkflowExecutionConfiguration
$creadPrec :: ReadPrec WorkflowExecutionConfiguration
readList :: ReadS [WorkflowExecutionConfiguration]
$creadList :: ReadS [WorkflowExecutionConfiguration]
readsPrec :: Int -> ReadS WorkflowExecutionConfiguration
$creadsPrec :: Int -> ReadS WorkflowExecutionConfiguration
Prelude.Read, Int -> WorkflowExecutionConfiguration -> ShowS
[WorkflowExecutionConfiguration] -> ShowS
WorkflowExecutionConfiguration -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [WorkflowExecutionConfiguration] -> ShowS
$cshowList :: [WorkflowExecutionConfiguration] -> ShowS
show :: WorkflowExecutionConfiguration -> String
$cshow :: WorkflowExecutionConfiguration -> String
showsPrec :: Int -> WorkflowExecutionConfiguration -> ShowS
$cshowsPrec :: Int -> WorkflowExecutionConfiguration -> ShowS
Prelude.Show, forall x.
Rep WorkflowExecutionConfiguration x
-> WorkflowExecutionConfiguration
forall x.
WorkflowExecutionConfiguration
-> Rep WorkflowExecutionConfiguration x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep WorkflowExecutionConfiguration x
-> WorkflowExecutionConfiguration
$cfrom :: forall x.
WorkflowExecutionConfiguration
-> Rep WorkflowExecutionConfiguration x
Prelude.Generic)
newWorkflowExecutionConfiguration ::
Prelude.Text ->
Prelude.Text ->
TaskList ->
ChildPolicy ->
WorkflowExecutionConfiguration
newWorkflowExecutionConfiguration :: Text
-> Text
-> TaskList
-> ChildPolicy
-> WorkflowExecutionConfiguration
newWorkflowExecutionConfiguration
Text
pTaskStartToCloseTimeout_
Text
pExecutionStartToCloseTimeout_
TaskList
pTaskList_
ChildPolicy
pChildPolicy_ =
WorkflowExecutionConfiguration'
{ $sel:lambdaRole:WorkflowExecutionConfiguration' :: Maybe Text
lambdaRole =
forall a. Maybe a
Prelude.Nothing,
$sel:taskPriority:WorkflowExecutionConfiguration' :: Maybe Text
taskPriority = forall a. Maybe a
Prelude.Nothing,
$sel:taskStartToCloseTimeout:WorkflowExecutionConfiguration' :: Text
taskStartToCloseTimeout =
Text
pTaskStartToCloseTimeout_,
$sel:executionStartToCloseTimeout:WorkflowExecutionConfiguration' :: Text
executionStartToCloseTimeout =
Text
pExecutionStartToCloseTimeout_,
$sel:taskList:WorkflowExecutionConfiguration' :: TaskList
taskList = TaskList
pTaskList_,
$sel:childPolicy:WorkflowExecutionConfiguration' :: ChildPolicy
childPolicy = ChildPolicy
pChildPolicy_
}
workflowExecutionConfiguration_lambdaRole :: Lens.Lens' WorkflowExecutionConfiguration (Prelude.Maybe Prelude.Text)
workflowExecutionConfiguration_lambdaRole :: Lens' WorkflowExecutionConfiguration (Maybe Text)
workflowExecutionConfiguration_lambdaRole = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\WorkflowExecutionConfiguration' {Maybe Text
lambdaRole :: Maybe Text
$sel:lambdaRole:WorkflowExecutionConfiguration' :: WorkflowExecutionConfiguration -> Maybe Text
lambdaRole} -> Maybe Text
lambdaRole) (\s :: WorkflowExecutionConfiguration
s@WorkflowExecutionConfiguration' {} Maybe Text
a -> WorkflowExecutionConfiguration
s {$sel:lambdaRole:WorkflowExecutionConfiguration' :: Maybe Text
lambdaRole = Maybe Text
a} :: WorkflowExecutionConfiguration)
workflowExecutionConfiguration_taskPriority :: Lens.Lens' WorkflowExecutionConfiguration (Prelude.Maybe Prelude.Text)
workflowExecutionConfiguration_taskPriority :: Lens' WorkflowExecutionConfiguration (Maybe Text)
workflowExecutionConfiguration_taskPriority = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\WorkflowExecutionConfiguration' {Maybe Text
taskPriority :: Maybe Text
$sel:taskPriority:WorkflowExecutionConfiguration' :: WorkflowExecutionConfiguration -> Maybe Text
taskPriority} -> Maybe Text
taskPriority) (\s :: WorkflowExecutionConfiguration
s@WorkflowExecutionConfiguration' {} Maybe Text
a -> WorkflowExecutionConfiguration
s {$sel:taskPriority:WorkflowExecutionConfiguration' :: Maybe Text
taskPriority = Maybe Text
a} :: WorkflowExecutionConfiguration)
workflowExecutionConfiguration_taskStartToCloseTimeout :: Lens.Lens' WorkflowExecutionConfiguration Prelude.Text
workflowExecutionConfiguration_taskStartToCloseTimeout :: Lens' WorkflowExecutionConfiguration Text
workflowExecutionConfiguration_taskStartToCloseTimeout = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\WorkflowExecutionConfiguration' {Text
taskStartToCloseTimeout :: Text
$sel:taskStartToCloseTimeout:WorkflowExecutionConfiguration' :: WorkflowExecutionConfiguration -> Text
taskStartToCloseTimeout} -> Text
taskStartToCloseTimeout) (\s :: WorkflowExecutionConfiguration
s@WorkflowExecutionConfiguration' {} Text
a -> WorkflowExecutionConfiguration
s {$sel:taskStartToCloseTimeout:WorkflowExecutionConfiguration' :: Text
taskStartToCloseTimeout = Text
a} :: WorkflowExecutionConfiguration)
workflowExecutionConfiguration_executionStartToCloseTimeout :: Lens.Lens' WorkflowExecutionConfiguration Prelude.Text
workflowExecutionConfiguration_executionStartToCloseTimeout :: Lens' WorkflowExecutionConfiguration Text
workflowExecutionConfiguration_executionStartToCloseTimeout = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\WorkflowExecutionConfiguration' {Text
executionStartToCloseTimeout :: Text
$sel:executionStartToCloseTimeout:WorkflowExecutionConfiguration' :: WorkflowExecutionConfiguration -> Text
executionStartToCloseTimeout} -> Text
executionStartToCloseTimeout) (\s :: WorkflowExecutionConfiguration
s@WorkflowExecutionConfiguration' {} Text
a -> WorkflowExecutionConfiguration
s {$sel:executionStartToCloseTimeout:WorkflowExecutionConfiguration' :: Text
executionStartToCloseTimeout = Text
a} :: WorkflowExecutionConfiguration)
workflowExecutionConfiguration_taskList :: Lens.Lens' WorkflowExecutionConfiguration TaskList
workflowExecutionConfiguration_taskList :: Lens' WorkflowExecutionConfiguration TaskList
workflowExecutionConfiguration_taskList = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\WorkflowExecutionConfiguration' {TaskList
taskList :: TaskList
$sel:taskList:WorkflowExecutionConfiguration' :: WorkflowExecutionConfiguration -> TaskList
taskList} -> TaskList
taskList) (\s :: WorkflowExecutionConfiguration
s@WorkflowExecutionConfiguration' {} TaskList
a -> WorkflowExecutionConfiguration
s {$sel:taskList:WorkflowExecutionConfiguration' :: TaskList
taskList = TaskList
a} :: WorkflowExecutionConfiguration)
workflowExecutionConfiguration_childPolicy :: Lens.Lens' WorkflowExecutionConfiguration ChildPolicy
workflowExecutionConfiguration_childPolicy :: Lens' WorkflowExecutionConfiguration ChildPolicy
workflowExecutionConfiguration_childPolicy = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\WorkflowExecutionConfiguration' {ChildPolicy
childPolicy :: ChildPolicy
$sel:childPolicy:WorkflowExecutionConfiguration' :: WorkflowExecutionConfiguration -> ChildPolicy
childPolicy} -> ChildPolicy
childPolicy) (\s :: WorkflowExecutionConfiguration
s@WorkflowExecutionConfiguration' {} ChildPolicy
a -> WorkflowExecutionConfiguration
s {$sel:childPolicy:WorkflowExecutionConfiguration' :: ChildPolicy
childPolicy = ChildPolicy
a} :: WorkflowExecutionConfiguration)
instance Data.FromJSON WorkflowExecutionConfiguration where
parseJSON :: Value -> Parser WorkflowExecutionConfiguration
parseJSON =
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Data.withObject
String
"WorkflowExecutionConfiguration"
( \Object
x ->
Maybe Text
-> Maybe Text
-> Text
-> Text
-> TaskList
-> ChildPolicy
-> WorkflowExecutionConfiguration
WorkflowExecutionConfiguration'
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"lambdaRole")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"taskPriority")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser a
Data..: Key
"taskStartToCloseTimeout")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser a
Data..: Key
"executionStartToCloseTimeout")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser a
Data..: Key
"taskList")
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser a
Data..: Key
"childPolicy")
)
instance
Prelude.Hashable
WorkflowExecutionConfiguration
where
hashWithSalt :: Int -> WorkflowExecutionConfiguration -> Int
hashWithSalt
Int
_salt
WorkflowExecutionConfiguration' {Maybe Text
Text
ChildPolicy
TaskList
childPolicy :: ChildPolicy
taskList :: TaskList
executionStartToCloseTimeout :: Text
taskStartToCloseTimeout :: Text
taskPriority :: Maybe Text
lambdaRole :: Maybe Text
$sel:childPolicy:WorkflowExecutionConfiguration' :: WorkflowExecutionConfiguration -> ChildPolicy
$sel:taskList:WorkflowExecutionConfiguration' :: WorkflowExecutionConfiguration -> TaskList
$sel:executionStartToCloseTimeout:WorkflowExecutionConfiguration' :: WorkflowExecutionConfiguration -> Text
$sel:taskStartToCloseTimeout:WorkflowExecutionConfiguration' :: WorkflowExecutionConfiguration -> Text
$sel:taskPriority:WorkflowExecutionConfiguration' :: WorkflowExecutionConfiguration -> Maybe Text
$sel:lambdaRole:WorkflowExecutionConfiguration' :: WorkflowExecutionConfiguration -> Maybe Text
..} =
Int
_salt
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
lambdaRole
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
taskPriority
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
taskStartToCloseTimeout
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
executionStartToCloseTimeout
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` TaskList
taskList
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` ChildPolicy
childPolicy
instance
Prelude.NFData
WorkflowExecutionConfiguration
where
rnf :: WorkflowExecutionConfiguration -> ()
rnf WorkflowExecutionConfiguration' {Maybe Text
Text
ChildPolicy
TaskList
childPolicy :: ChildPolicy
taskList :: TaskList
executionStartToCloseTimeout :: Text
taskStartToCloseTimeout :: Text
taskPriority :: Maybe Text
lambdaRole :: Maybe Text
$sel:childPolicy:WorkflowExecutionConfiguration' :: WorkflowExecutionConfiguration -> ChildPolicy
$sel:taskList:WorkflowExecutionConfiguration' :: WorkflowExecutionConfiguration -> TaskList
$sel:executionStartToCloseTimeout:WorkflowExecutionConfiguration' :: WorkflowExecutionConfiguration -> Text
$sel:taskStartToCloseTimeout:WorkflowExecutionConfiguration' :: WorkflowExecutionConfiguration -> Text
$sel:taskPriority:WorkflowExecutionConfiguration' :: WorkflowExecutionConfiguration -> Maybe Text
$sel:lambdaRole:WorkflowExecutionConfiguration' :: WorkflowExecutionConfiguration -> Maybe Text
..} =
forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
lambdaRole
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
taskPriority
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
taskStartToCloseTimeout
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
executionStartToCloseTimeout
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf TaskList
taskList
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf ChildPolicy
childPolicy