{-# 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.SageMaker.Types.MonitoringJobDefinition 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.SageMaker.Types.MonitoringAppSpecification
import Amazonka.SageMaker.Types.MonitoringBaselineConfig
import Amazonka.SageMaker.Types.MonitoringInput
import Amazonka.SageMaker.Types.MonitoringOutputConfig
import Amazonka.SageMaker.Types.MonitoringResources
import Amazonka.SageMaker.Types.MonitoringStoppingCondition
import Amazonka.SageMaker.Types.NetworkConfig
data MonitoringJobDefinition = MonitoringJobDefinition'
{
MonitoringJobDefinition -> Maybe MonitoringBaselineConfig
baselineConfig :: Prelude.Maybe MonitoringBaselineConfig,
MonitoringJobDefinition -> Maybe (HashMap Text Text)
environment :: Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text),
MonitoringJobDefinition -> Maybe NetworkConfig
networkConfig :: Prelude.Maybe NetworkConfig,
MonitoringJobDefinition -> Maybe MonitoringStoppingCondition
stoppingCondition :: Prelude.Maybe MonitoringStoppingCondition,
MonitoringJobDefinition -> NonEmpty MonitoringInput
monitoringInputs :: Prelude.NonEmpty MonitoringInput,
MonitoringJobDefinition -> MonitoringOutputConfig
monitoringOutputConfig :: MonitoringOutputConfig,
MonitoringJobDefinition -> MonitoringResources
monitoringResources :: MonitoringResources,
MonitoringJobDefinition -> MonitoringAppSpecification
monitoringAppSpecification :: MonitoringAppSpecification,
MonitoringJobDefinition -> Text
roleArn :: Prelude.Text
}
deriving (MonitoringJobDefinition -> MonitoringJobDefinition -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: MonitoringJobDefinition -> MonitoringJobDefinition -> Bool
$c/= :: MonitoringJobDefinition -> MonitoringJobDefinition -> Bool
== :: MonitoringJobDefinition -> MonitoringJobDefinition -> Bool
$c== :: MonitoringJobDefinition -> MonitoringJobDefinition -> Bool
Prelude.Eq, ReadPrec [MonitoringJobDefinition]
ReadPrec MonitoringJobDefinition
Int -> ReadS MonitoringJobDefinition
ReadS [MonitoringJobDefinition]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [MonitoringJobDefinition]
$creadListPrec :: ReadPrec [MonitoringJobDefinition]
readPrec :: ReadPrec MonitoringJobDefinition
$creadPrec :: ReadPrec MonitoringJobDefinition
readList :: ReadS [MonitoringJobDefinition]
$creadList :: ReadS [MonitoringJobDefinition]
readsPrec :: Int -> ReadS MonitoringJobDefinition
$creadsPrec :: Int -> ReadS MonitoringJobDefinition
Prelude.Read, Int -> MonitoringJobDefinition -> ShowS
[MonitoringJobDefinition] -> ShowS
MonitoringJobDefinition -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [MonitoringJobDefinition] -> ShowS
$cshowList :: [MonitoringJobDefinition] -> ShowS
show :: MonitoringJobDefinition -> String
$cshow :: MonitoringJobDefinition -> String
showsPrec :: Int -> MonitoringJobDefinition -> ShowS
$cshowsPrec :: Int -> MonitoringJobDefinition -> ShowS
Prelude.Show, forall x. Rep MonitoringJobDefinition x -> MonitoringJobDefinition
forall x. MonitoringJobDefinition -> Rep MonitoringJobDefinition x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep MonitoringJobDefinition x -> MonitoringJobDefinition
$cfrom :: forall x. MonitoringJobDefinition -> Rep MonitoringJobDefinition x
Prelude.Generic)
newMonitoringJobDefinition ::
Prelude.NonEmpty MonitoringInput ->
MonitoringOutputConfig ->
MonitoringResources ->
MonitoringAppSpecification ->
Prelude.Text ->
MonitoringJobDefinition
newMonitoringJobDefinition :: NonEmpty MonitoringInput
-> MonitoringOutputConfig
-> MonitoringResources
-> MonitoringAppSpecification
-> Text
-> MonitoringJobDefinition
newMonitoringJobDefinition
NonEmpty MonitoringInput
pMonitoringInputs_
MonitoringOutputConfig
pMonitoringOutputConfig_
MonitoringResources
pMonitoringResources_
MonitoringAppSpecification
pMonitoringAppSpecification_
Text
pRoleArn_ =
MonitoringJobDefinition'
{ $sel:baselineConfig:MonitoringJobDefinition' :: Maybe MonitoringBaselineConfig
baselineConfig =
forall a. Maybe a
Prelude.Nothing,
$sel:environment:MonitoringJobDefinition' :: Maybe (HashMap Text Text)
environment = forall a. Maybe a
Prelude.Nothing,
$sel:networkConfig:MonitoringJobDefinition' :: Maybe NetworkConfig
networkConfig = forall a. Maybe a
Prelude.Nothing,
$sel:stoppingCondition:MonitoringJobDefinition' :: Maybe MonitoringStoppingCondition
stoppingCondition = forall a. Maybe a
Prelude.Nothing,
$sel:monitoringInputs:MonitoringJobDefinition' :: NonEmpty MonitoringInput
monitoringInputs =
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced forall t b. AReview t b -> b -> t
Lens.# NonEmpty MonitoringInput
pMonitoringInputs_,
$sel:monitoringOutputConfig:MonitoringJobDefinition' :: MonitoringOutputConfig
monitoringOutputConfig = MonitoringOutputConfig
pMonitoringOutputConfig_,
$sel:monitoringResources:MonitoringJobDefinition' :: MonitoringResources
monitoringResources = MonitoringResources
pMonitoringResources_,
$sel:monitoringAppSpecification:MonitoringJobDefinition' :: MonitoringAppSpecification
monitoringAppSpecification =
MonitoringAppSpecification
pMonitoringAppSpecification_,
$sel:roleArn:MonitoringJobDefinition' :: Text
roleArn = Text
pRoleArn_
}
monitoringJobDefinition_baselineConfig :: Lens.Lens' MonitoringJobDefinition (Prelude.Maybe MonitoringBaselineConfig)
monitoringJobDefinition_baselineConfig :: Lens' MonitoringJobDefinition (Maybe MonitoringBaselineConfig)
monitoringJobDefinition_baselineConfig = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\MonitoringJobDefinition' {Maybe MonitoringBaselineConfig
baselineConfig :: Maybe MonitoringBaselineConfig
$sel:baselineConfig:MonitoringJobDefinition' :: MonitoringJobDefinition -> Maybe MonitoringBaselineConfig
baselineConfig} -> Maybe MonitoringBaselineConfig
baselineConfig) (\s :: MonitoringJobDefinition
s@MonitoringJobDefinition' {} Maybe MonitoringBaselineConfig
a -> MonitoringJobDefinition
s {$sel:baselineConfig:MonitoringJobDefinition' :: Maybe MonitoringBaselineConfig
baselineConfig = Maybe MonitoringBaselineConfig
a} :: MonitoringJobDefinition)
monitoringJobDefinition_environment :: Lens.Lens' MonitoringJobDefinition (Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text))
monitoringJobDefinition_environment :: Lens' MonitoringJobDefinition (Maybe (HashMap Text Text))
monitoringJobDefinition_environment = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\MonitoringJobDefinition' {Maybe (HashMap Text Text)
environment :: Maybe (HashMap Text Text)
$sel:environment:MonitoringJobDefinition' :: MonitoringJobDefinition -> Maybe (HashMap Text Text)
environment} -> Maybe (HashMap Text Text)
environment) (\s :: MonitoringJobDefinition
s@MonitoringJobDefinition' {} Maybe (HashMap Text Text)
a -> MonitoringJobDefinition
s {$sel:environment:MonitoringJobDefinition' :: Maybe (HashMap Text Text)
environment = Maybe (HashMap Text Text)
a} :: MonitoringJobDefinition) 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
monitoringJobDefinition_networkConfig :: Lens.Lens' MonitoringJobDefinition (Prelude.Maybe NetworkConfig)
monitoringJobDefinition_networkConfig :: Lens' MonitoringJobDefinition (Maybe NetworkConfig)
monitoringJobDefinition_networkConfig = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\MonitoringJobDefinition' {Maybe NetworkConfig
networkConfig :: Maybe NetworkConfig
$sel:networkConfig:MonitoringJobDefinition' :: MonitoringJobDefinition -> Maybe NetworkConfig
networkConfig} -> Maybe NetworkConfig
networkConfig) (\s :: MonitoringJobDefinition
s@MonitoringJobDefinition' {} Maybe NetworkConfig
a -> MonitoringJobDefinition
s {$sel:networkConfig:MonitoringJobDefinition' :: Maybe NetworkConfig
networkConfig = Maybe NetworkConfig
a} :: MonitoringJobDefinition)
monitoringJobDefinition_stoppingCondition :: Lens.Lens' MonitoringJobDefinition (Prelude.Maybe MonitoringStoppingCondition)
monitoringJobDefinition_stoppingCondition :: Lens' MonitoringJobDefinition (Maybe MonitoringStoppingCondition)
monitoringJobDefinition_stoppingCondition = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\MonitoringJobDefinition' {Maybe MonitoringStoppingCondition
stoppingCondition :: Maybe MonitoringStoppingCondition
$sel:stoppingCondition:MonitoringJobDefinition' :: MonitoringJobDefinition -> Maybe MonitoringStoppingCondition
stoppingCondition} -> Maybe MonitoringStoppingCondition
stoppingCondition) (\s :: MonitoringJobDefinition
s@MonitoringJobDefinition' {} Maybe MonitoringStoppingCondition
a -> MonitoringJobDefinition
s {$sel:stoppingCondition:MonitoringJobDefinition' :: Maybe MonitoringStoppingCondition
stoppingCondition = Maybe MonitoringStoppingCondition
a} :: MonitoringJobDefinition)
monitoringJobDefinition_monitoringInputs :: Lens.Lens' MonitoringJobDefinition (Prelude.NonEmpty MonitoringInput)
monitoringJobDefinition_monitoringInputs :: Lens' MonitoringJobDefinition (NonEmpty MonitoringInput)
monitoringJobDefinition_monitoringInputs = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\MonitoringJobDefinition' {NonEmpty MonitoringInput
monitoringInputs :: NonEmpty MonitoringInput
$sel:monitoringInputs:MonitoringJobDefinition' :: MonitoringJobDefinition -> NonEmpty MonitoringInput
monitoringInputs} -> NonEmpty MonitoringInput
monitoringInputs) (\s :: MonitoringJobDefinition
s@MonitoringJobDefinition' {} NonEmpty MonitoringInput
a -> MonitoringJobDefinition
s {$sel:monitoringInputs:MonitoringJobDefinition' :: NonEmpty MonitoringInput
monitoringInputs = NonEmpty MonitoringInput
a} :: MonitoringJobDefinition) 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
monitoringJobDefinition_monitoringOutputConfig :: Lens.Lens' MonitoringJobDefinition MonitoringOutputConfig
monitoringJobDefinition_monitoringOutputConfig :: Lens' MonitoringJobDefinition MonitoringOutputConfig
monitoringJobDefinition_monitoringOutputConfig = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\MonitoringJobDefinition' {MonitoringOutputConfig
monitoringOutputConfig :: MonitoringOutputConfig
$sel:monitoringOutputConfig:MonitoringJobDefinition' :: MonitoringJobDefinition -> MonitoringOutputConfig
monitoringOutputConfig} -> MonitoringOutputConfig
monitoringOutputConfig) (\s :: MonitoringJobDefinition
s@MonitoringJobDefinition' {} MonitoringOutputConfig
a -> MonitoringJobDefinition
s {$sel:monitoringOutputConfig:MonitoringJobDefinition' :: MonitoringOutputConfig
monitoringOutputConfig = MonitoringOutputConfig
a} :: MonitoringJobDefinition)
monitoringJobDefinition_monitoringResources :: Lens.Lens' MonitoringJobDefinition MonitoringResources
monitoringJobDefinition_monitoringResources :: Lens' MonitoringJobDefinition MonitoringResources
monitoringJobDefinition_monitoringResources = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\MonitoringJobDefinition' {MonitoringResources
monitoringResources :: MonitoringResources
$sel:monitoringResources:MonitoringJobDefinition' :: MonitoringJobDefinition -> MonitoringResources
monitoringResources} -> MonitoringResources
monitoringResources) (\s :: MonitoringJobDefinition
s@MonitoringJobDefinition' {} MonitoringResources
a -> MonitoringJobDefinition
s {$sel:monitoringResources:MonitoringJobDefinition' :: MonitoringResources
monitoringResources = MonitoringResources
a} :: MonitoringJobDefinition)
monitoringJobDefinition_monitoringAppSpecification :: Lens.Lens' MonitoringJobDefinition MonitoringAppSpecification
monitoringJobDefinition_monitoringAppSpecification :: Lens' MonitoringJobDefinition MonitoringAppSpecification
monitoringJobDefinition_monitoringAppSpecification = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\MonitoringJobDefinition' {MonitoringAppSpecification
monitoringAppSpecification :: MonitoringAppSpecification
$sel:monitoringAppSpecification:MonitoringJobDefinition' :: MonitoringJobDefinition -> MonitoringAppSpecification
monitoringAppSpecification} -> MonitoringAppSpecification
monitoringAppSpecification) (\s :: MonitoringJobDefinition
s@MonitoringJobDefinition' {} MonitoringAppSpecification
a -> MonitoringJobDefinition
s {$sel:monitoringAppSpecification:MonitoringJobDefinition' :: MonitoringAppSpecification
monitoringAppSpecification = MonitoringAppSpecification
a} :: MonitoringJobDefinition)
monitoringJobDefinition_roleArn :: Lens.Lens' MonitoringJobDefinition Prelude.Text
monitoringJobDefinition_roleArn :: Lens' MonitoringJobDefinition Text
monitoringJobDefinition_roleArn = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\MonitoringJobDefinition' {Text
roleArn :: Text
$sel:roleArn:MonitoringJobDefinition' :: MonitoringJobDefinition -> Text
roleArn} -> Text
roleArn) (\s :: MonitoringJobDefinition
s@MonitoringJobDefinition' {} Text
a -> MonitoringJobDefinition
s {$sel:roleArn:MonitoringJobDefinition' :: Text
roleArn = Text
a} :: MonitoringJobDefinition)
instance Data.FromJSON MonitoringJobDefinition where
parseJSON :: Value -> Parser MonitoringJobDefinition
parseJSON =
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Data.withObject
String
"MonitoringJobDefinition"
( \Object
x ->
Maybe MonitoringBaselineConfig
-> Maybe (HashMap Text Text)
-> Maybe NetworkConfig
-> Maybe MonitoringStoppingCondition
-> NonEmpty MonitoringInput
-> MonitoringOutputConfig
-> MonitoringResources
-> MonitoringAppSpecification
-> Text
-> MonitoringJobDefinition
MonitoringJobDefinition'
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
"BaselineConfig")
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
"Environment" forall a. Parser (Maybe a) -> a -> Parser a
Data..!= forall a. Monoid a => a
Prelude.mempty)
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
"NetworkConfig")
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
"StoppingCondition")
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
"MonitoringInputs")
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
"MonitoringOutputConfig")
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
"MonitoringResources")
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
"MonitoringAppSpecification")
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
"RoleArn")
)
instance Prelude.Hashable MonitoringJobDefinition where
hashWithSalt :: Int -> MonitoringJobDefinition -> Int
hashWithSalt Int
_salt MonitoringJobDefinition' {Maybe (HashMap Text Text)
Maybe MonitoringBaselineConfig
Maybe MonitoringStoppingCondition
Maybe NetworkConfig
NonEmpty MonitoringInput
Text
MonitoringAppSpecification
MonitoringResources
MonitoringOutputConfig
roleArn :: Text
monitoringAppSpecification :: MonitoringAppSpecification
monitoringResources :: MonitoringResources
monitoringOutputConfig :: MonitoringOutputConfig
monitoringInputs :: NonEmpty MonitoringInput
stoppingCondition :: Maybe MonitoringStoppingCondition
networkConfig :: Maybe NetworkConfig
environment :: Maybe (HashMap Text Text)
baselineConfig :: Maybe MonitoringBaselineConfig
$sel:roleArn:MonitoringJobDefinition' :: MonitoringJobDefinition -> Text
$sel:monitoringAppSpecification:MonitoringJobDefinition' :: MonitoringJobDefinition -> MonitoringAppSpecification
$sel:monitoringResources:MonitoringJobDefinition' :: MonitoringJobDefinition -> MonitoringResources
$sel:monitoringOutputConfig:MonitoringJobDefinition' :: MonitoringJobDefinition -> MonitoringOutputConfig
$sel:monitoringInputs:MonitoringJobDefinition' :: MonitoringJobDefinition -> NonEmpty MonitoringInput
$sel:stoppingCondition:MonitoringJobDefinition' :: MonitoringJobDefinition -> Maybe MonitoringStoppingCondition
$sel:networkConfig:MonitoringJobDefinition' :: MonitoringJobDefinition -> Maybe NetworkConfig
$sel:environment:MonitoringJobDefinition' :: MonitoringJobDefinition -> Maybe (HashMap Text Text)
$sel:baselineConfig:MonitoringJobDefinition' :: MonitoringJobDefinition -> Maybe MonitoringBaselineConfig
..} =
Int
_salt
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe MonitoringBaselineConfig
baselineConfig
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe (HashMap Text Text)
environment
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe NetworkConfig
networkConfig
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe MonitoringStoppingCondition
stoppingCondition
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` NonEmpty MonitoringInput
monitoringInputs
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` MonitoringOutputConfig
monitoringOutputConfig
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` MonitoringResources
monitoringResources
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` MonitoringAppSpecification
monitoringAppSpecification
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
roleArn
instance Prelude.NFData MonitoringJobDefinition where
rnf :: MonitoringJobDefinition -> ()
rnf MonitoringJobDefinition' {Maybe (HashMap Text Text)
Maybe MonitoringBaselineConfig
Maybe MonitoringStoppingCondition
Maybe NetworkConfig
NonEmpty MonitoringInput
Text
MonitoringAppSpecification
MonitoringResources
MonitoringOutputConfig
roleArn :: Text
monitoringAppSpecification :: MonitoringAppSpecification
monitoringResources :: MonitoringResources
monitoringOutputConfig :: MonitoringOutputConfig
monitoringInputs :: NonEmpty MonitoringInput
stoppingCondition :: Maybe MonitoringStoppingCondition
networkConfig :: Maybe NetworkConfig
environment :: Maybe (HashMap Text Text)
baselineConfig :: Maybe MonitoringBaselineConfig
$sel:roleArn:MonitoringJobDefinition' :: MonitoringJobDefinition -> Text
$sel:monitoringAppSpecification:MonitoringJobDefinition' :: MonitoringJobDefinition -> MonitoringAppSpecification
$sel:monitoringResources:MonitoringJobDefinition' :: MonitoringJobDefinition -> MonitoringResources
$sel:monitoringOutputConfig:MonitoringJobDefinition' :: MonitoringJobDefinition -> MonitoringOutputConfig
$sel:monitoringInputs:MonitoringJobDefinition' :: MonitoringJobDefinition -> NonEmpty MonitoringInput
$sel:stoppingCondition:MonitoringJobDefinition' :: MonitoringJobDefinition -> Maybe MonitoringStoppingCondition
$sel:networkConfig:MonitoringJobDefinition' :: MonitoringJobDefinition -> Maybe NetworkConfig
$sel:environment:MonitoringJobDefinition' :: MonitoringJobDefinition -> Maybe (HashMap Text Text)
$sel:baselineConfig:MonitoringJobDefinition' :: MonitoringJobDefinition -> Maybe MonitoringBaselineConfig
..} =
forall a. NFData a => a -> ()
Prelude.rnf Maybe MonitoringBaselineConfig
baselineConfig
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe (HashMap Text Text)
environment
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe NetworkConfig
networkConfig
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe MonitoringStoppingCondition
stoppingCondition
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf NonEmpty MonitoringInput
monitoringInputs
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf MonitoringOutputConfig
monitoringOutputConfig
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf MonitoringResources
monitoringResources
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf MonitoringAppSpecification
monitoringAppSpecification
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
roleArn
instance Data.ToJSON MonitoringJobDefinition where
toJSON :: MonitoringJobDefinition -> Value
toJSON MonitoringJobDefinition' {Maybe (HashMap Text Text)
Maybe MonitoringBaselineConfig
Maybe MonitoringStoppingCondition
Maybe NetworkConfig
NonEmpty MonitoringInput
Text
MonitoringAppSpecification
MonitoringResources
MonitoringOutputConfig
roleArn :: Text
monitoringAppSpecification :: MonitoringAppSpecification
monitoringResources :: MonitoringResources
monitoringOutputConfig :: MonitoringOutputConfig
monitoringInputs :: NonEmpty MonitoringInput
stoppingCondition :: Maybe MonitoringStoppingCondition
networkConfig :: Maybe NetworkConfig
environment :: Maybe (HashMap Text Text)
baselineConfig :: Maybe MonitoringBaselineConfig
$sel:roleArn:MonitoringJobDefinition' :: MonitoringJobDefinition -> Text
$sel:monitoringAppSpecification:MonitoringJobDefinition' :: MonitoringJobDefinition -> MonitoringAppSpecification
$sel:monitoringResources:MonitoringJobDefinition' :: MonitoringJobDefinition -> MonitoringResources
$sel:monitoringOutputConfig:MonitoringJobDefinition' :: MonitoringJobDefinition -> MonitoringOutputConfig
$sel:monitoringInputs:MonitoringJobDefinition' :: MonitoringJobDefinition -> NonEmpty MonitoringInput
$sel:stoppingCondition:MonitoringJobDefinition' :: MonitoringJobDefinition -> Maybe MonitoringStoppingCondition
$sel:networkConfig:MonitoringJobDefinition' :: MonitoringJobDefinition -> Maybe NetworkConfig
$sel:environment:MonitoringJobDefinition' :: MonitoringJobDefinition -> Maybe (HashMap Text Text)
$sel:baselineConfig:MonitoringJobDefinition' :: MonitoringJobDefinition -> Maybe MonitoringBaselineConfig
..} =
[Pair] -> Value
Data.object
( forall a. [Maybe a] -> [a]
Prelude.catMaybes
[ (Key
"BaselineConfig" 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 MonitoringBaselineConfig
baselineConfig,
(Key
"Environment" 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)
environment,
(Key
"NetworkConfig" 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 NetworkConfig
networkConfig,
(Key
"StoppingCondition" 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 MonitoringStoppingCondition
stoppingCondition,
forall a. a -> Maybe a
Prelude.Just
(Key
"MonitoringInputs" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..= NonEmpty MonitoringInput
monitoringInputs),
forall a. a -> Maybe a
Prelude.Just
( Key
"MonitoringOutputConfig"
forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..= MonitoringOutputConfig
monitoringOutputConfig
),
forall a. a -> Maybe a
Prelude.Just
(Key
"MonitoringResources" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..= MonitoringResources
monitoringResources),
forall a. a -> Maybe a
Prelude.Just
( Key
"MonitoringAppSpecification"
forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..= MonitoringAppSpecification
monitoringAppSpecification
),
forall a. a -> Maybe a
Prelude.Just (Key
"RoleArn" forall kv v. (KeyValue kv, ToJSON v) => Key -> v -> kv
Data..= Text
roleArn)
]
)