{-# 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 #-}

-- Derived from AWS service descriptions, licensed under Apache 2.0.

-- |
-- Module      : Amazonka.LookoutMetrics.DescribeMetricSet
-- Copyright   : (c) 2013-2021 Brendan Hay
-- License     : Mozilla Public License, v. 2.0.
-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>
-- Stability   : auto-generated
-- Portability : non-portable (GHC extensions)
--
-- Describes a dataset.
--
-- Amazon Lookout for Metrics API actions are eventually consistent. If you
-- do a read operation on a resource immediately after creating or
-- modifying it, use retries to allow time for the write operation to
-- complete.
module Amazonka.LookoutMetrics.DescribeMetricSet
  ( -- * Creating a Request
    DescribeMetricSet (..),
    newDescribeMetricSet,

    -- * Request Lenses
    describeMetricSet_metricSetArn,

    -- * Destructuring the Response
    DescribeMetricSetResponse (..),
    newDescribeMetricSetResponse,

    -- * Response Lenses
    describeMetricSetResponse_creationTime,
    describeMetricSetResponse_dimensionList,
    describeMetricSetResponse_offset,
    describeMetricSetResponse_timestampColumn,
    describeMetricSetResponse_metricList,
    describeMetricSetResponse_anomalyDetectorArn,
    describeMetricSetResponse_metricSource,
    describeMetricSetResponse_metricSetName,
    describeMetricSetResponse_metricSetFrequency,
    describeMetricSetResponse_metricSetDescription,
    describeMetricSetResponse_timezone,
    describeMetricSetResponse_metricSetArn,
    describeMetricSetResponse_lastModificationTime,
    describeMetricSetResponse_httpStatus,
  )
where

import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import Amazonka.LookoutMetrics.Types
import qualified Amazonka.Prelude as Prelude
import qualified Amazonka.Request as Request
import qualified Amazonka.Response as Response

-- | /See:/ 'newDescribeMetricSet' smart constructor.
data DescribeMetricSet = DescribeMetricSet'
  { -- | The ARN of the dataset.
    DescribeMetricSet -> Text
metricSetArn :: Prelude.Text
  }
  deriving (DescribeMetricSet -> DescribeMetricSet -> Bool
(DescribeMetricSet -> DescribeMetricSet -> Bool)
-> (DescribeMetricSet -> DescribeMetricSet -> Bool)
-> Eq DescribeMetricSet
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DescribeMetricSet -> DescribeMetricSet -> Bool
$c/= :: DescribeMetricSet -> DescribeMetricSet -> Bool
== :: DescribeMetricSet -> DescribeMetricSet -> Bool
$c== :: DescribeMetricSet -> DescribeMetricSet -> Bool
Prelude.Eq, ReadPrec [DescribeMetricSet]
ReadPrec DescribeMetricSet
Int -> ReadS DescribeMetricSet
ReadS [DescribeMetricSet]
(Int -> ReadS DescribeMetricSet)
-> ReadS [DescribeMetricSet]
-> ReadPrec DescribeMetricSet
-> ReadPrec [DescribeMetricSet]
-> Read DescribeMetricSet
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DescribeMetricSet]
$creadListPrec :: ReadPrec [DescribeMetricSet]
readPrec :: ReadPrec DescribeMetricSet
$creadPrec :: ReadPrec DescribeMetricSet
readList :: ReadS [DescribeMetricSet]
$creadList :: ReadS [DescribeMetricSet]
readsPrec :: Int -> ReadS DescribeMetricSet
$creadsPrec :: Int -> ReadS DescribeMetricSet
Prelude.Read, Int -> DescribeMetricSet -> ShowS
[DescribeMetricSet] -> ShowS
DescribeMetricSet -> String
(Int -> DescribeMetricSet -> ShowS)
-> (DescribeMetricSet -> String)
-> ([DescribeMetricSet] -> ShowS)
-> Show DescribeMetricSet
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DescribeMetricSet] -> ShowS
$cshowList :: [DescribeMetricSet] -> ShowS
show :: DescribeMetricSet -> String
$cshow :: DescribeMetricSet -> String
showsPrec :: Int -> DescribeMetricSet -> ShowS
$cshowsPrec :: Int -> DescribeMetricSet -> ShowS
Prelude.Show, (forall x. DescribeMetricSet -> Rep DescribeMetricSet x)
-> (forall x. Rep DescribeMetricSet x -> DescribeMetricSet)
-> Generic DescribeMetricSet
forall x. Rep DescribeMetricSet x -> DescribeMetricSet
forall x. DescribeMetricSet -> Rep DescribeMetricSet x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep DescribeMetricSet x -> DescribeMetricSet
$cfrom :: forall x. DescribeMetricSet -> Rep DescribeMetricSet x
Prelude.Generic)

-- |
-- Create a value of 'DescribeMetricSet' with all optional fields omitted.
--
-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.
--
-- The following record fields are available, with the corresponding lenses provided
-- for backwards compatibility:
--
-- 'metricSetArn', 'describeMetricSet_metricSetArn' - The ARN of the dataset.
newDescribeMetricSet ::
  -- | 'metricSetArn'
  Prelude.Text ->
  DescribeMetricSet
newDescribeMetricSet :: Text -> DescribeMetricSet
newDescribeMetricSet Text
pMetricSetArn_ =
  DescribeMetricSet' :: Text -> DescribeMetricSet
DescribeMetricSet' {$sel:metricSetArn:DescribeMetricSet' :: Text
metricSetArn = Text
pMetricSetArn_}

-- | The ARN of the dataset.
describeMetricSet_metricSetArn :: Lens.Lens' DescribeMetricSet Prelude.Text
describeMetricSet_metricSetArn :: (Text -> f Text) -> DescribeMetricSet -> f DescribeMetricSet
describeMetricSet_metricSetArn = (DescribeMetricSet -> Text)
-> (DescribeMetricSet -> Text -> DescribeMetricSet)
-> Lens DescribeMetricSet DescribeMetricSet Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeMetricSet' {Text
metricSetArn :: Text
$sel:metricSetArn:DescribeMetricSet' :: DescribeMetricSet -> Text
metricSetArn} -> Text
metricSetArn) (\s :: DescribeMetricSet
s@DescribeMetricSet' {} Text
a -> DescribeMetricSet
s {$sel:metricSetArn:DescribeMetricSet' :: Text
metricSetArn = Text
a} :: DescribeMetricSet)

instance Core.AWSRequest DescribeMetricSet where
  type
    AWSResponse DescribeMetricSet =
      DescribeMetricSetResponse
  request :: DescribeMetricSet -> Request DescribeMetricSet
request = Service -> DescribeMetricSet -> Request DescribeMetricSet
forall a. (ToRequest a, ToJSON a) => Service -> a -> Request a
Request.postJSON Service
defaultService
  response :: Logger
-> Service
-> Proxy DescribeMetricSet
-> ClientResponse ClientBody
-> m (Either
        Error (ClientResponse (AWSResponse DescribeMetricSet)))
response =
    (Int
 -> ResponseHeaders
 -> Object
 -> Either String (AWSResponse DescribeMetricSet))
-> Logger
-> Service
-> Proxy DescribeMetricSet
-> ClientResponse ClientBody
-> m (Either
        Error (ClientResponse (AWSResponse DescribeMetricSet)))
forall (m :: * -> *) a.
MonadResource m =>
(Int -> ResponseHeaders -> Object -> Either String (AWSResponse a))
-> Logger
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveJSON
      ( \Int
s ResponseHeaders
h Object
x ->
          Maybe POSIX
-> Maybe (NonEmpty Text)
-> Maybe Natural
-> Maybe TimestampColumn
-> Maybe (NonEmpty Metric)
-> Maybe Text
-> Maybe MetricSource
-> Maybe Text
-> Maybe Frequency
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> Int
-> DescribeMetricSetResponse
DescribeMetricSetResponse'
            (Maybe POSIX
 -> Maybe (NonEmpty Text)
 -> Maybe Natural
 -> Maybe TimestampColumn
 -> Maybe (NonEmpty Metric)
 -> Maybe Text
 -> Maybe MetricSource
 -> Maybe Text
 -> Maybe Frequency
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe POSIX
 -> Int
 -> DescribeMetricSetResponse)
-> Either String (Maybe POSIX)
-> Either
     String
     (Maybe (NonEmpty Text)
      -> Maybe Natural
      -> Maybe TimestampColumn
      -> Maybe (NonEmpty Metric)
      -> Maybe Text
      -> Maybe MetricSource
      -> Maybe Text
      -> Maybe Frequency
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe POSIX
      -> Int
      -> DescribeMetricSetResponse)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Either String (Maybe POSIX)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"CreationTime")
            Either
  String
  (Maybe (NonEmpty Text)
   -> Maybe Natural
   -> Maybe TimestampColumn
   -> Maybe (NonEmpty Metric)
   -> Maybe Text
   -> Maybe MetricSource
   -> Maybe Text
   -> Maybe Frequency
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe POSIX
   -> Int
   -> DescribeMetricSetResponse)
-> Either String (Maybe (NonEmpty Text))
-> Either
     String
     (Maybe Natural
      -> Maybe TimestampColumn
      -> Maybe (NonEmpty Metric)
      -> Maybe Text
      -> Maybe MetricSource
      -> Maybe Text
      -> Maybe Frequency
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe POSIX
      -> Int
      -> DescribeMetricSetResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe (NonEmpty Text))
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"DimensionList")
            Either
  String
  (Maybe Natural
   -> Maybe TimestampColumn
   -> Maybe (NonEmpty Metric)
   -> Maybe Text
   -> Maybe MetricSource
   -> Maybe Text
   -> Maybe Frequency
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe POSIX
   -> Int
   -> DescribeMetricSetResponse)
-> Either String (Maybe Natural)
-> Either
     String
     (Maybe TimestampColumn
      -> Maybe (NonEmpty Metric)
      -> Maybe Text
      -> Maybe MetricSource
      -> Maybe Text
      -> Maybe Frequency
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe POSIX
      -> Int
      -> DescribeMetricSetResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe Natural)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"Offset")
            Either
  String
  (Maybe TimestampColumn
   -> Maybe (NonEmpty Metric)
   -> Maybe Text
   -> Maybe MetricSource
   -> Maybe Text
   -> Maybe Frequency
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe POSIX
   -> Int
   -> DescribeMetricSetResponse)
-> Either String (Maybe TimestampColumn)
-> Either
     String
     (Maybe (NonEmpty Metric)
      -> Maybe Text
      -> Maybe MetricSource
      -> Maybe Text
      -> Maybe Frequency
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe POSIX
      -> Int
      -> DescribeMetricSetResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe TimestampColumn)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"TimestampColumn")
            Either
  String
  (Maybe (NonEmpty Metric)
   -> Maybe Text
   -> Maybe MetricSource
   -> Maybe Text
   -> Maybe Frequency
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe POSIX
   -> Int
   -> DescribeMetricSetResponse)
-> Either String (Maybe (NonEmpty Metric))
-> Either
     String
     (Maybe Text
      -> Maybe MetricSource
      -> Maybe Text
      -> Maybe Frequency
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe POSIX
      -> Int
      -> DescribeMetricSetResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe (NonEmpty Metric))
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"MetricList")
            Either
  String
  (Maybe Text
   -> Maybe MetricSource
   -> Maybe Text
   -> Maybe Frequency
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe POSIX
   -> Int
   -> DescribeMetricSetResponse)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe MetricSource
      -> Maybe Text
      -> Maybe Frequency
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe POSIX
      -> Int
      -> DescribeMetricSetResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe Text)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"AnomalyDetectorArn")
            Either
  String
  (Maybe MetricSource
   -> Maybe Text
   -> Maybe Frequency
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe POSIX
   -> Int
   -> DescribeMetricSetResponse)
-> Either String (Maybe MetricSource)
-> Either
     String
     (Maybe Text
      -> Maybe Frequency
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe POSIX
      -> Int
      -> DescribeMetricSetResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe MetricSource)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"MetricSource")
            Either
  String
  (Maybe Text
   -> Maybe Frequency
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe POSIX
   -> Int
   -> DescribeMetricSetResponse)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe Frequency
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe POSIX
      -> Int
      -> DescribeMetricSetResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe Text)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"MetricSetName")
            Either
  String
  (Maybe Frequency
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe POSIX
   -> Int
   -> DescribeMetricSetResponse)
-> Either String (Maybe Frequency)
-> Either
     String
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe POSIX
      -> Int
      -> DescribeMetricSetResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe Frequency)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"MetricSetFrequency")
            Either
  String
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe POSIX
   -> Int
   -> DescribeMetricSetResponse)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe Text
      -> Maybe Text -> Maybe POSIX -> Int -> DescribeMetricSetResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe Text)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"MetricSetDescription")
            Either
  String
  (Maybe Text
   -> Maybe Text -> Maybe POSIX -> Int -> DescribeMetricSetResponse)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe Text -> Maybe POSIX -> Int -> DescribeMetricSetResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe Text)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"Timezone")
            Either
  String
  (Maybe Text -> Maybe POSIX -> Int -> DescribeMetricSetResponse)
-> Either String (Maybe Text)
-> Either String (Maybe POSIX -> Int -> DescribeMetricSetResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe Text)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"MetricSetArn")
            Either String (Maybe POSIX -> Int -> DescribeMetricSetResponse)
-> Either String (Maybe POSIX)
-> Either String (Int -> DescribeMetricSetResponse)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Either String (Maybe POSIX)
forall a. FromJSON a => Object -> Text -> Either String (Maybe a)
Core..?> Text
"LastModificationTime")
            Either String (Int -> DescribeMetricSetResponse)
-> Either String Int -> Either String DescribeMetricSetResponse
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Int -> Either String Int
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure (Int -> Int
forall a. Enum a => a -> Int
Prelude.fromEnum Int
s))
      )

instance Prelude.Hashable DescribeMetricSet

instance Prelude.NFData DescribeMetricSet

instance Core.ToHeaders DescribeMetricSet where
  toHeaders :: DescribeMetricSet -> ResponseHeaders
toHeaders =
    ResponseHeaders -> DescribeMetricSet -> ResponseHeaders
forall a b. a -> b -> a
Prelude.const
      ( [ResponseHeaders] -> ResponseHeaders
forall a. Monoid a => [a] -> a
Prelude.mconcat
          [ HeaderName
"Content-Type"
              HeaderName -> ByteString -> ResponseHeaders
forall a. ToHeader a => HeaderName -> a -> ResponseHeaders
Core.=# ( ByteString
"application/x-amz-json-1.1" ::
                          Prelude.ByteString
                      )
          ]
      )

instance Core.ToJSON DescribeMetricSet where
  toJSON :: DescribeMetricSet -> Value
toJSON DescribeMetricSet' {Text
metricSetArn :: Text
$sel:metricSetArn:DescribeMetricSet' :: DescribeMetricSet -> Text
..} =
    [Pair] -> Value
Core.object
      ( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
          [Pair -> Maybe Pair
forall a. a -> Maybe a
Prelude.Just (Text
"MetricSetArn" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..= Text
metricSetArn)]
      )

instance Core.ToPath DescribeMetricSet where
  toPath :: DescribeMetricSet -> ByteString
toPath = ByteString -> DescribeMetricSet -> ByteString
forall a b. a -> b -> a
Prelude.const ByteString
"/DescribeMetricSet"

instance Core.ToQuery DescribeMetricSet where
  toQuery :: DescribeMetricSet -> QueryString
toQuery = QueryString -> DescribeMetricSet -> QueryString
forall a b. a -> b -> a
Prelude.const QueryString
forall a. Monoid a => a
Prelude.mempty

-- | /See:/ 'newDescribeMetricSetResponse' smart constructor.
data DescribeMetricSetResponse = DescribeMetricSetResponse'
  { -- | The time at which the dataset was created.
    DescribeMetricSetResponse -> Maybe POSIX
creationTime :: Prelude.Maybe Core.POSIX,
    -- | A list of the dimensions chosen for analysis.
    DescribeMetricSetResponse -> Maybe (NonEmpty Text)
dimensionList :: Prelude.Maybe (Prelude.NonEmpty Prelude.Text),
    -- | The offset in seconds. Only supported for S3 and Redshift datasources.
    DescribeMetricSetResponse -> Maybe Natural
offset :: Prelude.Maybe Prelude.Natural,
    -- | Contains information about the column used for tracking time in your
    -- source data.
    DescribeMetricSetResponse -> Maybe TimestampColumn
timestampColumn :: Prelude.Maybe TimestampColumn,
    -- | A list of the metrics defined by the dataset.
    DescribeMetricSetResponse -> Maybe (NonEmpty Metric)
metricList :: Prelude.Maybe (Prelude.NonEmpty Metric),
    -- | The ARN of the detector that contains the dataset.
    DescribeMetricSetResponse -> Maybe Text
anomalyDetectorArn :: Prelude.Maybe Prelude.Text,
    -- | Contains information about the dataset\'s source data.
    DescribeMetricSetResponse -> Maybe MetricSource
metricSource :: Prelude.Maybe MetricSource,
    -- | The name of the dataset.
    DescribeMetricSetResponse -> Maybe Text
metricSetName :: Prelude.Maybe Prelude.Text,
    -- | The interval at which the data will be analyzed for anomalies.
    DescribeMetricSetResponse -> Maybe Frequency
metricSetFrequency :: Prelude.Maybe Frequency,
    -- | The dataset\'s description.
    DescribeMetricSetResponse -> Maybe Text
metricSetDescription :: Prelude.Maybe Prelude.Text,
    -- | The time zone in which the dataset\'s data was recorded.
    DescribeMetricSetResponse -> Maybe Text
timezone :: Prelude.Maybe Prelude.Text,
    -- | The ARN of the dataset.
    DescribeMetricSetResponse -> Maybe Text
metricSetArn :: Prelude.Maybe Prelude.Text,
    -- | The time at which the dataset was last modified.
    DescribeMetricSetResponse -> Maybe POSIX
lastModificationTime :: Prelude.Maybe Core.POSIX,
    -- | The response's http status code.
    DescribeMetricSetResponse -> Int
httpStatus :: Prelude.Int
  }
  deriving (DescribeMetricSetResponse -> DescribeMetricSetResponse -> Bool
(DescribeMetricSetResponse -> DescribeMetricSetResponse -> Bool)
-> (DescribeMetricSetResponse -> DescribeMetricSetResponse -> Bool)
-> Eq DescribeMetricSetResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DescribeMetricSetResponse -> DescribeMetricSetResponse -> Bool
$c/= :: DescribeMetricSetResponse -> DescribeMetricSetResponse -> Bool
== :: DescribeMetricSetResponse -> DescribeMetricSetResponse -> Bool
$c== :: DescribeMetricSetResponse -> DescribeMetricSetResponse -> Bool
Prelude.Eq, ReadPrec [DescribeMetricSetResponse]
ReadPrec DescribeMetricSetResponse
Int -> ReadS DescribeMetricSetResponse
ReadS [DescribeMetricSetResponse]
(Int -> ReadS DescribeMetricSetResponse)
-> ReadS [DescribeMetricSetResponse]
-> ReadPrec DescribeMetricSetResponse
-> ReadPrec [DescribeMetricSetResponse]
-> Read DescribeMetricSetResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DescribeMetricSetResponse]
$creadListPrec :: ReadPrec [DescribeMetricSetResponse]
readPrec :: ReadPrec DescribeMetricSetResponse
$creadPrec :: ReadPrec DescribeMetricSetResponse
readList :: ReadS [DescribeMetricSetResponse]
$creadList :: ReadS [DescribeMetricSetResponse]
readsPrec :: Int -> ReadS DescribeMetricSetResponse
$creadsPrec :: Int -> ReadS DescribeMetricSetResponse
Prelude.Read, Int -> DescribeMetricSetResponse -> ShowS
[DescribeMetricSetResponse] -> ShowS
DescribeMetricSetResponse -> String
(Int -> DescribeMetricSetResponse -> ShowS)
-> (DescribeMetricSetResponse -> String)
-> ([DescribeMetricSetResponse] -> ShowS)
-> Show DescribeMetricSetResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DescribeMetricSetResponse] -> ShowS
$cshowList :: [DescribeMetricSetResponse] -> ShowS
show :: DescribeMetricSetResponse -> String
$cshow :: DescribeMetricSetResponse -> String
showsPrec :: Int -> DescribeMetricSetResponse -> ShowS
$cshowsPrec :: Int -> DescribeMetricSetResponse -> ShowS
Prelude.Show, (forall x.
 DescribeMetricSetResponse -> Rep DescribeMetricSetResponse x)
-> (forall x.
    Rep DescribeMetricSetResponse x -> DescribeMetricSetResponse)
-> Generic DescribeMetricSetResponse
forall x.
Rep DescribeMetricSetResponse x -> DescribeMetricSetResponse
forall x.
DescribeMetricSetResponse -> Rep DescribeMetricSetResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep DescribeMetricSetResponse x -> DescribeMetricSetResponse
$cfrom :: forall x.
DescribeMetricSetResponse -> Rep DescribeMetricSetResponse x
Prelude.Generic)

-- |
-- Create a value of 'DescribeMetricSetResponse' with all optional fields omitted.
--
-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.
--
-- The following record fields are available, with the corresponding lenses provided
-- for backwards compatibility:
--
-- 'creationTime', 'describeMetricSetResponse_creationTime' - The time at which the dataset was created.
--
-- 'dimensionList', 'describeMetricSetResponse_dimensionList' - A list of the dimensions chosen for analysis.
--
-- 'offset', 'describeMetricSetResponse_offset' - The offset in seconds. Only supported for S3 and Redshift datasources.
--
-- 'timestampColumn', 'describeMetricSetResponse_timestampColumn' - Contains information about the column used for tracking time in your
-- source data.
--
-- 'metricList', 'describeMetricSetResponse_metricList' - A list of the metrics defined by the dataset.
--
-- 'anomalyDetectorArn', 'describeMetricSetResponse_anomalyDetectorArn' - The ARN of the detector that contains the dataset.
--
-- 'metricSource', 'describeMetricSetResponse_metricSource' - Contains information about the dataset\'s source data.
--
-- 'metricSetName', 'describeMetricSetResponse_metricSetName' - The name of the dataset.
--
-- 'metricSetFrequency', 'describeMetricSetResponse_metricSetFrequency' - The interval at which the data will be analyzed for anomalies.
--
-- 'metricSetDescription', 'describeMetricSetResponse_metricSetDescription' - The dataset\'s description.
--
-- 'timezone', 'describeMetricSetResponse_timezone' - The time zone in which the dataset\'s data was recorded.
--
-- 'metricSetArn', 'describeMetricSetResponse_metricSetArn' - The ARN of the dataset.
--
-- 'lastModificationTime', 'describeMetricSetResponse_lastModificationTime' - The time at which the dataset was last modified.
--
-- 'httpStatus', 'describeMetricSetResponse_httpStatus' - The response's http status code.
newDescribeMetricSetResponse ::
  -- | 'httpStatus'
  Prelude.Int ->
  DescribeMetricSetResponse
newDescribeMetricSetResponse :: Int -> DescribeMetricSetResponse
newDescribeMetricSetResponse Int
pHttpStatus_ =
  DescribeMetricSetResponse' :: Maybe POSIX
-> Maybe (NonEmpty Text)
-> Maybe Natural
-> Maybe TimestampColumn
-> Maybe (NonEmpty Metric)
-> Maybe Text
-> Maybe MetricSource
-> Maybe Text
-> Maybe Frequency
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> Int
-> DescribeMetricSetResponse
DescribeMetricSetResponse'
    { $sel:creationTime:DescribeMetricSetResponse' :: Maybe POSIX
creationTime =
        Maybe POSIX
forall a. Maybe a
Prelude.Nothing,
      $sel:dimensionList:DescribeMetricSetResponse' :: Maybe (NonEmpty Text)
dimensionList = Maybe (NonEmpty Text)
forall a. Maybe a
Prelude.Nothing,
      $sel:offset:DescribeMetricSetResponse' :: Maybe Natural
offset = Maybe Natural
forall a. Maybe a
Prelude.Nothing,
      $sel:timestampColumn:DescribeMetricSetResponse' :: Maybe TimestampColumn
timestampColumn = Maybe TimestampColumn
forall a. Maybe a
Prelude.Nothing,
      $sel:metricList:DescribeMetricSetResponse' :: Maybe (NonEmpty Metric)
metricList = Maybe (NonEmpty Metric)
forall a. Maybe a
Prelude.Nothing,
      $sel:anomalyDetectorArn:DescribeMetricSetResponse' :: Maybe Text
anomalyDetectorArn = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:metricSource:DescribeMetricSetResponse' :: Maybe MetricSource
metricSource = Maybe MetricSource
forall a. Maybe a
Prelude.Nothing,
      $sel:metricSetName:DescribeMetricSetResponse' :: Maybe Text
metricSetName = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:metricSetFrequency:DescribeMetricSetResponse' :: Maybe Frequency
metricSetFrequency = Maybe Frequency
forall a. Maybe a
Prelude.Nothing,
      $sel:metricSetDescription:DescribeMetricSetResponse' :: Maybe Text
metricSetDescription = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:timezone:DescribeMetricSetResponse' :: Maybe Text
timezone = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:metricSetArn:DescribeMetricSetResponse' :: Maybe Text
metricSetArn = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:lastModificationTime:DescribeMetricSetResponse' :: Maybe POSIX
lastModificationTime = Maybe POSIX
forall a. Maybe a
Prelude.Nothing,
      $sel:httpStatus:DescribeMetricSetResponse' :: Int
httpStatus = Int
pHttpStatus_
    }

-- | The time at which the dataset was created.
describeMetricSetResponse_creationTime :: Lens.Lens' DescribeMetricSetResponse (Prelude.Maybe Prelude.UTCTime)
describeMetricSetResponse_creationTime :: (Maybe UTCTime -> f (Maybe UTCTime))
-> DescribeMetricSetResponse -> f DescribeMetricSetResponse
describeMetricSetResponse_creationTime = (DescribeMetricSetResponse -> Maybe POSIX)
-> (DescribeMetricSetResponse
    -> Maybe POSIX -> DescribeMetricSetResponse)
-> Lens
     DescribeMetricSetResponse
     DescribeMetricSetResponse
     (Maybe POSIX)
     (Maybe POSIX)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeMetricSetResponse' {Maybe POSIX
creationTime :: Maybe POSIX
$sel:creationTime:DescribeMetricSetResponse' :: DescribeMetricSetResponse -> Maybe POSIX
creationTime} -> Maybe POSIX
creationTime) (\s :: DescribeMetricSetResponse
s@DescribeMetricSetResponse' {} Maybe POSIX
a -> DescribeMetricSetResponse
s {$sel:creationTime:DescribeMetricSetResponse' :: Maybe POSIX
creationTime = Maybe POSIX
a} :: DescribeMetricSetResponse) ((Maybe POSIX -> f (Maybe POSIX))
 -> DescribeMetricSetResponse -> f DescribeMetricSetResponse)
-> ((Maybe UTCTime -> f (Maybe UTCTime))
    -> Maybe POSIX -> f (Maybe POSIX))
-> (Maybe UTCTime -> f (Maybe UTCTime))
-> DescribeMetricSetResponse
-> f DescribeMetricSetResponse
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

-- | A list of the dimensions chosen for analysis.
describeMetricSetResponse_dimensionList :: Lens.Lens' DescribeMetricSetResponse (Prelude.Maybe (Prelude.NonEmpty Prelude.Text))
describeMetricSetResponse_dimensionList :: (Maybe (NonEmpty Text) -> f (Maybe (NonEmpty Text)))
-> DescribeMetricSetResponse -> f DescribeMetricSetResponse
describeMetricSetResponse_dimensionList = (DescribeMetricSetResponse -> Maybe (NonEmpty Text))
-> (DescribeMetricSetResponse
    -> Maybe (NonEmpty Text) -> DescribeMetricSetResponse)
-> Lens
     DescribeMetricSetResponse
     DescribeMetricSetResponse
     (Maybe (NonEmpty Text))
     (Maybe (NonEmpty Text))
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeMetricSetResponse' {Maybe (NonEmpty Text)
dimensionList :: Maybe (NonEmpty Text)
$sel:dimensionList:DescribeMetricSetResponse' :: DescribeMetricSetResponse -> Maybe (NonEmpty Text)
dimensionList} -> Maybe (NonEmpty Text)
dimensionList) (\s :: DescribeMetricSetResponse
s@DescribeMetricSetResponse' {} Maybe (NonEmpty Text)
a -> DescribeMetricSetResponse
s {$sel:dimensionList:DescribeMetricSetResponse' :: Maybe (NonEmpty Text)
dimensionList = Maybe (NonEmpty Text)
a} :: DescribeMetricSetResponse) ((Maybe (NonEmpty Text) -> f (Maybe (NonEmpty Text)))
 -> DescribeMetricSetResponse -> f DescribeMetricSetResponse)
-> ((Maybe (NonEmpty Text) -> f (Maybe (NonEmpty Text)))
    -> Maybe (NonEmpty Text) -> f (Maybe (NonEmpty Text)))
-> (Maybe (NonEmpty Text) -> f (Maybe (NonEmpty Text)))
-> DescribeMetricSetResponse
-> f DescribeMetricSetResponse
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
  (NonEmpty Text) (NonEmpty Text) (NonEmpty Text) (NonEmpty Text)
-> Iso
     (Maybe (NonEmpty Text))
     (Maybe (NonEmpty Text))
     (Maybe (NonEmpty Text))
     (Maybe (NonEmpty Text))
forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping AnIso
  (NonEmpty Text) (NonEmpty Text) (NonEmpty Text) (NonEmpty Text)
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | The offset in seconds. Only supported for S3 and Redshift datasources.
describeMetricSetResponse_offset :: Lens.Lens' DescribeMetricSetResponse (Prelude.Maybe Prelude.Natural)
describeMetricSetResponse_offset :: (Maybe Natural -> f (Maybe Natural))
-> DescribeMetricSetResponse -> f DescribeMetricSetResponse
describeMetricSetResponse_offset = (DescribeMetricSetResponse -> Maybe Natural)
-> (DescribeMetricSetResponse
    -> Maybe Natural -> DescribeMetricSetResponse)
-> Lens
     DescribeMetricSetResponse
     DescribeMetricSetResponse
     (Maybe Natural)
     (Maybe Natural)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeMetricSetResponse' {Maybe Natural
offset :: Maybe Natural
$sel:offset:DescribeMetricSetResponse' :: DescribeMetricSetResponse -> Maybe Natural
offset} -> Maybe Natural
offset) (\s :: DescribeMetricSetResponse
s@DescribeMetricSetResponse' {} Maybe Natural
a -> DescribeMetricSetResponse
s {$sel:offset:DescribeMetricSetResponse' :: Maybe Natural
offset = Maybe Natural
a} :: DescribeMetricSetResponse)

-- | Contains information about the column used for tracking time in your
-- source data.
describeMetricSetResponse_timestampColumn :: Lens.Lens' DescribeMetricSetResponse (Prelude.Maybe TimestampColumn)
describeMetricSetResponse_timestampColumn :: (Maybe TimestampColumn -> f (Maybe TimestampColumn))
-> DescribeMetricSetResponse -> f DescribeMetricSetResponse
describeMetricSetResponse_timestampColumn = (DescribeMetricSetResponse -> Maybe TimestampColumn)
-> (DescribeMetricSetResponse
    -> Maybe TimestampColumn -> DescribeMetricSetResponse)
-> Lens
     DescribeMetricSetResponse
     DescribeMetricSetResponse
     (Maybe TimestampColumn)
     (Maybe TimestampColumn)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeMetricSetResponse' {Maybe TimestampColumn
timestampColumn :: Maybe TimestampColumn
$sel:timestampColumn:DescribeMetricSetResponse' :: DescribeMetricSetResponse -> Maybe TimestampColumn
timestampColumn} -> Maybe TimestampColumn
timestampColumn) (\s :: DescribeMetricSetResponse
s@DescribeMetricSetResponse' {} Maybe TimestampColumn
a -> DescribeMetricSetResponse
s {$sel:timestampColumn:DescribeMetricSetResponse' :: Maybe TimestampColumn
timestampColumn = Maybe TimestampColumn
a} :: DescribeMetricSetResponse)

-- | A list of the metrics defined by the dataset.
describeMetricSetResponse_metricList :: Lens.Lens' DescribeMetricSetResponse (Prelude.Maybe (Prelude.NonEmpty Metric))
describeMetricSetResponse_metricList :: (Maybe (NonEmpty Metric) -> f (Maybe (NonEmpty Metric)))
-> DescribeMetricSetResponse -> f DescribeMetricSetResponse
describeMetricSetResponse_metricList = (DescribeMetricSetResponse -> Maybe (NonEmpty Metric))
-> (DescribeMetricSetResponse
    -> Maybe (NonEmpty Metric) -> DescribeMetricSetResponse)
-> Lens
     DescribeMetricSetResponse
     DescribeMetricSetResponse
     (Maybe (NonEmpty Metric))
     (Maybe (NonEmpty Metric))
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeMetricSetResponse' {Maybe (NonEmpty Metric)
metricList :: Maybe (NonEmpty Metric)
$sel:metricList:DescribeMetricSetResponse' :: DescribeMetricSetResponse -> Maybe (NonEmpty Metric)
metricList} -> Maybe (NonEmpty Metric)
metricList) (\s :: DescribeMetricSetResponse
s@DescribeMetricSetResponse' {} Maybe (NonEmpty Metric)
a -> DescribeMetricSetResponse
s {$sel:metricList:DescribeMetricSetResponse' :: Maybe (NonEmpty Metric)
metricList = Maybe (NonEmpty Metric)
a} :: DescribeMetricSetResponse) ((Maybe (NonEmpty Metric) -> f (Maybe (NonEmpty Metric)))
 -> DescribeMetricSetResponse -> f DescribeMetricSetResponse)
-> ((Maybe (NonEmpty Metric) -> f (Maybe (NonEmpty Metric)))
    -> Maybe (NonEmpty Metric) -> f (Maybe (NonEmpty Metric)))
-> (Maybe (NonEmpty Metric) -> f (Maybe (NonEmpty Metric)))
-> DescribeMetricSetResponse
-> f DescribeMetricSetResponse
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
  (NonEmpty Metric)
  (NonEmpty Metric)
  (NonEmpty Metric)
  (NonEmpty Metric)
-> Iso
     (Maybe (NonEmpty Metric))
     (Maybe (NonEmpty Metric))
     (Maybe (NonEmpty Metric))
     (Maybe (NonEmpty Metric))
forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping AnIso
  (NonEmpty Metric)
  (NonEmpty Metric)
  (NonEmpty Metric)
  (NonEmpty Metric)
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | The ARN of the detector that contains the dataset.
describeMetricSetResponse_anomalyDetectorArn :: Lens.Lens' DescribeMetricSetResponse (Prelude.Maybe Prelude.Text)
describeMetricSetResponse_anomalyDetectorArn :: (Maybe Text -> f (Maybe Text))
-> DescribeMetricSetResponse -> f DescribeMetricSetResponse
describeMetricSetResponse_anomalyDetectorArn = (DescribeMetricSetResponse -> Maybe Text)
-> (DescribeMetricSetResponse
    -> Maybe Text -> DescribeMetricSetResponse)
-> Lens
     DescribeMetricSetResponse
     DescribeMetricSetResponse
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeMetricSetResponse' {Maybe Text
anomalyDetectorArn :: Maybe Text
$sel:anomalyDetectorArn:DescribeMetricSetResponse' :: DescribeMetricSetResponse -> Maybe Text
anomalyDetectorArn} -> Maybe Text
anomalyDetectorArn) (\s :: DescribeMetricSetResponse
s@DescribeMetricSetResponse' {} Maybe Text
a -> DescribeMetricSetResponse
s {$sel:anomalyDetectorArn:DescribeMetricSetResponse' :: Maybe Text
anomalyDetectorArn = Maybe Text
a} :: DescribeMetricSetResponse)

-- | Contains information about the dataset\'s source data.
describeMetricSetResponse_metricSource :: Lens.Lens' DescribeMetricSetResponse (Prelude.Maybe MetricSource)
describeMetricSetResponse_metricSource :: (Maybe MetricSource -> f (Maybe MetricSource))
-> DescribeMetricSetResponse -> f DescribeMetricSetResponse
describeMetricSetResponse_metricSource = (DescribeMetricSetResponse -> Maybe MetricSource)
-> (DescribeMetricSetResponse
    -> Maybe MetricSource -> DescribeMetricSetResponse)
-> Lens
     DescribeMetricSetResponse
     DescribeMetricSetResponse
     (Maybe MetricSource)
     (Maybe MetricSource)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeMetricSetResponse' {Maybe MetricSource
metricSource :: Maybe MetricSource
$sel:metricSource:DescribeMetricSetResponse' :: DescribeMetricSetResponse -> Maybe MetricSource
metricSource} -> Maybe MetricSource
metricSource) (\s :: DescribeMetricSetResponse
s@DescribeMetricSetResponse' {} Maybe MetricSource
a -> DescribeMetricSetResponse
s {$sel:metricSource:DescribeMetricSetResponse' :: Maybe MetricSource
metricSource = Maybe MetricSource
a} :: DescribeMetricSetResponse)

-- | The name of the dataset.
describeMetricSetResponse_metricSetName :: Lens.Lens' DescribeMetricSetResponse (Prelude.Maybe Prelude.Text)
describeMetricSetResponse_metricSetName :: (Maybe Text -> f (Maybe Text))
-> DescribeMetricSetResponse -> f DescribeMetricSetResponse
describeMetricSetResponse_metricSetName = (DescribeMetricSetResponse -> Maybe Text)
-> (DescribeMetricSetResponse
    -> Maybe Text -> DescribeMetricSetResponse)
-> Lens
     DescribeMetricSetResponse
     DescribeMetricSetResponse
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeMetricSetResponse' {Maybe Text
metricSetName :: Maybe Text
$sel:metricSetName:DescribeMetricSetResponse' :: DescribeMetricSetResponse -> Maybe Text
metricSetName} -> Maybe Text
metricSetName) (\s :: DescribeMetricSetResponse
s@DescribeMetricSetResponse' {} Maybe Text
a -> DescribeMetricSetResponse
s {$sel:metricSetName:DescribeMetricSetResponse' :: Maybe Text
metricSetName = Maybe Text
a} :: DescribeMetricSetResponse)

-- | The interval at which the data will be analyzed for anomalies.
describeMetricSetResponse_metricSetFrequency :: Lens.Lens' DescribeMetricSetResponse (Prelude.Maybe Frequency)
describeMetricSetResponse_metricSetFrequency :: (Maybe Frequency -> f (Maybe Frequency))
-> DescribeMetricSetResponse -> f DescribeMetricSetResponse
describeMetricSetResponse_metricSetFrequency = (DescribeMetricSetResponse -> Maybe Frequency)
-> (DescribeMetricSetResponse
    -> Maybe Frequency -> DescribeMetricSetResponse)
-> Lens
     DescribeMetricSetResponse
     DescribeMetricSetResponse
     (Maybe Frequency)
     (Maybe Frequency)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeMetricSetResponse' {Maybe Frequency
metricSetFrequency :: Maybe Frequency
$sel:metricSetFrequency:DescribeMetricSetResponse' :: DescribeMetricSetResponse -> Maybe Frequency
metricSetFrequency} -> Maybe Frequency
metricSetFrequency) (\s :: DescribeMetricSetResponse
s@DescribeMetricSetResponse' {} Maybe Frequency
a -> DescribeMetricSetResponse
s {$sel:metricSetFrequency:DescribeMetricSetResponse' :: Maybe Frequency
metricSetFrequency = Maybe Frequency
a} :: DescribeMetricSetResponse)

-- | The dataset\'s description.
describeMetricSetResponse_metricSetDescription :: Lens.Lens' DescribeMetricSetResponse (Prelude.Maybe Prelude.Text)
describeMetricSetResponse_metricSetDescription :: (Maybe Text -> f (Maybe Text))
-> DescribeMetricSetResponse -> f DescribeMetricSetResponse
describeMetricSetResponse_metricSetDescription = (DescribeMetricSetResponse -> Maybe Text)
-> (DescribeMetricSetResponse
    -> Maybe Text -> DescribeMetricSetResponse)
-> Lens
     DescribeMetricSetResponse
     DescribeMetricSetResponse
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeMetricSetResponse' {Maybe Text
metricSetDescription :: Maybe Text
$sel:metricSetDescription:DescribeMetricSetResponse' :: DescribeMetricSetResponse -> Maybe Text
metricSetDescription} -> Maybe Text
metricSetDescription) (\s :: DescribeMetricSetResponse
s@DescribeMetricSetResponse' {} Maybe Text
a -> DescribeMetricSetResponse
s {$sel:metricSetDescription:DescribeMetricSetResponse' :: Maybe Text
metricSetDescription = Maybe Text
a} :: DescribeMetricSetResponse)

-- | The time zone in which the dataset\'s data was recorded.
describeMetricSetResponse_timezone :: Lens.Lens' DescribeMetricSetResponse (Prelude.Maybe Prelude.Text)
describeMetricSetResponse_timezone :: (Maybe Text -> f (Maybe Text))
-> DescribeMetricSetResponse -> f DescribeMetricSetResponse
describeMetricSetResponse_timezone = (DescribeMetricSetResponse -> Maybe Text)
-> (DescribeMetricSetResponse
    -> Maybe Text -> DescribeMetricSetResponse)
-> Lens
     DescribeMetricSetResponse
     DescribeMetricSetResponse
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeMetricSetResponse' {Maybe Text
timezone :: Maybe Text
$sel:timezone:DescribeMetricSetResponse' :: DescribeMetricSetResponse -> Maybe Text
timezone} -> Maybe Text
timezone) (\s :: DescribeMetricSetResponse
s@DescribeMetricSetResponse' {} Maybe Text
a -> DescribeMetricSetResponse
s {$sel:timezone:DescribeMetricSetResponse' :: Maybe Text
timezone = Maybe Text
a} :: DescribeMetricSetResponse)

-- | The ARN of the dataset.
describeMetricSetResponse_metricSetArn :: Lens.Lens' DescribeMetricSetResponse (Prelude.Maybe Prelude.Text)
describeMetricSetResponse_metricSetArn :: (Maybe Text -> f (Maybe Text))
-> DescribeMetricSetResponse -> f DescribeMetricSetResponse
describeMetricSetResponse_metricSetArn = (DescribeMetricSetResponse -> Maybe Text)
-> (DescribeMetricSetResponse
    -> Maybe Text -> DescribeMetricSetResponse)
-> Lens
     DescribeMetricSetResponse
     DescribeMetricSetResponse
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeMetricSetResponse' {Maybe Text
metricSetArn :: Maybe Text
$sel:metricSetArn:DescribeMetricSetResponse' :: DescribeMetricSetResponse -> Maybe Text
metricSetArn} -> Maybe Text
metricSetArn) (\s :: DescribeMetricSetResponse
s@DescribeMetricSetResponse' {} Maybe Text
a -> DescribeMetricSetResponse
s {$sel:metricSetArn:DescribeMetricSetResponse' :: Maybe Text
metricSetArn = Maybe Text
a} :: DescribeMetricSetResponse)

-- | The time at which the dataset was last modified.
describeMetricSetResponse_lastModificationTime :: Lens.Lens' DescribeMetricSetResponse (Prelude.Maybe Prelude.UTCTime)
describeMetricSetResponse_lastModificationTime :: (Maybe UTCTime -> f (Maybe UTCTime))
-> DescribeMetricSetResponse -> f DescribeMetricSetResponse
describeMetricSetResponse_lastModificationTime = (DescribeMetricSetResponse -> Maybe POSIX)
-> (DescribeMetricSetResponse
    -> Maybe POSIX -> DescribeMetricSetResponse)
-> Lens
     DescribeMetricSetResponse
     DescribeMetricSetResponse
     (Maybe POSIX)
     (Maybe POSIX)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeMetricSetResponse' {Maybe POSIX
lastModificationTime :: Maybe POSIX
$sel:lastModificationTime:DescribeMetricSetResponse' :: DescribeMetricSetResponse -> Maybe POSIX
lastModificationTime} -> Maybe POSIX
lastModificationTime) (\s :: DescribeMetricSetResponse
s@DescribeMetricSetResponse' {} Maybe POSIX
a -> DescribeMetricSetResponse
s {$sel:lastModificationTime:DescribeMetricSetResponse' :: Maybe POSIX
lastModificationTime = Maybe POSIX
a} :: DescribeMetricSetResponse) ((Maybe POSIX -> f (Maybe POSIX))
 -> DescribeMetricSetResponse -> f DescribeMetricSetResponse)
-> ((Maybe UTCTime -> f (Maybe UTCTime))
    -> Maybe POSIX -> f (Maybe POSIX))
-> (Maybe UTCTime -> f (Maybe UTCTime))
-> DescribeMetricSetResponse
-> f DescribeMetricSetResponse
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

-- | The response's http status code.
describeMetricSetResponse_httpStatus :: Lens.Lens' DescribeMetricSetResponse Prelude.Int
describeMetricSetResponse_httpStatus :: (Int -> f Int)
-> DescribeMetricSetResponse -> f DescribeMetricSetResponse
describeMetricSetResponse_httpStatus = (DescribeMetricSetResponse -> Int)
-> (DescribeMetricSetResponse -> Int -> DescribeMetricSetResponse)
-> Lens DescribeMetricSetResponse DescribeMetricSetResponse Int Int
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DescribeMetricSetResponse' {Int
httpStatus :: Int
$sel:httpStatus:DescribeMetricSetResponse' :: DescribeMetricSetResponse -> Int
httpStatus} -> Int
httpStatus) (\s :: DescribeMetricSetResponse
s@DescribeMetricSetResponse' {} Int
a -> DescribeMetricSetResponse
s {$sel:httpStatus:DescribeMetricSetResponse' :: Int
httpStatus = Int
a} :: DescribeMetricSetResponse)

instance Prelude.NFData DescribeMetricSetResponse