{-# 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.XRay.Types.InsightSummary where
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
import Amazonka.XRay.Types.AnomalousService
import Amazonka.XRay.Types.InsightCategory
import Amazonka.XRay.Types.InsightState
import Amazonka.XRay.Types.RequestImpactStatistics
import Amazonka.XRay.Types.ServiceId
data InsightSummary = InsightSummary'
{
InsightSummary -> Maybe Text
summary :: Prelude.Maybe Prelude.Text,
InsightSummary -> Maybe InsightState
state :: Prelude.Maybe InsightState,
InsightSummary -> Maybe POSIX
startTime :: Prelude.Maybe Core.POSIX,
InsightSummary -> Maybe Text
insightId :: Prelude.Maybe Prelude.Text,
InsightSummary -> Maybe [InsightCategory]
categories :: Prelude.Maybe [InsightCategory],
InsightSummary -> Maybe RequestImpactStatistics
rootCauseServiceRequestImpactStatistics :: Prelude.Maybe RequestImpactStatistics,
InsightSummary -> Maybe [AnomalousService]
topAnomalousServices :: Prelude.Maybe [AnomalousService],
InsightSummary -> Maybe ServiceId
rootCauseServiceId :: Prelude.Maybe ServiceId,
InsightSummary -> Maybe RequestImpactStatistics
clientRequestImpactStatistics :: Prelude.Maybe RequestImpactStatistics,
InsightSummary -> Maybe POSIX
endTime :: Prelude.Maybe Core.POSIX,
InsightSummary -> Maybe Text
groupARN :: Prelude.Maybe Prelude.Text,
InsightSummary -> Maybe Text
groupName :: Prelude.Maybe Prelude.Text,
InsightSummary -> Maybe POSIX
lastUpdateTime :: Prelude.Maybe Core.POSIX
}
deriving (InsightSummary -> InsightSummary -> Bool
(InsightSummary -> InsightSummary -> Bool)
-> (InsightSummary -> InsightSummary -> Bool) -> Eq InsightSummary
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: InsightSummary -> InsightSummary -> Bool
$c/= :: InsightSummary -> InsightSummary -> Bool
== :: InsightSummary -> InsightSummary -> Bool
$c== :: InsightSummary -> InsightSummary -> Bool
Prelude.Eq, ReadPrec [InsightSummary]
ReadPrec InsightSummary
Int -> ReadS InsightSummary
ReadS [InsightSummary]
(Int -> ReadS InsightSummary)
-> ReadS [InsightSummary]
-> ReadPrec InsightSummary
-> ReadPrec [InsightSummary]
-> Read InsightSummary
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [InsightSummary]
$creadListPrec :: ReadPrec [InsightSummary]
readPrec :: ReadPrec InsightSummary
$creadPrec :: ReadPrec InsightSummary
readList :: ReadS [InsightSummary]
$creadList :: ReadS [InsightSummary]
readsPrec :: Int -> ReadS InsightSummary
$creadsPrec :: Int -> ReadS InsightSummary
Prelude.Read, Int -> InsightSummary -> ShowS
[InsightSummary] -> ShowS
InsightSummary -> String
(Int -> InsightSummary -> ShowS)
-> (InsightSummary -> String)
-> ([InsightSummary] -> ShowS)
-> Show InsightSummary
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [InsightSummary] -> ShowS
$cshowList :: [InsightSummary] -> ShowS
show :: InsightSummary -> String
$cshow :: InsightSummary -> String
showsPrec :: Int -> InsightSummary -> ShowS
$cshowsPrec :: Int -> InsightSummary -> ShowS
Prelude.Show, (forall x. InsightSummary -> Rep InsightSummary x)
-> (forall x. Rep InsightSummary x -> InsightSummary)
-> Generic InsightSummary
forall x. Rep InsightSummary x -> InsightSummary
forall x. InsightSummary -> Rep InsightSummary x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep InsightSummary x -> InsightSummary
$cfrom :: forall x. InsightSummary -> Rep InsightSummary x
Prelude.Generic)
newInsightSummary ::
InsightSummary
newInsightSummary :: InsightSummary
newInsightSummary =
InsightSummary' :: Maybe Text
-> Maybe InsightState
-> Maybe POSIX
-> Maybe Text
-> Maybe [InsightCategory]
-> Maybe RequestImpactStatistics
-> Maybe [AnomalousService]
-> Maybe ServiceId
-> Maybe RequestImpactStatistics
-> Maybe POSIX
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> InsightSummary
InsightSummary'
{ $sel:summary:InsightSummary' :: Maybe Text
summary = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:state:InsightSummary' :: Maybe InsightState
state = Maybe InsightState
forall a. Maybe a
Prelude.Nothing,
$sel:startTime:InsightSummary' :: Maybe POSIX
startTime = Maybe POSIX
forall a. Maybe a
Prelude.Nothing,
$sel:insightId:InsightSummary' :: Maybe Text
insightId = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:categories:InsightSummary' :: Maybe [InsightCategory]
categories = Maybe [InsightCategory]
forall a. Maybe a
Prelude.Nothing,
$sel:rootCauseServiceRequestImpactStatistics:InsightSummary' :: Maybe RequestImpactStatistics
rootCauseServiceRequestImpactStatistics =
Maybe RequestImpactStatistics
forall a. Maybe a
Prelude.Nothing,
$sel:topAnomalousServices:InsightSummary' :: Maybe [AnomalousService]
topAnomalousServices = Maybe [AnomalousService]
forall a. Maybe a
Prelude.Nothing,
$sel:rootCauseServiceId:InsightSummary' :: Maybe ServiceId
rootCauseServiceId = Maybe ServiceId
forall a. Maybe a
Prelude.Nothing,
$sel:clientRequestImpactStatistics:InsightSummary' :: Maybe RequestImpactStatistics
clientRequestImpactStatistics = Maybe RequestImpactStatistics
forall a. Maybe a
Prelude.Nothing,
$sel:endTime:InsightSummary' :: Maybe POSIX
endTime = Maybe POSIX
forall a. Maybe a
Prelude.Nothing,
$sel:groupARN:InsightSummary' :: Maybe Text
groupARN = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:groupName:InsightSummary' :: Maybe Text
groupName = Maybe Text
forall a. Maybe a
Prelude.Nothing,
$sel:lastUpdateTime:InsightSummary' :: Maybe POSIX
lastUpdateTime = Maybe POSIX
forall a. Maybe a
Prelude.Nothing
}
insightSummary_summary :: Lens.Lens' InsightSummary (Prelude.Maybe Prelude.Text)
insightSummary_summary :: (Maybe Text -> f (Maybe Text))
-> InsightSummary -> f InsightSummary
insightSummary_summary = (InsightSummary -> Maybe Text)
-> (InsightSummary -> Maybe Text -> InsightSummary)
-> Lens InsightSummary InsightSummary (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InsightSummary' {Maybe Text
summary :: Maybe Text
$sel:summary:InsightSummary' :: InsightSummary -> Maybe Text
summary} -> Maybe Text
summary) (\s :: InsightSummary
s@InsightSummary' {} Maybe Text
a -> InsightSummary
s {$sel:summary:InsightSummary' :: Maybe Text
summary = Maybe Text
a} :: InsightSummary)
insightSummary_state :: Lens.Lens' InsightSummary (Prelude.Maybe InsightState)
insightSummary_state :: (Maybe InsightState -> f (Maybe InsightState))
-> InsightSummary -> f InsightSummary
insightSummary_state = (InsightSummary -> Maybe InsightState)
-> (InsightSummary -> Maybe InsightState -> InsightSummary)
-> Lens
InsightSummary
InsightSummary
(Maybe InsightState)
(Maybe InsightState)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InsightSummary' {Maybe InsightState
state :: Maybe InsightState
$sel:state:InsightSummary' :: InsightSummary -> Maybe InsightState
state} -> Maybe InsightState
state) (\s :: InsightSummary
s@InsightSummary' {} Maybe InsightState
a -> InsightSummary
s {$sel:state:InsightSummary' :: Maybe InsightState
state = Maybe InsightState
a} :: InsightSummary)
insightSummary_startTime :: Lens.Lens' InsightSummary (Prelude.Maybe Prelude.UTCTime)
insightSummary_startTime :: (Maybe UTCTime -> f (Maybe UTCTime))
-> InsightSummary -> f InsightSummary
insightSummary_startTime = (InsightSummary -> Maybe POSIX)
-> (InsightSummary -> Maybe POSIX -> InsightSummary)
-> Lens InsightSummary InsightSummary (Maybe POSIX) (Maybe POSIX)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InsightSummary' {Maybe POSIX
startTime :: Maybe POSIX
$sel:startTime:InsightSummary' :: InsightSummary -> Maybe POSIX
startTime} -> Maybe POSIX
startTime) (\s :: InsightSummary
s@InsightSummary' {} Maybe POSIX
a -> InsightSummary
s {$sel:startTime:InsightSummary' :: Maybe POSIX
startTime = Maybe POSIX
a} :: InsightSummary) ((Maybe POSIX -> f (Maybe POSIX))
-> InsightSummary -> f InsightSummary)
-> ((Maybe UTCTime -> f (Maybe UTCTime))
-> Maybe POSIX -> f (Maybe POSIX))
-> (Maybe UTCTime -> f (Maybe UTCTime))
-> InsightSummary
-> f InsightSummary
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso POSIX POSIX UTCTime UTCTime
-> Iso (Maybe POSIX) (Maybe POSIX) (Maybe UTCTime) (Maybe UTCTime)
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 POSIX POSIX UTCTime UTCTime
forall (a :: Format). Iso' (Time a) UTCTime
Core._Time
insightSummary_insightId :: Lens.Lens' InsightSummary (Prelude.Maybe Prelude.Text)
insightSummary_insightId :: (Maybe Text -> f (Maybe Text))
-> InsightSummary -> f InsightSummary
insightSummary_insightId = (InsightSummary -> Maybe Text)
-> (InsightSummary -> Maybe Text -> InsightSummary)
-> Lens InsightSummary InsightSummary (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InsightSummary' {Maybe Text
insightId :: Maybe Text
$sel:insightId:InsightSummary' :: InsightSummary -> Maybe Text
insightId} -> Maybe Text
insightId) (\s :: InsightSummary
s@InsightSummary' {} Maybe Text
a -> InsightSummary
s {$sel:insightId:InsightSummary' :: Maybe Text
insightId = Maybe Text
a} :: InsightSummary)
insightSummary_categories :: Lens.Lens' InsightSummary (Prelude.Maybe [InsightCategory])
insightSummary_categories :: (Maybe [InsightCategory] -> f (Maybe [InsightCategory]))
-> InsightSummary -> f InsightSummary
insightSummary_categories = (InsightSummary -> Maybe [InsightCategory])
-> (InsightSummary -> Maybe [InsightCategory] -> InsightSummary)
-> Lens
InsightSummary
InsightSummary
(Maybe [InsightCategory])
(Maybe [InsightCategory])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InsightSummary' {Maybe [InsightCategory]
categories :: Maybe [InsightCategory]
$sel:categories:InsightSummary' :: InsightSummary -> Maybe [InsightCategory]
categories} -> Maybe [InsightCategory]
categories) (\s :: InsightSummary
s@InsightSummary' {} Maybe [InsightCategory]
a -> InsightSummary
s {$sel:categories:InsightSummary' :: Maybe [InsightCategory]
categories = Maybe [InsightCategory]
a} :: InsightSummary) ((Maybe [InsightCategory] -> f (Maybe [InsightCategory]))
-> InsightSummary -> f InsightSummary)
-> ((Maybe [InsightCategory] -> f (Maybe [InsightCategory]))
-> Maybe [InsightCategory] -> f (Maybe [InsightCategory]))
-> (Maybe [InsightCategory] -> f (Maybe [InsightCategory]))
-> InsightSummary
-> f InsightSummary
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
[InsightCategory]
[InsightCategory]
[InsightCategory]
[InsightCategory]
-> Iso
(Maybe [InsightCategory])
(Maybe [InsightCategory])
(Maybe [InsightCategory])
(Maybe [InsightCategory])
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
[InsightCategory]
[InsightCategory]
[InsightCategory]
[InsightCategory]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
insightSummary_rootCauseServiceRequestImpactStatistics :: Lens.Lens' InsightSummary (Prelude.Maybe RequestImpactStatistics)
insightSummary_rootCauseServiceRequestImpactStatistics :: (Maybe RequestImpactStatistics
-> f (Maybe RequestImpactStatistics))
-> InsightSummary -> f InsightSummary
insightSummary_rootCauseServiceRequestImpactStatistics = (InsightSummary -> Maybe RequestImpactStatistics)
-> (InsightSummary
-> Maybe RequestImpactStatistics -> InsightSummary)
-> Lens
InsightSummary
InsightSummary
(Maybe RequestImpactStatistics)
(Maybe RequestImpactStatistics)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InsightSummary' {Maybe RequestImpactStatistics
rootCauseServiceRequestImpactStatistics :: Maybe RequestImpactStatistics
$sel:rootCauseServiceRequestImpactStatistics:InsightSummary' :: InsightSummary -> Maybe RequestImpactStatistics
rootCauseServiceRequestImpactStatistics} -> Maybe RequestImpactStatistics
rootCauseServiceRequestImpactStatistics) (\s :: InsightSummary
s@InsightSummary' {} Maybe RequestImpactStatistics
a -> InsightSummary
s {$sel:rootCauseServiceRequestImpactStatistics:InsightSummary' :: Maybe RequestImpactStatistics
rootCauseServiceRequestImpactStatistics = Maybe RequestImpactStatistics
a} :: InsightSummary)
insightSummary_topAnomalousServices :: Lens.Lens' InsightSummary (Prelude.Maybe [AnomalousService])
insightSummary_topAnomalousServices :: (Maybe [AnomalousService] -> f (Maybe [AnomalousService]))
-> InsightSummary -> f InsightSummary
insightSummary_topAnomalousServices = (InsightSummary -> Maybe [AnomalousService])
-> (InsightSummary -> Maybe [AnomalousService] -> InsightSummary)
-> Lens
InsightSummary
InsightSummary
(Maybe [AnomalousService])
(Maybe [AnomalousService])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InsightSummary' {Maybe [AnomalousService]
topAnomalousServices :: Maybe [AnomalousService]
$sel:topAnomalousServices:InsightSummary' :: InsightSummary -> Maybe [AnomalousService]
topAnomalousServices} -> Maybe [AnomalousService]
topAnomalousServices) (\s :: InsightSummary
s@InsightSummary' {} Maybe [AnomalousService]
a -> InsightSummary
s {$sel:topAnomalousServices:InsightSummary' :: Maybe [AnomalousService]
topAnomalousServices = Maybe [AnomalousService]
a} :: InsightSummary) ((Maybe [AnomalousService] -> f (Maybe [AnomalousService]))
-> InsightSummary -> f InsightSummary)
-> ((Maybe [AnomalousService] -> f (Maybe [AnomalousService]))
-> Maybe [AnomalousService] -> f (Maybe [AnomalousService]))
-> (Maybe [AnomalousService] -> f (Maybe [AnomalousService]))
-> InsightSummary
-> f InsightSummary
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
[AnomalousService]
[AnomalousService]
[AnomalousService]
[AnomalousService]
-> Iso
(Maybe [AnomalousService])
(Maybe [AnomalousService])
(Maybe [AnomalousService])
(Maybe [AnomalousService])
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
[AnomalousService]
[AnomalousService]
[AnomalousService]
[AnomalousService]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
insightSummary_rootCauseServiceId :: Lens.Lens' InsightSummary (Prelude.Maybe ServiceId)
insightSummary_rootCauseServiceId :: (Maybe ServiceId -> f (Maybe ServiceId))
-> InsightSummary -> f InsightSummary
insightSummary_rootCauseServiceId = (InsightSummary -> Maybe ServiceId)
-> (InsightSummary -> Maybe ServiceId -> InsightSummary)
-> Lens
InsightSummary InsightSummary (Maybe ServiceId) (Maybe ServiceId)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InsightSummary' {Maybe ServiceId
rootCauseServiceId :: Maybe ServiceId
$sel:rootCauseServiceId:InsightSummary' :: InsightSummary -> Maybe ServiceId
rootCauseServiceId} -> Maybe ServiceId
rootCauseServiceId) (\s :: InsightSummary
s@InsightSummary' {} Maybe ServiceId
a -> InsightSummary
s {$sel:rootCauseServiceId:InsightSummary' :: Maybe ServiceId
rootCauseServiceId = Maybe ServiceId
a} :: InsightSummary)
insightSummary_clientRequestImpactStatistics :: Lens.Lens' InsightSummary (Prelude.Maybe RequestImpactStatistics)
insightSummary_clientRequestImpactStatistics :: (Maybe RequestImpactStatistics
-> f (Maybe RequestImpactStatistics))
-> InsightSummary -> f InsightSummary
insightSummary_clientRequestImpactStatistics = (InsightSummary -> Maybe RequestImpactStatistics)
-> (InsightSummary
-> Maybe RequestImpactStatistics -> InsightSummary)
-> Lens
InsightSummary
InsightSummary
(Maybe RequestImpactStatistics)
(Maybe RequestImpactStatistics)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InsightSummary' {Maybe RequestImpactStatistics
clientRequestImpactStatistics :: Maybe RequestImpactStatistics
$sel:clientRequestImpactStatistics:InsightSummary' :: InsightSummary -> Maybe RequestImpactStatistics
clientRequestImpactStatistics} -> Maybe RequestImpactStatistics
clientRequestImpactStatistics) (\s :: InsightSummary
s@InsightSummary' {} Maybe RequestImpactStatistics
a -> InsightSummary
s {$sel:clientRequestImpactStatistics:InsightSummary' :: Maybe RequestImpactStatistics
clientRequestImpactStatistics = Maybe RequestImpactStatistics
a} :: InsightSummary)
insightSummary_endTime :: Lens.Lens' InsightSummary (Prelude.Maybe Prelude.UTCTime)
insightSummary_endTime :: (Maybe UTCTime -> f (Maybe UTCTime))
-> InsightSummary -> f InsightSummary
insightSummary_endTime = (InsightSummary -> Maybe POSIX)
-> (InsightSummary -> Maybe POSIX -> InsightSummary)
-> Lens InsightSummary InsightSummary (Maybe POSIX) (Maybe POSIX)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InsightSummary' {Maybe POSIX
endTime :: Maybe POSIX
$sel:endTime:InsightSummary' :: InsightSummary -> Maybe POSIX
endTime} -> Maybe POSIX
endTime) (\s :: InsightSummary
s@InsightSummary' {} Maybe POSIX
a -> InsightSummary
s {$sel:endTime:InsightSummary' :: Maybe POSIX
endTime = Maybe POSIX
a} :: InsightSummary) ((Maybe POSIX -> f (Maybe POSIX))
-> InsightSummary -> f InsightSummary)
-> ((Maybe UTCTime -> f (Maybe UTCTime))
-> Maybe POSIX -> f (Maybe POSIX))
-> (Maybe UTCTime -> f (Maybe UTCTime))
-> InsightSummary
-> f InsightSummary
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso POSIX POSIX UTCTime UTCTime
-> Iso (Maybe POSIX) (Maybe POSIX) (Maybe UTCTime) (Maybe UTCTime)
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 POSIX POSIX UTCTime UTCTime
forall (a :: Format). Iso' (Time a) UTCTime
Core._Time
insightSummary_groupARN :: Lens.Lens' InsightSummary (Prelude.Maybe Prelude.Text)
insightSummary_groupARN :: (Maybe Text -> f (Maybe Text))
-> InsightSummary -> f InsightSummary
insightSummary_groupARN = (InsightSummary -> Maybe Text)
-> (InsightSummary -> Maybe Text -> InsightSummary)
-> Lens InsightSummary InsightSummary (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InsightSummary' {Maybe Text
groupARN :: Maybe Text
$sel:groupARN:InsightSummary' :: InsightSummary -> Maybe Text
groupARN} -> Maybe Text
groupARN) (\s :: InsightSummary
s@InsightSummary' {} Maybe Text
a -> InsightSummary
s {$sel:groupARN:InsightSummary' :: Maybe Text
groupARN = Maybe Text
a} :: InsightSummary)
insightSummary_groupName :: Lens.Lens' InsightSummary (Prelude.Maybe Prelude.Text)
insightSummary_groupName :: (Maybe Text -> f (Maybe Text))
-> InsightSummary -> f InsightSummary
insightSummary_groupName = (InsightSummary -> Maybe Text)
-> (InsightSummary -> Maybe Text -> InsightSummary)
-> Lens InsightSummary InsightSummary (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InsightSummary' {Maybe Text
groupName :: Maybe Text
$sel:groupName:InsightSummary' :: InsightSummary -> Maybe Text
groupName} -> Maybe Text
groupName) (\s :: InsightSummary
s@InsightSummary' {} Maybe Text
a -> InsightSummary
s {$sel:groupName:InsightSummary' :: Maybe Text
groupName = Maybe Text
a} :: InsightSummary)
insightSummary_lastUpdateTime :: Lens.Lens' InsightSummary (Prelude.Maybe Prelude.UTCTime)
insightSummary_lastUpdateTime :: (Maybe UTCTime -> f (Maybe UTCTime))
-> InsightSummary -> f InsightSummary
insightSummary_lastUpdateTime = (InsightSummary -> Maybe POSIX)
-> (InsightSummary -> Maybe POSIX -> InsightSummary)
-> Lens InsightSummary InsightSummary (Maybe POSIX) (Maybe POSIX)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\InsightSummary' {Maybe POSIX
lastUpdateTime :: Maybe POSIX
$sel:lastUpdateTime:InsightSummary' :: InsightSummary -> Maybe POSIX
lastUpdateTime} -> Maybe POSIX
lastUpdateTime) (\s :: InsightSummary
s@InsightSummary' {} Maybe POSIX
a -> InsightSummary
s {$sel:lastUpdateTime:InsightSummary' :: Maybe POSIX
lastUpdateTime = Maybe POSIX
a} :: InsightSummary) ((Maybe POSIX -> f (Maybe POSIX))
-> InsightSummary -> f InsightSummary)
-> ((Maybe UTCTime -> f (Maybe UTCTime))
-> Maybe POSIX -> f (Maybe POSIX))
-> (Maybe UTCTime -> f (Maybe UTCTime))
-> InsightSummary
-> f InsightSummary
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso POSIX POSIX UTCTime UTCTime
-> Iso (Maybe POSIX) (Maybe POSIX) (Maybe UTCTime) (Maybe UTCTime)
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 POSIX POSIX UTCTime UTCTime
forall (a :: Format). Iso' (Time a) UTCTime
Core._Time
instance Core.FromJSON InsightSummary where
parseJSON :: Value -> Parser InsightSummary
parseJSON =
String
-> (Object -> Parser InsightSummary)
-> Value
-> Parser InsightSummary
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Core.withObject
String
"InsightSummary"
( \Object
x ->
Maybe Text
-> Maybe InsightState
-> Maybe POSIX
-> Maybe Text
-> Maybe [InsightCategory]
-> Maybe RequestImpactStatistics
-> Maybe [AnomalousService]
-> Maybe ServiceId
-> Maybe RequestImpactStatistics
-> Maybe POSIX
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> InsightSummary
InsightSummary'
(Maybe Text
-> Maybe InsightState
-> Maybe POSIX
-> Maybe Text
-> Maybe [InsightCategory]
-> Maybe RequestImpactStatistics
-> Maybe [AnomalousService]
-> Maybe ServiceId
-> Maybe RequestImpactStatistics
-> Maybe POSIX
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> InsightSummary)
-> Parser (Maybe Text)
-> Parser
(Maybe InsightState
-> Maybe POSIX
-> Maybe Text
-> Maybe [InsightCategory]
-> Maybe RequestImpactStatistics
-> Maybe [AnomalousService]
-> Maybe ServiceId
-> Maybe RequestImpactStatistics
-> Maybe POSIX
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> InsightSummary)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Summary")
Parser
(Maybe InsightState
-> Maybe POSIX
-> Maybe Text
-> Maybe [InsightCategory]
-> Maybe RequestImpactStatistics
-> Maybe [AnomalousService]
-> Maybe ServiceId
-> Maybe RequestImpactStatistics
-> Maybe POSIX
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> InsightSummary)
-> Parser (Maybe InsightState)
-> Parser
(Maybe POSIX
-> Maybe Text
-> Maybe [InsightCategory]
-> Maybe RequestImpactStatistics
-> Maybe [AnomalousService]
-> Maybe ServiceId
-> Maybe RequestImpactStatistics
-> Maybe POSIX
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> InsightSummary)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe InsightState)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"State")
Parser
(Maybe POSIX
-> Maybe Text
-> Maybe [InsightCategory]
-> Maybe RequestImpactStatistics
-> Maybe [AnomalousService]
-> Maybe ServiceId
-> Maybe RequestImpactStatistics
-> Maybe POSIX
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> InsightSummary)
-> Parser (Maybe POSIX)
-> Parser
(Maybe Text
-> Maybe [InsightCategory]
-> Maybe RequestImpactStatistics
-> Maybe [AnomalousService]
-> Maybe ServiceId
-> Maybe RequestImpactStatistics
-> Maybe POSIX
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> InsightSummary)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe POSIX)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"StartTime")
Parser
(Maybe Text
-> Maybe [InsightCategory]
-> Maybe RequestImpactStatistics
-> Maybe [AnomalousService]
-> Maybe ServiceId
-> Maybe RequestImpactStatistics
-> Maybe POSIX
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> InsightSummary)
-> Parser (Maybe Text)
-> Parser
(Maybe [InsightCategory]
-> Maybe RequestImpactStatistics
-> Maybe [AnomalousService]
-> Maybe ServiceId
-> Maybe RequestImpactStatistics
-> Maybe POSIX
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> InsightSummary)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"InsightId")
Parser
(Maybe [InsightCategory]
-> Maybe RequestImpactStatistics
-> Maybe [AnomalousService]
-> Maybe ServiceId
-> Maybe RequestImpactStatistics
-> Maybe POSIX
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> InsightSummary)
-> Parser (Maybe [InsightCategory])
-> Parser
(Maybe RequestImpactStatistics
-> Maybe [AnomalousService]
-> Maybe ServiceId
-> Maybe RequestImpactStatistics
-> Maybe POSIX
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> InsightSummary)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe (Maybe [InsightCategory]))
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Categories" Parser (Maybe (Maybe [InsightCategory]))
-> Maybe [InsightCategory] -> Parser (Maybe [InsightCategory])
forall a. Parser (Maybe a) -> a -> Parser a
Core..!= Maybe [InsightCategory]
forall a. Monoid a => a
Prelude.mempty)
Parser
(Maybe RequestImpactStatistics
-> Maybe [AnomalousService]
-> Maybe ServiceId
-> Maybe RequestImpactStatistics
-> Maybe POSIX
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> InsightSummary)
-> Parser (Maybe RequestImpactStatistics)
-> Parser
(Maybe [AnomalousService]
-> Maybe ServiceId
-> Maybe RequestImpactStatistics
-> Maybe POSIX
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> InsightSummary)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( Object
x
Object -> Text -> Parser (Maybe RequestImpactStatistics)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"RootCauseServiceRequestImpactStatistics"
)
Parser
(Maybe [AnomalousService]
-> Maybe ServiceId
-> Maybe RequestImpactStatistics
-> Maybe POSIX
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> InsightSummary)
-> Parser (Maybe [AnomalousService])
-> Parser
(Maybe ServiceId
-> Maybe RequestImpactStatistics
-> Maybe POSIX
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> InsightSummary)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( Object
x Object -> Text -> Parser (Maybe (Maybe [AnomalousService]))
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"TopAnomalousServices"
Parser (Maybe (Maybe [AnomalousService]))
-> Maybe [AnomalousService] -> Parser (Maybe [AnomalousService])
forall a. Parser (Maybe a) -> a -> Parser a
Core..!= Maybe [AnomalousService]
forall a. Monoid a => a
Prelude.mempty
)
Parser
(Maybe ServiceId
-> Maybe RequestImpactStatistics
-> Maybe POSIX
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> InsightSummary)
-> Parser (Maybe ServiceId)
-> Parser
(Maybe RequestImpactStatistics
-> Maybe POSIX
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> InsightSummary)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe ServiceId)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"RootCauseServiceId")
Parser
(Maybe RequestImpactStatistics
-> Maybe POSIX
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> InsightSummary)
-> Parser (Maybe RequestImpactStatistics)
-> Parser
(Maybe POSIX
-> Maybe Text -> Maybe Text -> Maybe POSIX -> InsightSummary)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe RequestImpactStatistics)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"ClientRequestImpactStatistics")
Parser
(Maybe POSIX
-> Maybe Text -> Maybe Text -> Maybe POSIX -> InsightSummary)
-> Parser (Maybe POSIX)
-> Parser
(Maybe Text -> Maybe Text -> Maybe POSIX -> InsightSummary)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe POSIX)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"EndTime")
Parser (Maybe Text -> Maybe Text -> Maybe POSIX -> InsightSummary)
-> Parser (Maybe Text)
-> Parser (Maybe Text -> Maybe POSIX -> InsightSummary)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"GroupARN")
Parser (Maybe Text -> Maybe POSIX -> InsightSummary)
-> Parser (Maybe Text) -> Parser (Maybe POSIX -> InsightSummary)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"GroupName")
Parser (Maybe POSIX -> InsightSummary)
-> Parser (Maybe POSIX) -> Parser InsightSummary
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe POSIX)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"LastUpdateTime")
)
instance Prelude.Hashable InsightSummary
instance Prelude.NFData InsightSummary