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

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

-- |
-- Module      : Amazonka.Kafka.Types.MutableClusterInfo
-- 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)
module Amazonka.Kafka.Types.MutableClusterInfo where

import qualified Amazonka.Core as Core
import Amazonka.Kafka.Types.BrokerEBSVolumeInfo
import Amazonka.Kafka.Types.ClientAuthentication
import Amazonka.Kafka.Types.ConfigurationInfo
import Amazonka.Kafka.Types.EncryptionInfo
import Amazonka.Kafka.Types.EnhancedMonitoring
import Amazonka.Kafka.Types.LoggingInfo
import Amazonka.Kafka.Types.OpenMonitoring
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude

-- | Information about cluster attributes that can be updated via update
-- APIs.
--
-- /See:/ 'newMutableClusterInfo' smart constructor.
data MutableClusterInfo = MutableClusterInfo'
  { -- | The number of broker nodes in the cluster.
    MutableClusterInfo -> Maybe Int
numberOfBrokerNodes :: Prelude.Maybe Prelude.Int,
    -- | Specifies which Apache Kafka metrics Amazon MSK gathers and sends to
    -- Amazon CloudWatch for this cluster.
    MutableClusterInfo -> Maybe EnhancedMonitoring
enhancedMonitoring :: Prelude.Maybe EnhancedMonitoring,
    -- | The settings for open monitoring.
    MutableClusterInfo -> Maybe OpenMonitoring
openMonitoring :: Prelude.Maybe OpenMonitoring,
    -- | Information about the changes in the configuration of the brokers.
    MutableClusterInfo -> Maybe ConfigurationInfo
configurationInfo :: Prelude.Maybe ConfigurationInfo,
    -- | Information about the Amazon MSK broker type.
    MutableClusterInfo -> Maybe Text
instanceType :: Prelude.Maybe Prelude.Text,
    -- | The Kafka version.
    MutableClusterInfo -> Maybe Text
kafkaVersion :: Prelude.Maybe Prelude.Text,
    -- | You can configure your MSK cluster to send broker logs to different
    -- destination types. This is a container for the configuration details
    -- related to broker logs.
    MutableClusterInfo -> Maybe LoggingInfo
loggingInfo :: Prelude.Maybe LoggingInfo,
    -- | Includes all client authentication information.
    MutableClusterInfo -> Maybe ClientAuthentication
clientAuthentication :: Prelude.Maybe ClientAuthentication,
    -- | Specifies the size of the EBS volume and the ID of the associated
    -- broker.
    MutableClusterInfo -> Maybe [BrokerEBSVolumeInfo]
brokerEBSVolumeInfo :: Prelude.Maybe [BrokerEBSVolumeInfo],
    -- | Includes all encryption-related information.
    MutableClusterInfo -> Maybe EncryptionInfo
encryptionInfo :: Prelude.Maybe EncryptionInfo
  }
  deriving (MutableClusterInfo -> MutableClusterInfo -> Bool
(MutableClusterInfo -> MutableClusterInfo -> Bool)
-> (MutableClusterInfo -> MutableClusterInfo -> Bool)
-> Eq MutableClusterInfo
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: MutableClusterInfo -> MutableClusterInfo -> Bool
$c/= :: MutableClusterInfo -> MutableClusterInfo -> Bool
== :: MutableClusterInfo -> MutableClusterInfo -> Bool
$c== :: MutableClusterInfo -> MutableClusterInfo -> Bool
Prelude.Eq, ReadPrec [MutableClusterInfo]
ReadPrec MutableClusterInfo
Int -> ReadS MutableClusterInfo
ReadS [MutableClusterInfo]
(Int -> ReadS MutableClusterInfo)
-> ReadS [MutableClusterInfo]
-> ReadPrec MutableClusterInfo
-> ReadPrec [MutableClusterInfo]
-> Read MutableClusterInfo
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [MutableClusterInfo]
$creadListPrec :: ReadPrec [MutableClusterInfo]
readPrec :: ReadPrec MutableClusterInfo
$creadPrec :: ReadPrec MutableClusterInfo
readList :: ReadS [MutableClusterInfo]
$creadList :: ReadS [MutableClusterInfo]
readsPrec :: Int -> ReadS MutableClusterInfo
$creadsPrec :: Int -> ReadS MutableClusterInfo
Prelude.Read, Int -> MutableClusterInfo -> ShowS
[MutableClusterInfo] -> ShowS
MutableClusterInfo -> String
(Int -> MutableClusterInfo -> ShowS)
-> (MutableClusterInfo -> String)
-> ([MutableClusterInfo] -> ShowS)
-> Show MutableClusterInfo
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [MutableClusterInfo] -> ShowS
$cshowList :: [MutableClusterInfo] -> ShowS
show :: MutableClusterInfo -> String
$cshow :: MutableClusterInfo -> String
showsPrec :: Int -> MutableClusterInfo -> ShowS
$cshowsPrec :: Int -> MutableClusterInfo -> ShowS
Prelude.Show, (forall x. MutableClusterInfo -> Rep MutableClusterInfo x)
-> (forall x. Rep MutableClusterInfo x -> MutableClusterInfo)
-> Generic MutableClusterInfo
forall x. Rep MutableClusterInfo x -> MutableClusterInfo
forall x. MutableClusterInfo -> Rep MutableClusterInfo x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep MutableClusterInfo x -> MutableClusterInfo
$cfrom :: forall x. MutableClusterInfo -> Rep MutableClusterInfo x
Prelude.Generic)

-- |
-- Create a value of 'MutableClusterInfo' 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:
--
-- 'numberOfBrokerNodes', 'mutableClusterInfo_numberOfBrokerNodes' - The number of broker nodes in the cluster.
--
-- 'enhancedMonitoring', 'mutableClusterInfo_enhancedMonitoring' - Specifies which Apache Kafka metrics Amazon MSK gathers and sends to
-- Amazon CloudWatch for this cluster.
--
-- 'openMonitoring', 'mutableClusterInfo_openMonitoring' - The settings for open monitoring.
--
-- 'configurationInfo', 'mutableClusterInfo_configurationInfo' - Information about the changes in the configuration of the brokers.
--
-- 'instanceType', 'mutableClusterInfo_instanceType' - Information about the Amazon MSK broker type.
--
-- 'kafkaVersion', 'mutableClusterInfo_kafkaVersion' - The Kafka version.
--
-- 'loggingInfo', 'mutableClusterInfo_loggingInfo' - You can configure your MSK cluster to send broker logs to different
-- destination types. This is a container for the configuration details
-- related to broker logs.
--
-- 'clientAuthentication', 'mutableClusterInfo_clientAuthentication' - Includes all client authentication information.
--
-- 'brokerEBSVolumeInfo', 'mutableClusterInfo_brokerEBSVolumeInfo' - Specifies the size of the EBS volume and the ID of the associated
-- broker.
--
-- 'encryptionInfo', 'mutableClusterInfo_encryptionInfo' - Includes all encryption-related information.
newMutableClusterInfo ::
  MutableClusterInfo
newMutableClusterInfo :: MutableClusterInfo
newMutableClusterInfo =
  MutableClusterInfo' :: Maybe Int
-> Maybe EnhancedMonitoring
-> Maybe OpenMonitoring
-> Maybe ConfigurationInfo
-> Maybe Text
-> Maybe Text
-> Maybe LoggingInfo
-> Maybe ClientAuthentication
-> Maybe [BrokerEBSVolumeInfo]
-> Maybe EncryptionInfo
-> MutableClusterInfo
MutableClusterInfo'
    { $sel:numberOfBrokerNodes:MutableClusterInfo' :: Maybe Int
numberOfBrokerNodes =
        Maybe Int
forall a. Maybe a
Prelude.Nothing,
      $sel:enhancedMonitoring:MutableClusterInfo' :: Maybe EnhancedMonitoring
enhancedMonitoring = Maybe EnhancedMonitoring
forall a. Maybe a
Prelude.Nothing,
      $sel:openMonitoring:MutableClusterInfo' :: Maybe OpenMonitoring
openMonitoring = Maybe OpenMonitoring
forall a. Maybe a
Prelude.Nothing,
      $sel:configurationInfo:MutableClusterInfo' :: Maybe ConfigurationInfo
configurationInfo = Maybe ConfigurationInfo
forall a. Maybe a
Prelude.Nothing,
      $sel:instanceType:MutableClusterInfo' :: Maybe Text
instanceType = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:kafkaVersion:MutableClusterInfo' :: Maybe Text
kafkaVersion = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:loggingInfo:MutableClusterInfo' :: Maybe LoggingInfo
loggingInfo = Maybe LoggingInfo
forall a. Maybe a
Prelude.Nothing,
      $sel:clientAuthentication:MutableClusterInfo' :: Maybe ClientAuthentication
clientAuthentication = Maybe ClientAuthentication
forall a. Maybe a
Prelude.Nothing,
      $sel:brokerEBSVolumeInfo:MutableClusterInfo' :: Maybe [BrokerEBSVolumeInfo]
brokerEBSVolumeInfo = Maybe [BrokerEBSVolumeInfo]
forall a. Maybe a
Prelude.Nothing,
      $sel:encryptionInfo:MutableClusterInfo' :: Maybe EncryptionInfo
encryptionInfo = Maybe EncryptionInfo
forall a. Maybe a
Prelude.Nothing
    }

-- | The number of broker nodes in the cluster.
mutableClusterInfo_numberOfBrokerNodes :: Lens.Lens' MutableClusterInfo (Prelude.Maybe Prelude.Int)
mutableClusterInfo_numberOfBrokerNodes :: (Maybe Int -> f (Maybe Int))
-> MutableClusterInfo -> f MutableClusterInfo
mutableClusterInfo_numberOfBrokerNodes = (MutableClusterInfo -> Maybe Int)
-> (MutableClusterInfo -> Maybe Int -> MutableClusterInfo)
-> Lens
     MutableClusterInfo MutableClusterInfo (Maybe Int) (Maybe Int)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\MutableClusterInfo' {Maybe Int
numberOfBrokerNodes :: Maybe Int
$sel:numberOfBrokerNodes:MutableClusterInfo' :: MutableClusterInfo -> Maybe Int
numberOfBrokerNodes} -> Maybe Int
numberOfBrokerNodes) (\s :: MutableClusterInfo
s@MutableClusterInfo' {} Maybe Int
a -> MutableClusterInfo
s {$sel:numberOfBrokerNodes:MutableClusterInfo' :: Maybe Int
numberOfBrokerNodes = Maybe Int
a} :: MutableClusterInfo)

-- | Specifies which Apache Kafka metrics Amazon MSK gathers and sends to
-- Amazon CloudWatch for this cluster.
mutableClusterInfo_enhancedMonitoring :: Lens.Lens' MutableClusterInfo (Prelude.Maybe EnhancedMonitoring)
mutableClusterInfo_enhancedMonitoring :: (Maybe EnhancedMonitoring -> f (Maybe EnhancedMonitoring))
-> MutableClusterInfo -> f MutableClusterInfo
mutableClusterInfo_enhancedMonitoring = (MutableClusterInfo -> Maybe EnhancedMonitoring)
-> (MutableClusterInfo
    -> Maybe EnhancedMonitoring -> MutableClusterInfo)
-> Lens
     MutableClusterInfo
     MutableClusterInfo
     (Maybe EnhancedMonitoring)
     (Maybe EnhancedMonitoring)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\MutableClusterInfo' {Maybe EnhancedMonitoring
enhancedMonitoring :: Maybe EnhancedMonitoring
$sel:enhancedMonitoring:MutableClusterInfo' :: MutableClusterInfo -> Maybe EnhancedMonitoring
enhancedMonitoring} -> Maybe EnhancedMonitoring
enhancedMonitoring) (\s :: MutableClusterInfo
s@MutableClusterInfo' {} Maybe EnhancedMonitoring
a -> MutableClusterInfo
s {$sel:enhancedMonitoring:MutableClusterInfo' :: Maybe EnhancedMonitoring
enhancedMonitoring = Maybe EnhancedMonitoring
a} :: MutableClusterInfo)

-- | The settings for open monitoring.
mutableClusterInfo_openMonitoring :: Lens.Lens' MutableClusterInfo (Prelude.Maybe OpenMonitoring)
mutableClusterInfo_openMonitoring :: (Maybe OpenMonitoring -> f (Maybe OpenMonitoring))
-> MutableClusterInfo -> f MutableClusterInfo
mutableClusterInfo_openMonitoring = (MutableClusterInfo -> Maybe OpenMonitoring)
-> (MutableClusterInfo
    -> Maybe OpenMonitoring -> MutableClusterInfo)
-> Lens
     MutableClusterInfo
     MutableClusterInfo
     (Maybe OpenMonitoring)
     (Maybe OpenMonitoring)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\MutableClusterInfo' {Maybe OpenMonitoring
openMonitoring :: Maybe OpenMonitoring
$sel:openMonitoring:MutableClusterInfo' :: MutableClusterInfo -> Maybe OpenMonitoring
openMonitoring} -> Maybe OpenMonitoring
openMonitoring) (\s :: MutableClusterInfo
s@MutableClusterInfo' {} Maybe OpenMonitoring
a -> MutableClusterInfo
s {$sel:openMonitoring:MutableClusterInfo' :: Maybe OpenMonitoring
openMonitoring = Maybe OpenMonitoring
a} :: MutableClusterInfo)

-- | Information about the changes in the configuration of the brokers.
mutableClusterInfo_configurationInfo :: Lens.Lens' MutableClusterInfo (Prelude.Maybe ConfigurationInfo)
mutableClusterInfo_configurationInfo :: (Maybe ConfigurationInfo -> f (Maybe ConfigurationInfo))
-> MutableClusterInfo -> f MutableClusterInfo
mutableClusterInfo_configurationInfo = (MutableClusterInfo -> Maybe ConfigurationInfo)
-> (MutableClusterInfo
    -> Maybe ConfigurationInfo -> MutableClusterInfo)
-> Lens
     MutableClusterInfo
     MutableClusterInfo
     (Maybe ConfigurationInfo)
     (Maybe ConfigurationInfo)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\MutableClusterInfo' {Maybe ConfigurationInfo
configurationInfo :: Maybe ConfigurationInfo
$sel:configurationInfo:MutableClusterInfo' :: MutableClusterInfo -> Maybe ConfigurationInfo
configurationInfo} -> Maybe ConfigurationInfo
configurationInfo) (\s :: MutableClusterInfo
s@MutableClusterInfo' {} Maybe ConfigurationInfo
a -> MutableClusterInfo
s {$sel:configurationInfo:MutableClusterInfo' :: Maybe ConfigurationInfo
configurationInfo = Maybe ConfigurationInfo
a} :: MutableClusterInfo)

-- | Information about the Amazon MSK broker type.
mutableClusterInfo_instanceType :: Lens.Lens' MutableClusterInfo (Prelude.Maybe Prelude.Text)
mutableClusterInfo_instanceType :: (Maybe Text -> f (Maybe Text))
-> MutableClusterInfo -> f MutableClusterInfo
mutableClusterInfo_instanceType = (MutableClusterInfo -> Maybe Text)
-> (MutableClusterInfo -> Maybe Text -> MutableClusterInfo)
-> Lens
     MutableClusterInfo MutableClusterInfo (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\MutableClusterInfo' {Maybe Text
instanceType :: Maybe Text
$sel:instanceType:MutableClusterInfo' :: MutableClusterInfo -> Maybe Text
instanceType} -> Maybe Text
instanceType) (\s :: MutableClusterInfo
s@MutableClusterInfo' {} Maybe Text
a -> MutableClusterInfo
s {$sel:instanceType:MutableClusterInfo' :: Maybe Text
instanceType = Maybe Text
a} :: MutableClusterInfo)

-- | The Kafka version.
mutableClusterInfo_kafkaVersion :: Lens.Lens' MutableClusterInfo (Prelude.Maybe Prelude.Text)
mutableClusterInfo_kafkaVersion :: (Maybe Text -> f (Maybe Text))
-> MutableClusterInfo -> f MutableClusterInfo
mutableClusterInfo_kafkaVersion = (MutableClusterInfo -> Maybe Text)
-> (MutableClusterInfo -> Maybe Text -> MutableClusterInfo)
-> Lens
     MutableClusterInfo MutableClusterInfo (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\MutableClusterInfo' {Maybe Text
kafkaVersion :: Maybe Text
$sel:kafkaVersion:MutableClusterInfo' :: MutableClusterInfo -> Maybe Text
kafkaVersion} -> Maybe Text
kafkaVersion) (\s :: MutableClusterInfo
s@MutableClusterInfo' {} Maybe Text
a -> MutableClusterInfo
s {$sel:kafkaVersion:MutableClusterInfo' :: Maybe Text
kafkaVersion = Maybe Text
a} :: MutableClusterInfo)

-- | You can configure your MSK cluster to send broker logs to different
-- destination types. This is a container for the configuration details
-- related to broker logs.
mutableClusterInfo_loggingInfo :: Lens.Lens' MutableClusterInfo (Prelude.Maybe LoggingInfo)
mutableClusterInfo_loggingInfo :: (Maybe LoggingInfo -> f (Maybe LoggingInfo))
-> MutableClusterInfo -> f MutableClusterInfo
mutableClusterInfo_loggingInfo = (MutableClusterInfo -> Maybe LoggingInfo)
-> (MutableClusterInfo -> Maybe LoggingInfo -> MutableClusterInfo)
-> Lens
     MutableClusterInfo
     MutableClusterInfo
     (Maybe LoggingInfo)
     (Maybe LoggingInfo)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\MutableClusterInfo' {Maybe LoggingInfo
loggingInfo :: Maybe LoggingInfo
$sel:loggingInfo:MutableClusterInfo' :: MutableClusterInfo -> Maybe LoggingInfo
loggingInfo} -> Maybe LoggingInfo
loggingInfo) (\s :: MutableClusterInfo
s@MutableClusterInfo' {} Maybe LoggingInfo
a -> MutableClusterInfo
s {$sel:loggingInfo:MutableClusterInfo' :: Maybe LoggingInfo
loggingInfo = Maybe LoggingInfo
a} :: MutableClusterInfo)

-- | Includes all client authentication information.
mutableClusterInfo_clientAuthentication :: Lens.Lens' MutableClusterInfo (Prelude.Maybe ClientAuthentication)
mutableClusterInfo_clientAuthentication :: (Maybe ClientAuthentication -> f (Maybe ClientAuthentication))
-> MutableClusterInfo -> f MutableClusterInfo
mutableClusterInfo_clientAuthentication = (MutableClusterInfo -> Maybe ClientAuthentication)
-> (MutableClusterInfo
    -> Maybe ClientAuthentication -> MutableClusterInfo)
-> Lens
     MutableClusterInfo
     MutableClusterInfo
     (Maybe ClientAuthentication)
     (Maybe ClientAuthentication)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\MutableClusterInfo' {Maybe ClientAuthentication
clientAuthentication :: Maybe ClientAuthentication
$sel:clientAuthentication:MutableClusterInfo' :: MutableClusterInfo -> Maybe ClientAuthentication
clientAuthentication} -> Maybe ClientAuthentication
clientAuthentication) (\s :: MutableClusterInfo
s@MutableClusterInfo' {} Maybe ClientAuthentication
a -> MutableClusterInfo
s {$sel:clientAuthentication:MutableClusterInfo' :: Maybe ClientAuthentication
clientAuthentication = Maybe ClientAuthentication
a} :: MutableClusterInfo)

-- | Specifies the size of the EBS volume and the ID of the associated
-- broker.
mutableClusterInfo_brokerEBSVolumeInfo :: Lens.Lens' MutableClusterInfo (Prelude.Maybe [BrokerEBSVolumeInfo])
mutableClusterInfo_brokerEBSVolumeInfo :: (Maybe [BrokerEBSVolumeInfo] -> f (Maybe [BrokerEBSVolumeInfo]))
-> MutableClusterInfo -> f MutableClusterInfo
mutableClusterInfo_brokerEBSVolumeInfo = (MutableClusterInfo -> Maybe [BrokerEBSVolumeInfo])
-> (MutableClusterInfo
    -> Maybe [BrokerEBSVolumeInfo] -> MutableClusterInfo)
-> Lens
     MutableClusterInfo
     MutableClusterInfo
     (Maybe [BrokerEBSVolumeInfo])
     (Maybe [BrokerEBSVolumeInfo])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\MutableClusterInfo' {Maybe [BrokerEBSVolumeInfo]
brokerEBSVolumeInfo :: Maybe [BrokerEBSVolumeInfo]
$sel:brokerEBSVolumeInfo:MutableClusterInfo' :: MutableClusterInfo -> Maybe [BrokerEBSVolumeInfo]
brokerEBSVolumeInfo} -> Maybe [BrokerEBSVolumeInfo]
brokerEBSVolumeInfo) (\s :: MutableClusterInfo
s@MutableClusterInfo' {} Maybe [BrokerEBSVolumeInfo]
a -> MutableClusterInfo
s {$sel:brokerEBSVolumeInfo:MutableClusterInfo' :: Maybe [BrokerEBSVolumeInfo]
brokerEBSVolumeInfo = Maybe [BrokerEBSVolumeInfo]
a} :: MutableClusterInfo) ((Maybe [BrokerEBSVolumeInfo] -> f (Maybe [BrokerEBSVolumeInfo]))
 -> MutableClusterInfo -> f MutableClusterInfo)
-> ((Maybe [BrokerEBSVolumeInfo]
     -> f (Maybe [BrokerEBSVolumeInfo]))
    -> Maybe [BrokerEBSVolumeInfo] -> f (Maybe [BrokerEBSVolumeInfo]))
-> (Maybe [BrokerEBSVolumeInfo] -> f (Maybe [BrokerEBSVolumeInfo]))
-> MutableClusterInfo
-> f MutableClusterInfo
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
  [BrokerEBSVolumeInfo]
  [BrokerEBSVolumeInfo]
  [BrokerEBSVolumeInfo]
  [BrokerEBSVolumeInfo]
-> Iso
     (Maybe [BrokerEBSVolumeInfo])
     (Maybe [BrokerEBSVolumeInfo])
     (Maybe [BrokerEBSVolumeInfo])
     (Maybe [BrokerEBSVolumeInfo])
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
  [BrokerEBSVolumeInfo]
  [BrokerEBSVolumeInfo]
  [BrokerEBSVolumeInfo]
  [BrokerEBSVolumeInfo]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | Includes all encryption-related information.
mutableClusterInfo_encryptionInfo :: Lens.Lens' MutableClusterInfo (Prelude.Maybe EncryptionInfo)
mutableClusterInfo_encryptionInfo :: (Maybe EncryptionInfo -> f (Maybe EncryptionInfo))
-> MutableClusterInfo -> f MutableClusterInfo
mutableClusterInfo_encryptionInfo = (MutableClusterInfo -> Maybe EncryptionInfo)
-> (MutableClusterInfo
    -> Maybe EncryptionInfo -> MutableClusterInfo)
-> Lens
     MutableClusterInfo
     MutableClusterInfo
     (Maybe EncryptionInfo)
     (Maybe EncryptionInfo)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\MutableClusterInfo' {Maybe EncryptionInfo
encryptionInfo :: Maybe EncryptionInfo
$sel:encryptionInfo:MutableClusterInfo' :: MutableClusterInfo -> Maybe EncryptionInfo
encryptionInfo} -> Maybe EncryptionInfo
encryptionInfo) (\s :: MutableClusterInfo
s@MutableClusterInfo' {} Maybe EncryptionInfo
a -> MutableClusterInfo
s {$sel:encryptionInfo:MutableClusterInfo' :: Maybe EncryptionInfo
encryptionInfo = Maybe EncryptionInfo
a} :: MutableClusterInfo)

instance Core.FromJSON MutableClusterInfo where
  parseJSON :: Value -> Parser MutableClusterInfo
parseJSON =
    String
-> (Object -> Parser MutableClusterInfo)
-> Value
-> Parser MutableClusterInfo
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Core.withObject
      String
"MutableClusterInfo"
      ( \Object
x ->
          Maybe Int
-> Maybe EnhancedMonitoring
-> Maybe OpenMonitoring
-> Maybe ConfigurationInfo
-> Maybe Text
-> Maybe Text
-> Maybe LoggingInfo
-> Maybe ClientAuthentication
-> Maybe [BrokerEBSVolumeInfo]
-> Maybe EncryptionInfo
-> MutableClusterInfo
MutableClusterInfo'
            (Maybe Int
 -> Maybe EnhancedMonitoring
 -> Maybe OpenMonitoring
 -> Maybe ConfigurationInfo
 -> Maybe Text
 -> Maybe Text
 -> Maybe LoggingInfo
 -> Maybe ClientAuthentication
 -> Maybe [BrokerEBSVolumeInfo]
 -> Maybe EncryptionInfo
 -> MutableClusterInfo)
-> Parser (Maybe Int)
-> Parser
     (Maybe EnhancedMonitoring
      -> Maybe OpenMonitoring
      -> Maybe ConfigurationInfo
      -> Maybe Text
      -> Maybe Text
      -> Maybe LoggingInfo
      -> Maybe ClientAuthentication
      -> Maybe [BrokerEBSVolumeInfo]
      -> Maybe EncryptionInfo
      -> MutableClusterInfo)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"numberOfBrokerNodes")
            Parser
  (Maybe EnhancedMonitoring
   -> Maybe OpenMonitoring
   -> Maybe ConfigurationInfo
   -> Maybe Text
   -> Maybe Text
   -> Maybe LoggingInfo
   -> Maybe ClientAuthentication
   -> Maybe [BrokerEBSVolumeInfo]
   -> Maybe EncryptionInfo
   -> MutableClusterInfo)
-> Parser (Maybe EnhancedMonitoring)
-> Parser
     (Maybe OpenMonitoring
      -> Maybe ConfigurationInfo
      -> Maybe Text
      -> Maybe Text
      -> Maybe LoggingInfo
      -> Maybe ClientAuthentication
      -> Maybe [BrokerEBSVolumeInfo]
      -> Maybe EncryptionInfo
      -> MutableClusterInfo)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe EnhancedMonitoring)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"enhancedMonitoring")
            Parser
  (Maybe OpenMonitoring
   -> Maybe ConfigurationInfo
   -> Maybe Text
   -> Maybe Text
   -> Maybe LoggingInfo
   -> Maybe ClientAuthentication
   -> Maybe [BrokerEBSVolumeInfo]
   -> Maybe EncryptionInfo
   -> MutableClusterInfo)
-> Parser (Maybe OpenMonitoring)
-> Parser
     (Maybe ConfigurationInfo
      -> Maybe Text
      -> Maybe Text
      -> Maybe LoggingInfo
      -> Maybe ClientAuthentication
      -> Maybe [BrokerEBSVolumeInfo]
      -> Maybe EncryptionInfo
      -> MutableClusterInfo)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe OpenMonitoring)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"openMonitoring")
            Parser
  (Maybe ConfigurationInfo
   -> Maybe Text
   -> Maybe Text
   -> Maybe LoggingInfo
   -> Maybe ClientAuthentication
   -> Maybe [BrokerEBSVolumeInfo]
   -> Maybe EncryptionInfo
   -> MutableClusterInfo)
-> Parser (Maybe ConfigurationInfo)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe LoggingInfo
      -> Maybe ClientAuthentication
      -> Maybe [BrokerEBSVolumeInfo]
      -> Maybe EncryptionInfo
      -> MutableClusterInfo)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe ConfigurationInfo)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"configurationInfo")
            Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe LoggingInfo
   -> Maybe ClientAuthentication
   -> Maybe [BrokerEBSVolumeInfo]
   -> Maybe EncryptionInfo
   -> MutableClusterInfo)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe LoggingInfo
      -> Maybe ClientAuthentication
      -> Maybe [BrokerEBSVolumeInfo]
      -> Maybe EncryptionInfo
      -> MutableClusterInfo)
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
"instanceType")
            Parser
  (Maybe Text
   -> Maybe LoggingInfo
   -> Maybe ClientAuthentication
   -> Maybe [BrokerEBSVolumeInfo]
   -> Maybe EncryptionInfo
   -> MutableClusterInfo)
-> Parser (Maybe Text)
-> Parser
     (Maybe LoggingInfo
      -> Maybe ClientAuthentication
      -> Maybe [BrokerEBSVolumeInfo]
      -> Maybe EncryptionInfo
      -> MutableClusterInfo)
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
"kafkaVersion")
            Parser
  (Maybe LoggingInfo
   -> Maybe ClientAuthentication
   -> Maybe [BrokerEBSVolumeInfo]
   -> Maybe EncryptionInfo
   -> MutableClusterInfo)
-> Parser (Maybe LoggingInfo)
-> Parser
     (Maybe ClientAuthentication
      -> Maybe [BrokerEBSVolumeInfo]
      -> Maybe EncryptionInfo
      -> MutableClusterInfo)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe LoggingInfo)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"loggingInfo")
            Parser
  (Maybe ClientAuthentication
   -> Maybe [BrokerEBSVolumeInfo]
   -> Maybe EncryptionInfo
   -> MutableClusterInfo)
-> Parser (Maybe ClientAuthentication)
-> Parser
     (Maybe [BrokerEBSVolumeInfo]
      -> Maybe EncryptionInfo -> MutableClusterInfo)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe ClientAuthentication)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"clientAuthentication")
            Parser
  (Maybe [BrokerEBSVolumeInfo]
   -> Maybe EncryptionInfo -> MutableClusterInfo)
-> Parser (Maybe [BrokerEBSVolumeInfo])
-> Parser (Maybe EncryptionInfo -> MutableClusterInfo)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( Object
x Object -> Text -> Parser (Maybe (Maybe [BrokerEBSVolumeInfo]))
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"brokerEBSVolumeInfo"
                            Parser (Maybe (Maybe [BrokerEBSVolumeInfo]))
-> Maybe [BrokerEBSVolumeInfo]
-> Parser (Maybe [BrokerEBSVolumeInfo])
forall a. Parser (Maybe a) -> a -> Parser a
Core..!= Maybe [BrokerEBSVolumeInfo]
forall a. Monoid a => a
Prelude.mempty
                        )
            Parser (Maybe EncryptionInfo -> MutableClusterInfo)
-> Parser (Maybe EncryptionInfo) -> Parser MutableClusterInfo
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe EncryptionInfo)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"encryptionInfo")
      )

instance Prelude.Hashable MutableClusterInfo

instance Prelude.NFData MutableClusterInfo