{-# 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.ElastiCache.Types.ReplicationGroup
-- 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.ElastiCache.Types.ReplicationGroup where

import qualified Amazonka.Core as Core
import Amazonka.ElastiCache.Types.AutomaticFailoverStatus
import Amazonka.ElastiCache.Types.Endpoint
import Amazonka.ElastiCache.Types.GlobalReplicationGroupInfo
import Amazonka.ElastiCache.Types.LogDeliveryConfiguration
import Amazonka.ElastiCache.Types.MultiAZStatus
import Amazonka.ElastiCache.Types.NodeGroup
import Amazonka.ElastiCache.Types.ReplicationGroupPendingModifiedValues
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude

-- | Contains all of the attributes of a specific Redis replication group.
--
-- /See:/ 'newReplicationGroup' smart constructor.
data ReplicationGroup = ReplicationGroup'
  { -- | The date the auth token was last modified
    ReplicationGroup -> Maybe ISO8601
authTokenLastModifiedDate :: Prelude.Maybe Core.ISO8601,
    -- | The current state of this replication group - @creating@, @available@,
    -- @modifying@, @deleting@, @create-failed@, @snapshotting@.
    ReplicationGroup -> Maybe Text
status :: Prelude.Maybe Prelude.Text,
    -- | The name of the compute and memory capacity node type for each node in
    -- the replication group.
    ReplicationGroup -> Maybe Text
cacheNodeType :: Prelude.Maybe Prelude.Text,
    -- | A list of node groups in this replication group. For Redis (cluster mode
    -- disabled) replication groups, this is a single-element list. For Redis
    -- (cluster mode enabled) replication groups, the list contains an entry
    -- for each node group (shard).
    ReplicationGroup -> Maybe [NodeGroup]
nodeGroups :: Prelude.Maybe [NodeGroup],
    -- | The cluster ID that is used as the daily snapshot source for the
    -- replication group.
    ReplicationGroup -> Maybe Text
snapshottingClusterId :: Prelude.Maybe Prelude.Text,
    -- | A flag indicating whether or not this replication group is cluster
    -- enabled; i.e., whether its data can be partitioned across multiple
    -- shards (API\/CLI: node groups).
    --
    -- Valid values: @true@ | @false@
    ReplicationGroup -> Maybe Bool
clusterEnabled :: Prelude.Maybe Prelude.Bool,
    -- | A flag that enables encryption at-rest when set to @true@.
    --
    -- You cannot modify the value of @AtRestEncryptionEnabled@ after the
    -- cluster is created. To enable encryption at-rest on a cluster you must
    -- set @AtRestEncryptionEnabled@ to @true@ when you create a cluster.
    --
    -- __Required:__ Only available when creating a replication group in an
    -- Amazon VPC using redis version @3.2.6@, @4.x@ or later.
    --
    -- Default: @false@
    ReplicationGroup -> Maybe Bool
atRestEncryptionEnabled :: Prelude.Maybe Prelude.Bool,
    -- | The date and time when the cluster was created.
    ReplicationGroup -> Maybe ISO8601
replicationGroupCreateTime :: Prelude.Maybe Core.ISO8601,
    -- | The ARN (Amazon Resource Name) of the replication group.
    ReplicationGroup -> Maybe Text
arn :: Prelude.Maybe Prelude.Text,
    -- | A flag that enables in-transit encryption when set to @true@.
    --
    -- You cannot modify the value of @TransitEncryptionEnabled@ after the
    -- cluster is created. To enable in-transit encryption on a cluster you
    -- must set @TransitEncryptionEnabled@ to @true@ when you create a cluster.
    --
    -- __Required:__ Only available when creating a replication group in an
    -- Amazon VPC using redis version @3.2.6@, @4.x@ or later.
    --
    -- Default: @false@
    ReplicationGroup -> Maybe Bool
transitEncryptionEnabled :: Prelude.Maybe Prelude.Bool,
    -- | The ID of the user group associated to the replication group.
    ReplicationGroup -> Maybe [Text]
userGroupIds :: Prelude.Maybe [Prelude.Text],
    -- | The daily time range (in UTC) during which ElastiCache begins taking a
    -- daily snapshot of your node group (shard).
    --
    -- Example: @05:00-09:00@
    --
    -- If you do not specify this parameter, ElastiCache automatically chooses
    -- an appropriate time range.
    --
    -- This parameter is only valid if the @Engine@ parameter is @redis@.
    ReplicationGroup -> Maybe Text
snapshotWindow :: Prelude.Maybe Prelude.Text,
    -- | Returns the destination, format and type of the logs.
    ReplicationGroup -> Maybe [LogDeliveryConfiguration]
logDeliveryConfigurations :: Prelude.Maybe [LogDeliveryConfiguration],
    -- | The configuration endpoint for this replication group. Use the
    -- configuration endpoint to connect to this replication group.
    ReplicationGroup -> Maybe Endpoint
configurationEndpoint :: Prelude.Maybe Endpoint,
    -- | A flag that enables using an @AuthToken@ (password) when issuing Redis
    -- commands.
    --
    -- Default: @false@
    ReplicationGroup -> Maybe Bool
authTokenEnabled :: Prelude.Maybe Prelude.Bool,
    -- | The names of all the cache clusters that are part of this replication
    -- group.
    ReplicationGroup -> Maybe [Text]
memberClusters :: Prelude.Maybe [Prelude.Text],
    -- | The ID of the KMS key used to encrypt the disk in the cluster.
    ReplicationGroup -> Maybe Text
kmsKeyId :: Prelude.Maybe Prelude.Text,
    -- | A flag indicating if you have Multi-AZ enabled to enhance fault
    -- tolerance. For more information, see
    -- <http://docs.aws.amazon.com/AmazonElastiCache/latest/red-ug/AutoFailover.html Minimizing Downtime: Multi-AZ>
    ReplicationGroup -> Maybe MultiAZStatus
multiAZ :: Prelude.Maybe MultiAZStatus,
    -- | The number of days for which ElastiCache retains automatic cluster
    -- snapshots before deleting them. For example, if you set
    -- @SnapshotRetentionLimit@ to 5, a snapshot that was taken today is
    -- retained for 5 days before being deleted.
    --
    -- If the value of @SnapshotRetentionLimit@ is set to zero (0), backups are
    -- turned off.
    ReplicationGroup -> Maybe Int
snapshotRetentionLimit :: Prelude.Maybe Prelude.Int,
    -- | The user supplied description of the replication group.
    ReplicationGroup -> Maybe Text
description :: Prelude.Maybe Prelude.Text,
    -- | The identifier for the replication group.
    ReplicationGroup -> Maybe Text
replicationGroupId :: Prelude.Maybe Prelude.Text,
    -- | A group of settings to be applied to the replication group, either
    -- immediately or during the next maintenance window.
    ReplicationGroup -> Maybe ReplicationGroupPendingModifiedValues
pendingModifiedValues :: Prelude.Maybe ReplicationGroupPendingModifiedValues,
    -- | The name of the Global datastore and role of this replication group in
    -- the Global datastore.
    ReplicationGroup -> Maybe GlobalReplicationGroupInfo
globalReplicationGroupInfo :: Prelude.Maybe GlobalReplicationGroupInfo,
    -- | The outpost ARNs of the replication group\'s member clusters.
    ReplicationGroup -> Maybe [Text]
memberClustersOutpostArns :: Prelude.Maybe [Prelude.Text],
    -- | Indicates the status of automatic failover for this Redis replication
    -- group.
    ReplicationGroup -> Maybe AutomaticFailoverStatus
automaticFailover :: Prelude.Maybe AutomaticFailoverStatus
  }
  deriving (ReplicationGroup -> ReplicationGroup -> Bool
(ReplicationGroup -> ReplicationGroup -> Bool)
-> (ReplicationGroup -> ReplicationGroup -> Bool)
-> Eq ReplicationGroup
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ReplicationGroup -> ReplicationGroup -> Bool
$c/= :: ReplicationGroup -> ReplicationGroup -> Bool
== :: ReplicationGroup -> ReplicationGroup -> Bool
$c== :: ReplicationGroup -> ReplicationGroup -> Bool
Prelude.Eq, ReadPrec [ReplicationGroup]
ReadPrec ReplicationGroup
Int -> ReadS ReplicationGroup
ReadS [ReplicationGroup]
(Int -> ReadS ReplicationGroup)
-> ReadS [ReplicationGroup]
-> ReadPrec ReplicationGroup
-> ReadPrec [ReplicationGroup]
-> Read ReplicationGroup
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ReplicationGroup]
$creadListPrec :: ReadPrec [ReplicationGroup]
readPrec :: ReadPrec ReplicationGroup
$creadPrec :: ReadPrec ReplicationGroup
readList :: ReadS [ReplicationGroup]
$creadList :: ReadS [ReplicationGroup]
readsPrec :: Int -> ReadS ReplicationGroup
$creadsPrec :: Int -> ReadS ReplicationGroup
Prelude.Read, Int -> ReplicationGroup -> ShowS
[ReplicationGroup] -> ShowS
ReplicationGroup -> String
(Int -> ReplicationGroup -> ShowS)
-> (ReplicationGroup -> String)
-> ([ReplicationGroup] -> ShowS)
-> Show ReplicationGroup
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ReplicationGroup] -> ShowS
$cshowList :: [ReplicationGroup] -> ShowS
show :: ReplicationGroup -> String
$cshow :: ReplicationGroup -> String
showsPrec :: Int -> ReplicationGroup -> ShowS
$cshowsPrec :: Int -> ReplicationGroup -> ShowS
Prelude.Show, (forall x. ReplicationGroup -> Rep ReplicationGroup x)
-> (forall x. Rep ReplicationGroup x -> ReplicationGroup)
-> Generic ReplicationGroup
forall x. Rep ReplicationGroup x -> ReplicationGroup
forall x. ReplicationGroup -> Rep ReplicationGroup x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep ReplicationGroup x -> ReplicationGroup
$cfrom :: forall x. ReplicationGroup -> Rep ReplicationGroup x
Prelude.Generic)

-- |
-- Create a value of 'ReplicationGroup' 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:
--
-- 'authTokenLastModifiedDate', 'replicationGroup_authTokenLastModifiedDate' - The date the auth token was last modified
--
-- 'status', 'replicationGroup_status' - The current state of this replication group - @creating@, @available@,
-- @modifying@, @deleting@, @create-failed@, @snapshotting@.
--
-- 'cacheNodeType', 'replicationGroup_cacheNodeType' - The name of the compute and memory capacity node type for each node in
-- the replication group.
--
-- 'nodeGroups', 'replicationGroup_nodeGroups' - A list of node groups in this replication group. For Redis (cluster mode
-- disabled) replication groups, this is a single-element list. For Redis
-- (cluster mode enabled) replication groups, the list contains an entry
-- for each node group (shard).
--
-- 'snapshottingClusterId', 'replicationGroup_snapshottingClusterId' - The cluster ID that is used as the daily snapshot source for the
-- replication group.
--
-- 'clusterEnabled', 'replicationGroup_clusterEnabled' - A flag indicating whether or not this replication group is cluster
-- enabled; i.e., whether its data can be partitioned across multiple
-- shards (API\/CLI: node groups).
--
-- Valid values: @true@ | @false@
--
-- 'atRestEncryptionEnabled', 'replicationGroup_atRestEncryptionEnabled' - A flag that enables encryption at-rest when set to @true@.
--
-- You cannot modify the value of @AtRestEncryptionEnabled@ after the
-- cluster is created. To enable encryption at-rest on a cluster you must
-- set @AtRestEncryptionEnabled@ to @true@ when you create a cluster.
--
-- __Required:__ Only available when creating a replication group in an
-- Amazon VPC using redis version @3.2.6@, @4.x@ or later.
--
-- Default: @false@
--
-- 'replicationGroupCreateTime', 'replicationGroup_replicationGroupCreateTime' - The date and time when the cluster was created.
--
-- 'arn', 'replicationGroup_arn' - The ARN (Amazon Resource Name) of the replication group.
--
-- 'transitEncryptionEnabled', 'replicationGroup_transitEncryptionEnabled' - A flag that enables in-transit encryption when set to @true@.
--
-- You cannot modify the value of @TransitEncryptionEnabled@ after the
-- cluster is created. To enable in-transit encryption on a cluster you
-- must set @TransitEncryptionEnabled@ to @true@ when you create a cluster.
--
-- __Required:__ Only available when creating a replication group in an
-- Amazon VPC using redis version @3.2.6@, @4.x@ or later.
--
-- Default: @false@
--
-- 'userGroupIds', 'replicationGroup_userGroupIds' - The ID of the user group associated to the replication group.
--
-- 'snapshotWindow', 'replicationGroup_snapshotWindow' - The daily time range (in UTC) during which ElastiCache begins taking a
-- daily snapshot of your node group (shard).
--
-- Example: @05:00-09:00@
--
-- If you do not specify this parameter, ElastiCache automatically chooses
-- an appropriate time range.
--
-- This parameter is only valid if the @Engine@ parameter is @redis@.
--
-- 'logDeliveryConfigurations', 'replicationGroup_logDeliveryConfigurations' - Returns the destination, format and type of the logs.
--
-- 'configurationEndpoint', 'replicationGroup_configurationEndpoint' - The configuration endpoint for this replication group. Use the
-- configuration endpoint to connect to this replication group.
--
-- 'authTokenEnabled', 'replicationGroup_authTokenEnabled' - A flag that enables using an @AuthToken@ (password) when issuing Redis
-- commands.
--
-- Default: @false@
--
-- 'memberClusters', 'replicationGroup_memberClusters' - The names of all the cache clusters that are part of this replication
-- group.
--
-- 'kmsKeyId', 'replicationGroup_kmsKeyId' - The ID of the KMS key used to encrypt the disk in the cluster.
--
-- 'multiAZ', 'replicationGroup_multiAZ' - A flag indicating if you have Multi-AZ enabled to enhance fault
-- tolerance. For more information, see
-- <http://docs.aws.amazon.com/AmazonElastiCache/latest/red-ug/AutoFailover.html Minimizing Downtime: Multi-AZ>
--
-- 'snapshotRetentionLimit', 'replicationGroup_snapshotRetentionLimit' - The number of days for which ElastiCache retains automatic cluster
-- snapshots before deleting them. For example, if you set
-- @SnapshotRetentionLimit@ to 5, a snapshot that was taken today is
-- retained for 5 days before being deleted.
--
-- If the value of @SnapshotRetentionLimit@ is set to zero (0), backups are
-- turned off.
--
-- 'description', 'replicationGroup_description' - The user supplied description of the replication group.
--
-- 'replicationGroupId', 'replicationGroup_replicationGroupId' - The identifier for the replication group.
--
-- 'pendingModifiedValues', 'replicationGroup_pendingModifiedValues' - A group of settings to be applied to the replication group, either
-- immediately or during the next maintenance window.
--
-- 'globalReplicationGroupInfo', 'replicationGroup_globalReplicationGroupInfo' - The name of the Global datastore and role of this replication group in
-- the Global datastore.
--
-- 'memberClustersOutpostArns', 'replicationGroup_memberClustersOutpostArns' - The outpost ARNs of the replication group\'s member clusters.
--
-- 'automaticFailover', 'replicationGroup_automaticFailover' - Indicates the status of automatic failover for this Redis replication
-- group.
newReplicationGroup ::
  ReplicationGroup
newReplicationGroup :: ReplicationGroup
newReplicationGroup =
  ReplicationGroup' :: Maybe ISO8601
-> Maybe Text
-> Maybe Text
-> Maybe [NodeGroup]
-> Maybe Text
-> Maybe Bool
-> Maybe Bool
-> Maybe ISO8601
-> Maybe Text
-> Maybe Bool
-> Maybe [Text]
-> Maybe Text
-> Maybe [LogDeliveryConfiguration]
-> Maybe Endpoint
-> Maybe Bool
-> Maybe [Text]
-> Maybe Text
-> Maybe MultiAZStatus
-> Maybe Int
-> Maybe Text
-> Maybe Text
-> Maybe ReplicationGroupPendingModifiedValues
-> Maybe GlobalReplicationGroupInfo
-> Maybe [Text]
-> Maybe AutomaticFailoverStatus
-> ReplicationGroup
ReplicationGroup'
    { $sel:authTokenLastModifiedDate:ReplicationGroup' :: Maybe ISO8601
authTokenLastModifiedDate =
        Maybe ISO8601
forall a. Maybe a
Prelude.Nothing,
      $sel:status:ReplicationGroup' :: Maybe Text
status = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:cacheNodeType:ReplicationGroup' :: Maybe Text
cacheNodeType = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:nodeGroups:ReplicationGroup' :: Maybe [NodeGroup]
nodeGroups = Maybe [NodeGroup]
forall a. Maybe a
Prelude.Nothing,
      $sel:snapshottingClusterId:ReplicationGroup' :: Maybe Text
snapshottingClusterId = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:clusterEnabled:ReplicationGroup' :: Maybe Bool
clusterEnabled = Maybe Bool
forall a. Maybe a
Prelude.Nothing,
      $sel:atRestEncryptionEnabled:ReplicationGroup' :: Maybe Bool
atRestEncryptionEnabled = Maybe Bool
forall a. Maybe a
Prelude.Nothing,
      $sel:replicationGroupCreateTime:ReplicationGroup' :: Maybe ISO8601
replicationGroupCreateTime = Maybe ISO8601
forall a. Maybe a
Prelude.Nothing,
      $sel:arn:ReplicationGroup' :: Maybe Text
arn = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:transitEncryptionEnabled:ReplicationGroup' :: Maybe Bool
transitEncryptionEnabled = Maybe Bool
forall a. Maybe a
Prelude.Nothing,
      $sel:userGroupIds:ReplicationGroup' :: Maybe [Text]
userGroupIds = Maybe [Text]
forall a. Maybe a
Prelude.Nothing,
      $sel:snapshotWindow:ReplicationGroup' :: Maybe Text
snapshotWindow = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:logDeliveryConfigurations:ReplicationGroup' :: Maybe [LogDeliveryConfiguration]
logDeliveryConfigurations = Maybe [LogDeliveryConfiguration]
forall a. Maybe a
Prelude.Nothing,
      $sel:configurationEndpoint:ReplicationGroup' :: Maybe Endpoint
configurationEndpoint = Maybe Endpoint
forall a. Maybe a
Prelude.Nothing,
      $sel:authTokenEnabled:ReplicationGroup' :: Maybe Bool
authTokenEnabled = Maybe Bool
forall a. Maybe a
Prelude.Nothing,
      $sel:memberClusters:ReplicationGroup' :: Maybe [Text]
memberClusters = Maybe [Text]
forall a. Maybe a
Prelude.Nothing,
      $sel:kmsKeyId:ReplicationGroup' :: Maybe Text
kmsKeyId = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:multiAZ:ReplicationGroup' :: Maybe MultiAZStatus
multiAZ = Maybe MultiAZStatus
forall a. Maybe a
Prelude.Nothing,
      $sel:snapshotRetentionLimit:ReplicationGroup' :: Maybe Int
snapshotRetentionLimit = Maybe Int
forall a. Maybe a
Prelude.Nothing,
      $sel:description:ReplicationGroup' :: Maybe Text
description = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:replicationGroupId:ReplicationGroup' :: Maybe Text
replicationGroupId = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:pendingModifiedValues:ReplicationGroup' :: Maybe ReplicationGroupPendingModifiedValues
pendingModifiedValues = Maybe ReplicationGroupPendingModifiedValues
forall a. Maybe a
Prelude.Nothing,
      $sel:globalReplicationGroupInfo:ReplicationGroup' :: Maybe GlobalReplicationGroupInfo
globalReplicationGroupInfo = Maybe GlobalReplicationGroupInfo
forall a. Maybe a
Prelude.Nothing,
      $sel:memberClustersOutpostArns:ReplicationGroup' :: Maybe [Text]
memberClustersOutpostArns = Maybe [Text]
forall a. Maybe a
Prelude.Nothing,
      $sel:automaticFailover:ReplicationGroup' :: Maybe AutomaticFailoverStatus
automaticFailover = Maybe AutomaticFailoverStatus
forall a. Maybe a
Prelude.Nothing
    }

-- | The date the auth token was last modified
replicationGroup_authTokenLastModifiedDate :: Lens.Lens' ReplicationGroup (Prelude.Maybe Prelude.UTCTime)
replicationGroup_authTokenLastModifiedDate :: (Maybe UTCTime -> f (Maybe UTCTime))
-> ReplicationGroup -> f ReplicationGroup
replicationGroup_authTokenLastModifiedDate = (ReplicationGroup -> Maybe ISO8601)
-> (ReplicationGroup -> Maybe ISO8601 -> ReplicationGroup)
-> Lens
     ReplicationGroup ReplicationGroup (Maybe ISO8601) (Maybe ISO8601)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ReplicationGroup' {Maybe ISO8601
authTokenLastModifiedDate :: Maybe ISO8601
$sel:authTokenLastModifiedDate:ReplicationGroup' :: ReplicationGroup -> Maybe ISO8601
authTokenLastModifiedDate} -> Maybe ISO8601
authTokenLastModifiedDate) (\s :: ReplicationGroup
s@ReplicationGroup' {} Maybe ISO8601
a -> ReplicationGroup
s {$sel:authTokenLastModifiedDate:ReplicationGroup' :: Maybe ISO8601
authTokenLastModifiedDate = Maybe ISO8601
a} :: ReplicationGroup) ((Maybe ISO8601 -> f (Maybe ISO8601))
 -> ReplicationGroup -> f ReplicationGroup)
-> ((Maybe UTCTime -> f (Maybe UTCTime))
    -> Maybe ISO8601 -> f (Maybe ISO8601))
-> (Maybe UTCTime -> f (Maybe UTCTime))
-> ReplicationGroup
-> f ReplicationGroup
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso ISO8601 ISO8601 UTCTime UTCTime
-> Iso
     (Maybe ISO8601) (Maybe ISO8601) (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 ISO8601 ISO8601 UTCTime UTCTime
forall (a :: Format). Iso' (Time a) UTCTime
Core._Time

-- | The current state of this replication group - @creating@, @available@,
-- @modifying@, @deleting@, @create-failed@, @snapshotting@.
replicationGroup_status :: Lens.Lens' ReplicationGroup (Prelude.Maybe Prelude.Text)
replicationGroup_status :: (Maybe Text -> f (Maybe Text))
-> ReplicationGroup -> f ReplicationGroup
replicationGroup_status = (ReplicationGroup -> Maybe Text)
-> (ReplicationGroup -> Maybe Text -> ReplicationGroup)
-> Lens ReplicationGroup ReplicationGroup (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ReplicationGroup' {Maybe Text
status :: Maybe Text
$sel:status:ReplicationGroup' :: ReplicationGroup -> Maybe Text
status} -> Maybe Text
status) (\s :: ReplicationGroup
s@ReplicationGroup' {} Maybe Text
a -> ReplicationGroup
s {$sel:status:ReplicationGroup' :: Maybe Text
status = Maybe Text
a} :: ReplicationGroup)

-- | The name of the compute and memory capacity node type for each node in
-- the replication group.
replicationGroup_cacheNodeType :: Lens.Lens' ReplicationGroup (Prelude.Maybe Prelude.Text)
replicationGroup_cacheNodeType :: (Maybe Text -> f (Maybe Text))
-> ReplicationGroup -> f ReplicationGroup
replicationGroup_cacheNodeType = (ReplicationGroup -> Maybe Text)
-> (ReplicationGroup -> Maybe Text -> ReplicationGroup)
-> Lens ReplicationGroup ReplicationGroup (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ReplicationGroup' {Maybe Text
cacheNodeType :: Maybe Text
$sel:cacheNodeType:ReplicationGroup' :: ReplicationGroup -> Maybe Text
cacheNodeType} -> Maybe Text
cacheNodeType) (\s :: ReplicationGroup
s@ReplicationGroup' {} Maybe Text
a -> ReplicationGroup
s {$sel:cacheNodeType:ReplicationGroup' :: Maybe Text
cacheNodeType = Maybe Text
a} :: ReplicationGroup)

-- | A list of node groups in this replication group. For Redis (cluster mode
-- disabled) replication groups, this is a single-element list. For Redis
-- (cluster mode enabled) replication groups, the list contains an entry
-- for each node group (shard).
replicationGroup_nodeGroups :: Lens.Lens' ReplicationGroup (Prelude.Maybe [NodeGroup])
replicationGroup_nodeGroups :: (Maybe [NodeGroup] -> f (Maybe [NodeGroup]))
-> ReplicationGroup -> f ReplicationGroup
replicationGroup_nodeGroups = (ReplicationGroup -> Maybe [NodeGroup])
-> (ReplicationGroup -> Maybe [NodeGroup] -> ReplicationGroup)
-> Lens
     ReplicationGroup
     ReplicationGroup
     (Maybe [NodeGroup])
     (Maybe [NodeGroup])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ReplicationGroup' {Maybe [NodeGroup]
nodeGroups :: Maybe [NodeGroup]
$sel:nodeGroups:ReplicationGroup' :: ReplicationGroup -> Maybe [NodeGroup]
nodeGroups} -> Maybe [NodeGroup]
nodeGroups) (\s :: ReplicationGroup
s@ReplicationGroup' {} Maybe [NodeGroup]
a -> ReplicationGroup
s {$sel:nodeGroups:ReplicationGroup' :: Maybe [NodeGroup]
nodeGroups = Maybe [NodeGroup]
a} :: ReplicationGroup) ((Maybe [NodeGroup] -> f (Maybe [NodeGroup]))
 -> ReplicationGroup -> f ReplicationGroup)
-> ((Maybe [NodeGroup] -> f (Maybe [NodeGroup]))
    -> Maybe [NodeGroup] -> f (Maybe [NodeGroup]))
-> (Maybe [NodeGroup] -> f (Maybe [NodeGroup]))
-> ReplicationGroup
-> f ReplicationGroup
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso [NodeGroup] [NodeGroup] [NodeGroup] [NodeGroup]
-> Iso
     (Maybe [NodeGroup])
     (Maybe [NodeGroup])
     (Maybe [NodeGroup])
     (Maybe [NodeGroup])
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 [NodeGroup] [NodeGroup] [NodeGroup] [NodeGroup]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | The cluster ID that is used as the daily snapshot source for the
-- replication group.
replicationGroup_snapshottingClusterId :: Lens.Lens' ReplicationGroup (Prelude.Maybe Prelude.Text)
replicationGroup_snapshottingClusterId :: (Maybe Text -> f (Maybe Text))
-> ReplicationGroup -> f ReplicationGroup
replicationGroup_snapshottingClusterId = (ReplicationGroup -> Maybe Text)
-> (ReplicationGroup -> Maybe Text -> ReplicationGroup)
-> Lens ReplicationGroup ReplicationGroup (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ReplicationGroup' {Maybe Text
snapshottingClusterId :: Maybe Text
$sel:snapshottingClusterId:ReplicationGroup' :: ReplicationGroup -> Maybe Text
snapshottingClusterId} -> Maybe Text
snapshottingClusterId) (\s :: ReplicationGroup
s@ReplicationGroup' {} Maybe Text
a -> ReplicationGroup
s {$sel:snapshottingClusterId:ReplicationGroup' :: Maybe Text
snapshottingClusterId = Maybe Text
a} :: ReplicationGroup)

-- | A flag indicating whether or not this replication group is cluster
-- enabled; i.e., whether its data can be partitioned across multiple
-- shards (API\/CLI: node groups).
--
-- Valid values: @true@ | @false@
replicationGroup_clusterEnabled :: Lens.Lens' ReplicationGroup (Prelude.Maybe Prelude.Bool)
replicationGroup_clusterEnabled :: (Maybe Bool -> f (Maybe Bool))
-> ReplicationGroup -> f ReplicationGroup
replicationGroup_clusterEnabled = (ReplicationGroup -> Maybe Bool)
-> (ReplicationGroup -> Maybe Bool -> ReplicationGroup)
-> Lens ReplicationGroup ReplicationGroup (Maybe Bool) (Maybe Bool)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ReplicationGroup' {Maybe Bool
clusterEnabled :: Maybe Bool
$sel:clusterEnabled:ReplicationGroup' :: ReplicationGroup -> Maybe Bool
clusterEnabled} -> Maybe Bool
clusterEnabled) (\s :: ReplicationGroup
s@ReplicationGroup' {} Maybe Bool
a -> ReplicationGroup
s {$sel:clusterEnabled:ReplicationGroup' :: Maybe Bool
clusterEnabled = Maybe Bool
a} :: ReplicationGroup)

-- | A flag that enables encryption at-rest when set to @true@.
--
-- You cannot modify the value of @AtRestEncryptionEnabled@ after the
-- cluster is created. To enable encryption at-rest on a cluster you must
-- set @AtRestEncryptionEnabled@ to @true@ when you create a cluster.
--
-- __Required:__ Only available when creating a replication group in an
-- Amazon VPC using redis version @3.2.6@, @4.x@ or later.
--
-- Default: @false@
replicationGroup_atRestEncryptionEnabled :: Lens.Lens' ReplicationGroup (Prelude.Maybe Prelude.Bool)
replicationGroup_atRestEncryptionEnabled :: (Maybe Bool -> f (Maybe Bool))
-> ReplicationGroup -> f ReplicationGroup
replicationGroup_atRestEncryptionEnabled = (ReplicationGroup -> Maybe Bool)
-> (ReplicationGroup -> Maybe Bool -> ReplicationGroup)
-> Lens ReplicationGroup ReplicationGroup (Maybe Bool) (Maybe Bool)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ReplicationGroup' {Maybe Bool
atRestEncryptionEnabled :: Maybe Bool
$sel:atRestEncryptionEnabled:ReplicationGroup' :: ReplicationGroup -> Maybe Bool
atRestEncryptionEnabled} -> Maybe Bool
atRestEncryptionEnabled) (\s :: ReplicationGroup
s@ReplicationGroup' {} Maybe Bool
a -> ReplicationGroup
s {$sel:atRestEncryptionEnabled:ReplicationGroup' :: Maybe Bool
atRestEncryptionEnabled = Maybe Bool
a} :: ReplicationGroup)

-- | The date and time when the cluster was created.
replicationGroup_replicationGroupCreateTime :: Lens.Lens' ReplicationGroup (Prelude.Maybe Prelude.UTCTime)
replicationGroup_replicationGroupCreateTime :: (Maybe UTCTime -> f (Maybe UTCTime))
-> ReplicationGroup -> f ReplicationGroup
replicationGroup_replicationGroupCreateTime = (ReplicationGroup -> Maybe ISO8601)
-> (ReplicationGroup -> Maybe ISO8601 -> ReplicationGroup)
-> Lens
     ReplicationGroup ReplicationGroup (Maybe ISO8601) (Maybe ISO8601)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ReplicationGroup' {Maybe ISO8601
replicationGroupCreateTime :: Maybe ISO8601
$sel:replicationGroupCreateTime:ReplicationGroup' :: ReplicationGroup -> Maybe ISO8601
replicationGroupCreateTime} -> Maybe ISO8601
replicationGroupCreateTime) (\s :: ReplicationGroup
s@ReplicationGroup' {} Maybe ISO8601
a -> ReplicationGroup
s {$sel:replicationGroupCreateTime:ReplicationGroup' :: Maybe ISO8601
replicationGroupCreateTime = Maybe ISO8601
a} :: ReplicationGroup) ((Maybe ISO8601 -> f (Maybe ISO8601))
 -> ReplicationGroup -> f ReplicationGroup)
-> ((Maybe UTCTime -> f (Maybe UTCTime))
    -> Maybe ISO8601 -> f (Maybe ISO8601))
-> (Maybe UTCTime -> f (Maybe UTCTime))
-> ReplicationGroup
-> f ReplicationGroup
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso ISO8601 ISO8601 UTCTime UTCTime
-> Iso
     (Maybe ISO8601) (Maybe ISO8601) (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 ISO8601 ISO8601 UTCTime UTCTime
forall (a :: Format). Iso' (Time a) UTCTime
Core._Time

-- | The ARN (Amazon Resource Name) of the replication group.
replicationGroup_arn :: Lens.Lens' ReplicationGroup (Prelude.Maybe Prelude.Text)
replicationGroup_arn :: (Maybe Text -> f (Maybe Text))
-> ReplicationGroup -> f ReplicationGroup
replicationGroup_arn = (ReplicationGroup -> Maybe Text)
-> (ReplicationGroup -> Maybe Text -> ReplicationGroup)
-> Lens ReplicationGroup ReplicationGroup (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ReplicationGroup' {Maybe Text
arn :: Maybe Text
$sel:arn:ReplicationGroup' :: ReplicationGroup -> Maybe Text
arn} -> Maybe Text
arn) (\s :: ReplicationGroup
s@ReplicationGroup' {} Maybe Text
a -> ReplicationGroup
s {$sel:arn:ReplicationGroup' :: Maybe Text
arn = Maybe Text
a} :: ReplicationGroup)

-- | A flag that enables in-transit encryption when set to @true@.
--
-- You cannot modify the value of @TransitEncryptionEnabled@ after the
-- cluster is created. To enable in-transit encryption on a cluster you
-- must set @TransitEncryptionEnabled@ to @true@ when you create a cluster.
--
-- __Required:__ Only available when creating a replication group in an
-- Amazon VPC using redis version @3.2.6@, @4.x@ or later.
--
-- Default: @false@
replicationGroup_transitEncryptionEnabled :: Lens.Lens' ReplicationGroup (Prelude.Maybe Prelude.Bool)
replicationGroup_transitEncryptionEnabled :: (Maybe Bool -> f (Maybe Bool))
-> ReplicationGroup -> f ReplicationGroup
replicationGroup_transitEncryptionEnabled = (ReplicationGroup -> Maybe Bool)
-> (ReplicationGroup -> Maybe Bool -> ReplicationGroup)
-> Lens ReplicationGroup ReplicationGroup (Maybe Bool) (Maybe Bool)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ReplicationGroup' {Maybe Bool
transitEncryptionEnabled :: Maybe Bool
$sel:transitEncryptionEnabled:ReplicationGroup' :: ReplicationGroup -> Maybe Bool
transitEncryptionEnabled} -> Maybe Bool
transitEncryptionEnabled) (\s :: ReplicationGroup
s@ReplicationGroup' {} Maybe Bool
a -> ReplicationGroup
s {$sel:transitEncryptionEnabled:ReplicationGroup' :: Maybe Bool
transitEncryptionEnabled = Maybe Bool
a} :: ReplicationGroup)

-- | The ID of the user group associated to the replication group.
replicationGroup_userGroupIds :: Lens.Lens' ReplicationGroup (Prelude.Maybe [Prelude.Text])
replicationGroup_userGroupIds :: (Maybe [Text] -> f (Maybe [Text]))
-> ReplicationGroup -> f ReplicationGroup
replicationGroup_userGroupIds = (ReplicationGroup -> Maybe [Text])
-> (ReplicationGroup -> Maybe [Text] -> ReplicationGroup)
-> Lens
     ReplicationGroup ReplicationGroup (Maybe [Text]) (Maybe [Text])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ReplicationGroup' {Maybe [Text]
userGroupIds :: Maybe [Text]
$sel:userGroupIds:ReplicationGroup' :: ReplicationGroup -> Maybe [Text]
userGroupIds} -> Maybe [Text]
userGroupIds) (\s :: ReplicationGroup
s@ReplicationGroup' {} Maybe [Text]
a -> ReplicationGroup
s {$sel:userGroupIds:ReplicationGroup' :: Maybe [Text]
userGroupIds = Maybe [Text]
a} :: ReplicationGroup) ((Maybe [Text] -> f (Maybe [Text]))
 -> ReplicationGroup -> f ReplicationGroup)
-> ((Maybe [Text] -> f (Maybe [Text]))
    -> Maybe [Text] -> f (Maybe [Text]))
-> (Maybe [Text] -> f (Maybe [Text]))
-> ReplicationGroup
-> f ReplicationGroup
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso [Text] [Text] [Text] [Text]
-> Iso (Maybe [Text]) (Maybe [Text]) (Maybe [Text]) (Maybe [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 [Text] [Text] [Text] [Text]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | The daily time range (in UTC) during which ElastiCache begins taking a
-- daily snapshot of your node group (shard).
--
-- Example: @05:00-09:00@
--
-- If you do not specify this parameter, ElastiCache automatically chooses
-- an appropriate time range.
--
-- This parameter is only valid if the @Engine@ parameter is @redis@.
replicationGroup_snapshotWindow :: Lens.Lens' ReplicationGroup (Prelude.Maybe Prelude.Text)
replicationGroup_snapshotWindow :: (Maybe Text -> f (Maybe Text))
-> ReplicationGroup -> f ReplicationGroup
replicationGroup_snapshotWindow = (ReplicationGroup -> Maybe Text)
-> (ReplicationGroup -> Maybe Text -> ReplicationGroup)
-> Lens ReplicationGroup ReplicationGroup (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ReplicationGroup' {Maybe Text
snapshotWindow :: Maybe Text
$sel:snapshotWindow:ReplicationGroup' :: ReplicationGroup -> Maybe Text
snapshotWindow} -> Maybe Text
snapshotWindow) (\s :: ReplicationGroup
s@ReplicationGroup' {} Maybe Text
a -> ReplicationGroup
s {$sel:snapshotWindow:ReplicationGroup' :: Maybe Text
snapshotWindow = Maybe Text
a} :: ReplicationGroup)

-- | Returns the destination, format and type of the logs.
replicationGroup_logDeliveryConfigurations :: Lens.Lens' ReplicationGroup (Prelude.Maybe [LogDeliveryConfiguration])
replicationGroup_logDeliveryConfigurations :: (Maybe [LogDeliveryConfiguration]
 -> f (Maybe [LogDeliveryConfiguration]))
-> ReplicationGroup -> f ReplicationGroup
replicationGroup_logDeliveryConfigurations = (ReplicationGroup -> Maybe [LogDeliveryConfiguration])
-> (ReplicationGroup
    -> Maybe [LogDeliveryConfiguration] -> ReplicationGroup)
-> Lens
     ReplicationGroup
     ReplicationGroup
     (Maybe [LogDeliveryConfiguration])
     (Maybe [LogDeliveryConfiguration])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ReplicationGroup' {Maybe [LogDeliveryConfiguration]
logDeliveryConfigurations :: Maybe [LogDeliveryConfiguration]
$sel:logDeliveryConfigurations:ReplicationGroup' :: ReplicationGroup -> Maybe [LogDeliveryConfiguration]
logDeliveryConfigurations} -> Maybe [LogDeliveryConfiguration]
logDeliveryConfigurations) (\s :: ReplicationGroup
s@ReplicationGroup' {} Maybe [LogDeliveryConfiguration]
a -> ReplicationGroup
s {$sel:logDeliveryConfigurations:ReplicationGroup' :: Maybe [LogDeliveryConfiguration]
logDeliveryConfigurations = Maybe [LogDeliveryConfiguration]
a} :: ReplicationGroup) ((Maybe [LogDeliveryConfiguration]
  -> f (Maybe [LogDeliveryConfiguration]))
 -> ReplicationGroup -> f ReplicationGroup)
-> ((Maybe [LogDeliveryConfiguration]
     -> f (Maybe [LogDeliveryConfiguration]))
    -> Maybe [LogDeliveryConfiguration]
    -> f (Maybe [LogDeliveryConfiguration]))
-> (Maybe [LogDeliveryConfiguration]
    -> f (Maybe [LogDeliveryConfiguration]))
-> ReplicationGroup
-> f ReplicationGroup
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
  [LogDeliveryConfiguration]
  [LogDeliveryConfiguration]
  [LogDeliveryConfiguration]
  [LogDeliveryConfiguration]
-> Iso
     (Maybe [LogDeliveryConfiguration])
     (Maybe [LogDeliveryConfiguration])
     (Maybe [LogDeliveryConfiguration])
     (Maybe [LogDeliveryConfiguration])
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
  [LogDeliveryConfiguration]
  [LogDeliveryConfiguration]
  [LogDeliveryConfiguration]
  [LogDeliveryConfiguration]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | The configuration endpoint for this replication group. Use the
-- configuration endpoint to connect to this replication group.
replicationGroup_configurationEndpoint :: Lens.Lens' ReplicationGroup (Prelude.Maybe Endpoint)
replicationGroup_configurationEndpoint :: (Maybe Endpoint -> f (Maybe Endpoint))
-> ReplicationGroup -> f ReplicationGroup
replicationGroup_configurationEndpoint = (ReplicationGroup -> Maybe Endpoint)
-> (ReplicationGroup -> Maybe Endpoint -> ReplicationGroup)
-> Lens
     ReplicationGroup ReplicationGroup (Maybe Endpoint) (Maybe Endpoint)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ReplicationGroup' {Maybe Endpoint
configurationEndpoint :: Maybe Endpoint
$sel:configurationEndpoint:ReplicationGroup' :: ReplicationGroup -> Maybe Endpoint
configurationEndpoint} -> Maybe Endpoint
configurationEndpoint) (\s :: ReplicationGroup
s@ReplicationGroup' {} Maybe Endpoint
a -> ReplicationGroup
s {$sel:configurationEndpoint:ReplicationGroup' :: Maybe Endpoint
configurationEndpoint = Maybe Endpoint
a} :: ReplicationGroup)

-- | A flag that enables using an @AuthToken@ (password) when issuing Redis
-- commands.
--
-- Default: @false@
replicationGroup_authTokenEnabled :: Lens.Lens' ReplicationGroup (Prelude.Maybe Prelude.Bool)
replicationGroup_authTokenEnabled :: (Maybe Bool -> f (Maybe Bool))
-> ReplicationGroup -> f ReplicationGroup
replicationGroup_authTokenEnabled = (ReplicationGroup -> Maybe Bool)
-> (ReplicationGroup -> Maybe Bool -> ReplicationGroup)
-> Lens ReplicationGroup ReplicationGroup (Maybe Bool) (Maybe Bool)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ReplicationGroup' {Maybe Bool
authTokenEnabled :: Maybe Bool
$sel:authTokenEnabled:ReplicationGroup' :: ReplicationGroup -> Maybe Bool
authTokenEnabled} -> Maybe Bool
authTokenEnabled) (\s :: ReplicationGroup
s@ReplicationGroup' {} Maybe Bool
a -> ReplicationGroup
s {$sel:authTokenEnabled:ReplicationGroup' :: Maybe Bool
authTokenEnabled = Maybe Bool
a} :: ReplicationGroup)

-- | The names of all the cache clusters that are part of this replication
-- group.
replicationGroup_memberClusters :: Lens.Lens' ReplicationGroup (Prelude.Maybe [Prelude.Text])
replicationGroup_memberClusters :: (Maybe [Text] -> f (Maybe [Text]))
-> ReplicationGroup -> f ReplicationGroup
replicationGroup_memberClusters = (ReplicationGroup -> Maybe [Text])
-> (ReplicationGroup -> Maybe [Text] -> ReplicationGroup)
-> Lens
     ReplicationGroup ReplicationGroup (Maybe [Text]) (Maybe [Text])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ReplicationGroup' {Maybe [Text]
memberClusters :: Maybe [Text]
$sel:memberClusters:ReplicationGroup' :: ReplicationGroup -> Maybe [Text]
memberClusters} -> Maybe [Text]
memberClusters) (\s :: ReplicationGroup
s@ReplicationGroup' {} Maybe [Text]
a -> ReplicationGroup
s {$sel:memberClusters:ReplicationGroup' :: Maybe [Text]
memberClusters = Maybe [Text]
a} :: ReplicationGroup) ((Maybe [Text] -> f (Maybe [Text]))
 -> ReplicationGroup -> f ReplicationGroup)
-> ((Maybe [Text] -> f (Maybe [Text]))
    -> Maybe [Text] -> f (Maybe [Text]))
-> (Maybe [Text] -> f (Maybe [Text]))
-> ReplicationGroup
-> f ReplicationGroup
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso [Text] [Text] [Text] [Text]
-> Iso (Maybe [Text]) (Maybe [Text]) (Maybe [Text]) (Maybe [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 [Text] [Text] [Text] [Text]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | The ID of the KMS key used to encrypt the disk in the cluster.
replicationGroup_kmsKeyId :: Lens.Lens' ReplicationGroup (Prelude.Maybe Prelude.Text)
replicationGroup_kmsKeyId :: (Maybe Text -> f (Maybe Text))
-> ReplicationGroup -> f ReplicationGroup
replicationGroup_kmsKeyId = (ReplicationGroup -> Maybe Text)
-> (ReplicationGroup -> Maybe Text -> ReplicationGroup)
-> Lens ReplicationGroup ReplicationGroup (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ReplicationGroup' {Maybe Text
kmsKeyId :: Maybe Text
$sel:kmsKeyId:ReplicationGroup' :: ReplicationGroup -> Maybe Text
kmsKeyId} -> Maybe Text
kmsKeyId) (\s :: ReplicationGroup
s@ReplicationGroup' {} Maybe Text
a -> ReplicationGroup
s {$sel:kmsKeyId:ReplicationGroup' :: Maybe Text
kmsKeyId = Maybe Text
a} :: ReplicationGroup)

-- | A flag indicating if you have Multi-AZ enabled to enhance fault
-- tolerance. For more information, see
-- <http://docs.aws.amazon.com/AmazonElastiCache/latest/red-ug/AutoFailover.html Minimizing Downtime: Multi-AZ>
replicationGroup_multiAZ :: Lens.Lens' ReplicationGroup (Prelude.Maybe MultiAZStatus)
replicationGroup_multiAZ :: (Maybe MultiAZStatus -> f (Maybe MultiAZStatus))
-> ReplicationGroup -> f ReplicationGroup
replicationGroup_multiAZ = (ReplicationGroup -> Maybe MultiAZStatus)
-> (ReplicationGroup -> Maybe MultiAZStatus -> ReplicationGroup)
-> Lens
     ReplicationGroup
     ReplicationGroup
     (Maybe MultiAZStatus)
     (Maybe MultiAZStatus)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ReplicationGroup' {Maybe MultiAZStatus
multiAZ :: Maybe MultiAZStatus
$sel:multiAZ:ReplicationGroup' :: ReplicationGroup -> Maybe MultiAZStatus
multiAZ} -> Maybe MultiAZStatus
multiAZ) (\s :: ReplicationGroup
s@ReplicationGroup' {} Maybe MultiAZStatus
a -> ReplicationGroup
s {$sel:multiAZ:ReplicationGroup' :: Maybe MultiAZStatus
multiAZ = Maybe MultiAZStatus
a} :: ReplicationGroup)

-- | The number of days for which ElastiCache retains automatic cluster
-- snapshots before deleting them. For example, if you set
-- @SnapshotRetentionLimit@ to 5, a snapshot that was taken today is
-- retained for 5 days before being deleted.
--
-- If the value of @SnapshotRetentionLimit@ is set to zero (0), backups are
-- turned off.
replicationGroup_snapshotRetentionLimit :: Lens.Lens' ReplicationGroup (Prelude.Maybe Prelude.Int)
replicationGroup_snapshotRetentionLimit :: (Maybe Int -> f (Maybe Int))
-> ReplicationGroup -> f ReplicationGroup
replicationGroup_snapshotRetentionLimit = (ReplicationGroup -> Maybe Int)
-> (ReplicationGroup -> Maybe Int -> ReplicationGroup)
-> Lens ReplicationGroup ReplicationGroup (Maybe Int) (Maybe Int)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ReplicationGroup' {Maybe Int
snapshotRetentionLimit :: Maybe Int
$sel:snapshotRetentionLimit:ReplicationGroup' :: ReplicationGroup -> Maybe Int
snapshotRetentionLimit} -> Maybe Int
snapshotRetentionLimit) (\s :: ReplicationGroup
s@ReplicationGroup' {} Maybe Int
a -> ReplicationGroup
s {$sel:snapshotRetentionLimit:ReplicationGroup' :: Maybe Int
snapshotRetentionLimit = Maybe Int
a} :: ReplicationGroup)

-- | The user supplied description of the replication group.
replicationGroup_description :: Lens.Lens' ReplicationGroup (Prelude.Maybe Prelude.Text)
replicationGroup_description :: (Maybe Text -> f (Maybe Text))
-> ReplicationGroup -> f ReplicationGroup
replicationGroup_description = (ReplicationGroup -> Maybe Text)
-> (ReplicationGroup -> Maybe Text -> ReplicationGroup)
-> Lens ReplicationGroup ReplicationGroup (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ReplicationGroup' {Maybe Text
description :: Maybe Text
$sel:description:ReplicationGroup' :: ReplicationGroup -> Maybe Text
description} -> Maybe Text
description) (\s :: ReplicationGroup
s@ReplicationGroup' {} Maybe Text
a -> ReplicationGroup
s {$sel:description:ReplicationGroup' :: Maybe Text
description = Maybe Text
a} :: ReplicationGroup)

-- | The identifier for the replication group.
replicationGroup_replicationGroupId :: Lens.Lens' ReplicationGroup (Prelude.Maybe Prelude.Text)
replicationGroup_replicationGroupId :: (Maybe Text -> f (Maybe Text))
-> ReplicationGroup -> f ReplicationGroup
replicationGroup_replicationGroupId = (ReplicationGroup -> Maybe Text)
-> (ReplicationGroup -> Maybe Text -> ReplicationGroup)
-> Lens ReplicationGroup ReplicationGroup (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ReplicationGroup' {Maybe Text
replicationGroupId :: Maybe Text
$sel:replicationGroupId:ReplicationGroup' :: ReplicationGroup -> Maybe Text
replicationGroupId} -> Maybe Text
replicationGroupId) (\s :: ReplicationGroup
s@ReplicationGroup' {} Maybe Text
a -> ReplicationGroup
s {$sel:replicationGroupId:ReplicationGroup' :: Maybe Text
replicationGroupId = Maybe Text
a} :: ReplicationGroup)

-- | A group of settings to be applied to the replication group, either
-- immediately or during the next maintenance window.
replicationGroup_pendingModifiedValues :: Lens.Lens' ReplicationGroup (Prelude.Maybe ReplicationGroupPendingModifiedValues)
replicationGroup_pendingModifiedValues :: (Maybe ReplicationGroupPendingModifiedValues
 -> f (Maybe ReplicationGroupPendingModifiedValues))
-> ReplicationGroup -> f ReplicationGroup
replicationGroup_pendingModifiedValues = (ReplicationGroup -> Maybe ReplicationGroupPendingModifiedValues)
-> (ReplicationGroup
    -> Maybe ReplicationGroupPendingModifiedValues -> ReplicationGroup)
-> Lens
     ReplicationGroup
     ReplicationGroup
     (Maybe ReplicationGroupPendingModifiedValues)
     (Maybe ReplicationGroupPendingModifiedValues)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ReplicationGroup' {Maybe ReplicationGroupPendingModifiedValues
pendingModifiedValues :: Maybe ReplicationGroupPendingModifiedValues
$sel:pendingModifiedValues:ReplicationGroup' :: ReplicationGroup -> Maybe ReplicationGroupPendingModifiedValues
pendingModifiedValues} -> Maybe ReplicationGroupPendingModifiedValues
pendingModifiedValues) (\s :: ReplicationGroup
s@ReplicationGroup' {} Maybe ReplicationGroupPendingModifiedValues
a -> ReplicationGroup
s {$sel:pendingModifiedValues:ReplicationGroup' :: Maybe ReplicationGroupPendingModifiedValues
pendingModifiedValues = Maybe ReplicationGroupPendingModifiedValues
a} :: ReplicationGroup)

-- | The name of the Global datastore and role of this replication group in
-- the Global datastore.
replicationGroup_globalReplicationGroupInfo :: Lens.Lens' ReplicationGroup (Prelude.Maybe GlobalReplicationGroupInfo)
replicationGroup_globalReplicationGroupInfo :: (Maybe GlobalReplicationGroupInfo
 -> f (Maybe GlobalReplicationGroupInfo))
-> ReplicationGroup -> f ReplicationGroup
replicationGroup_globalReplicationGroupInfo = (ReplicationGroup -> Maybe GlobalReplicationGroupInfo)
-> (ReplicationGroup
    -> Maybe GlobalReplicationGroupInfo -> ReplicationGroup)
-> Lens
     ReplicationGroup
     ReplicationGroup
     (Maybe GlobalReplicationGroupInfo)
     (Maybe GlobalReplicationGroupInfo)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ReplicationGroup' {Maybe GlobalReplicationGroupInfo
globalReplicationGroupInfo :: Maybe GlobalReplicationGroupInfo
$sel:globalReplicationGroupInfo:ReplicationGroup' :: ReplicationGroup -> Maybe GlobalReplicationGroupInfo
globalReplicationGroupInfo} -> Maybe GlobalReplicationGroupInfo
globalReplicationGroupInfo) (\s :: ReplicationGroup
s@ReplicationGroup' {} Maybe GlobalReplicationGroupInfo
a -> ReplicationGroup
s {$sel:globalReplicationGroupInfo:ReplicationGroup' :: Maybe GlobalReplicationGroupInfo
globalReplicationGroupInfo = Maybe GlobalReplicationGroupInfo
a} :: ReplicationGroup)

-- | The outpost ARNs of the replication group\'s member clusters.
replicationGroup_memberClustersOutpostArns :: Lens.Lens' ReplicationGroup (Prelude.Maybe [Prelude.Text])
replicationGroup_memberClustersOutpostArns :: (Maybe [Text] -> f (Maybe [Text]))
-> ReplicationGroup -> f ReplicationGroup
replicationGroup_memberClustersOutpostArns = (ReplicationGroup -> Maybe [Text])
-> (ReplicationGroup -> Maybe [Text] -> ReplicationGroup)
-> Lens
     ReplicationGroup ReplicationGroup (Maybe [Text]) (Maybe [Text])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ReplicationGroup' {Maybe [Text]
memberClustersOutpostArns :: Maybe [Text]
$sel:memberClustersOutpostArns:ReplicationGroup' :: ReplicationGroup -> Maybe [Text]
memberClustersOutpostArns} -> Maybe [Text]
memberClustersOutpostArns) (\s :: ReplicationGroup
s@ReplicationGroup' {} Maybe [Text]
a -> ReplicationGroup
s {$sel:memberClustersOutpostArns:ReplicationGroup' :: Maybe [Text]
memberClustersOutpostArns = Maybe [Text]
a} :: ReplicationGroup) ((Maybe [Text] -> f (Maybe [Text]))
 -> ReplicationGroup -> f ReplicationGroup)
-> ((Maybe [Text] -> f (Maybe [Text]))
    -> Maybe [Text] -> f (Maybe [Text]))
-> (Maybe [Text] -> f (Maybe [Text]))
-> ReplicationGroup
-> f ReplicationGroup
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso [Text] [Text] [Text] [Text]
-> Iso (Maybe [Text]) (Maybe [Text]) (Maybe [Text]) (Maybe [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 [Text] [Text] [Text] [Text]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | Indicates the status of automatic failover for this Redis replication
-- group.
replicationGroup_automaticFailover :: Lens.Lens' ReplicationGroup (Prelude.Maybe AutomaticFailoverStatus)
replicationGroup_automaticFailover :: (Maybe AutomaticFailoverStatus
 -> f (Maybe AutomaticFailoverStatus))
-> ReplicationGroup -> f ReplicationGroup
replicationGroup_automaticFailover = (ReplicationGroup -> Maybe AutomaticFailoverStatus)
-> (ReplicationGroup
    -> Maybe AutomaticFailoverStatus -> ReplicationGroup)
-> Lens
     ReplicationGroup
     ReplicationGroup
     (Maybe AutomaticFailoverStatus)
     (Maybe AutomaticFailoverStatus)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ReplicationGroup' {Maybe AutomaticFailoverStatus
automaticFailover :: Maybe AutomaticFailoverStatus
$sel:automaticFailover:ReplicationGroup' :: ReplicationGroup -> Maybe AutomaticFailoverStatus
automaticFailover} -> Maybe AutomaticFailoverStatus
automaticFailover) (\s :: ReplicationGroup
s@ReplicationGroup' {} Maybe AutomaticFailoverStatus
a -> ReplicationGroup
s {$sel:automaticFailover:ReplicationGroup' :: Maybe AutomaticFailoverStatus
automaticFailover = Maybe AutomaticFailoverStatus
a} :: ReplicationGroup)

instance Core.FromXML ReplicationGroup where
  parseXML :: [Node] -> Either String ReplicationGroup
parseXML [Node]
x =
    Maybe ISO8601
-> Maybe Text
-> Maybe Text
-> Maybe [NodeGroup]
-> Maybe Text
-> Maybe Bool
-> Maybe Bool
-> Maybe ISO8601
-> Maybe Text
-> Maybe Bool
-> Maybe [Text]
-> Maybe Text
-> Maybe [LogDeliveryConfiguration]
-> Maybe Endpoint
-> Maybe Bool
-> Maybe [Text]
-> Maybe Text
-> Maybe MultiAZStatus
-> Maybe Int
-> Maybe Text
-> Maybe Text
-> Maybe ReplicationGroupPendingModifiedValues
-> Maybe GlobalReplicationGroupInfo
-> Maybe [Text]
-> Maybe AutomaticFailoverStatus
-> ReplicationGroup
ReplicationGroup'
      (Maybe ISO8601
 -> Maybe Text
 -> Maybe Text
 -> Maybe [NodeGroup]
 -> Maybe Text
 -> Maybe Bool
 -> Maybe Bool
 -> Maybe ISO8601
 -> Maybe Text
 -> Maybe Bool
 -> Maybe [Text]
 -> Maybe Text
 -> Maybe [LogDeliveryConfiguration]
 -> Maybe Endpoint
 -> Maybe Bool
 -> Maybe [Text]
 -> Maybe Text
 -> Maybe MultiAZStatus
 -> Maybe Int
 -> Maybe Text
 -> Maybe Text
 -> Maybe ReplicationGroupPendingModifiedValues
 -> Maybe GlobalReplicationGroupInfo
 -> Maybe [Text]
 -> Maybe AutomaticFailoverStatus
 -> ReplicationGroup)
-> Either String (Maybe ISO8601)
-> Either
     String
     (Maybe Text
      -> Maybe Text
      -> Maybe [NodeGroup]
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Bool
      -> Maybe ISO8601
      -> Maybe Text
      -> Maybe Bool
      -> Maybe [Text]
      -> Maybe Text
      -> Maybe [LogDeliveryConfiguration]
      -> Maybe Endpoint
      -> Maybe Bool
      -> Maybe [Text]
      -> Maybe Text
      -> Maybe MultiAZStatus
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe ReplicationGroupPendingModifiedValues
      -> Maybe GlobalReplicationGroupInfo
      -> Maybe [Text]
      -> Maybe AutomaticFailoverStatus
      -> ReplicationGroup)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> ([Node]
x [Node] -> Text -> Either String (Maybe ISO8601)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"AuthTokenLastModifiedDate")
      Either
  String
  (Maybe Text
   -> Maybe Text
   -> Maybe [NodeGroup]
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Bool
   -> Maybe ISO8601
   -> Maybe Text
   -> Maybe Bool
   -> Maybe [Text]
   -> Maybe Text
   -> Maybe [LogDeliveryConfiguration]
   -> Maybe Endpoint
   -> Maybe Bool
   -> Maybe [Text]
   -> Maybe Text
   -> Maybe MultiAZStatus
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe ReplicationGroupPendingModifiedValues
   -> Maybe GlobalReplicationGroupInfo
   -> Maybe [Text]
   -> Maybe AutomaticFailoverStatus
   -> ReplicationGroup)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe Text
      -> Maybe [NodeGroup]
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Bool
      -> Maybe ISO8601
      -> Maybe Text
      -> Maybe Bool
      -> Maybe [Text]
      -> Maybe Text
      -> Maybe [LogDeliveryConfiguration]
      -> Maybe Endpoint
      -> Maybe Bool
      -> Maybe [Text]
      -> Maybe Text
      -> Maybe MultiAZStatus
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe ReplicationGroupPendingModifiedValues
      -> Maybe GlobalReplicationGroupInfo
      -> Maybe [Text]
      -> Maybe AutomaticFailoverStatus
      -> ReplicationGroup)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe Text)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"Status")
      Either
  String
  (Maybe Text
   -> Maybe [NodeGroup]
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Bool
   -> Maybe ISO8601
   -> Maybe Text
   -> Maybe Bool
   -> Maybe [Text]
   -> Maybe Text
   -> Maybe [LogDeliveryConfiguration]
   -> Maybe Endpoint
   -> Maybe Bool
   -> Maybe [Text]
   -> Maybe Text
   -> Maybe MultiAZStatus
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe ReplicationGroupPendingModifiedValues
   -> Maybe GlobalReplicationGroupInfo
   -> Maybe [Text]
   -> Maybe AutomaticFailoverStatus
   -> ReplicationGroup)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe [NodeGroup]
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Bool
      -> Maybe ISO8601
      -> Maybe Text
      -> Maybe Bool
      -> Maybe [Text]
      -> Maybe Text
      -> Maybe [LogDeliveryConfiguration]
      -> Maybe Endpoint
      -> Maybe Bool
      -> Maybe [Text]
      -> Maybe Text
      -> Maybe MultiAZStatus
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe ReplicationGroupPendingModifiedValues
      -> Maybe GlobalReplicationGroupInfo
      -> Maybe [Text]
      -> Maybe AutomaticFailoverStatus
      -> ReplicationGroup)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe Text)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"CacheNodeType")
      Either
  String
  (Maybe [NodeGroup]
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Bool
   -> Maybe ISO8601
   -> Maybe Text
   -> Maybe Bool
   -> Maybe [Text]
   -> Maybe Text
   -> Maybe [LogDeliveryConfiguration]
   -> Maybe Endpoint
   -> Maybe Bool
   -> Maybe [Text]
   -> Maybe Text
   -> Maybe MultiAZStatus
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe ReplicationGroupPendingModifiedValues
   -> Maybe GlobalReplicationGroupInfo
   -> Maybe [Text]
   -> Maybe AutomaticFailoverStatus
   -> ReplicationGroup)
-> Either String (Maybe [NodeGroup])
-> Either
     String
     (Maybe Text
      -> Maybe Bool
      -> Maybe Bool
      -> Maybe ISO8601
      -> Maybe Text
      -> Maybe Bool
      -> Maybe [Text]
      -> Maybe Text
      -> Maybe [LogDeliveryConfiguration]
      -> Maybe Endpoint
      -> Maybe Bool
      -> Maybe [Text]
      -> Maybe Text
      -> Maybe MultiAZStatus
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe ReplicationGroupPendingModifiedValues
      -> Maybe GlobalReplicationGroupInfo
      -> Maybe [Text]
      -> Maybe AutomaticFailoverStatus
      -> ReplicationGroup)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( [Node]
x [Node] -> Text -> Either String (Maybe [Node])
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"NodeGroups" Either String (Maybe [Node]) -> [Node] -> Either String [Node]
forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ [Node]
forall a. Monoid a => a
Prelude.mempty
                      Either String [Node]
-> ([Node] -> Either String (Maybe [NodeGroup]))
-> Either String (Maybe [NodeGroup])
forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b
Prelude.>>= ([Node] -> Either String [NodeGroup])
-> [Node] -> Either String (Maybe [NodeGroup])
forall (f :: * -> *) a b.
Applicative f =>
([a] -> f b) -> [a] -> f (Maybe b)
Core.may (Text -> [Node] -> Either String [NodeGroup]
forall a. FromXML a => Text -> [Node] -> Either String [a]
Core.parseXMLList Text
"NodeGroup")
                  )
      Either
  String
  (Maybe Text
   -> Maybe Bool
   -> Maybe Bool
   -> Maybe ISO8601
   -> Maybe Text
   -> Maybe Bool
   -> Maybe [Text]
   -> Maybe Text
   -> Maybe [LogDeliveryConfiguration]
   -> Maybe Endpoint
   -> Maybe Bool
   -> Maybe [Text]
   -> Maybe Text
   -> Maybe MultiAZStatus
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe ReplicationGroupPendingModifiedValues
   -> Maybe GlobalReplicationGroupInfo
   -> Maybe [Text]
   -> Maybe AutomaticFailoverStatus
   -> ReplicationGroup)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe Bool
      -> Maybe Bool
      -> Maybe ISO8601
      -> Maybe Text
      -> Maybe Bool
      -> Maybe [Text]
      -> Maybe Text
      -> Maybe [LogDeliveryConfiguration]
      -> Maybe Endpoint
      -> Maybe Bool
      -> Maybe [Text]
      -> Maybe Text
      -> Maybe MultiAZStatus
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe ReplicationGroupPendingModifiedValues
      -> Maybe GlobalReplicationGroupInfo
      -> Maybe [Text]
      -> Maybe AutomaticFailoverStatus
      -> ReplicationGroup)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe Text)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"SnapshottingClusterId")
      Either
  String
  (Maybe Bool
   -> Maybe Bool
   -> Maybe ISO8601
   -> Maybe Text
   -> Maybe Bool
   -> Maybe [Text]
   -> Maybe Text
   -> Maybe [LogDeliveryConfiguration]
   -> Maybe Endpoint
   -> Maybe Bool
   -> Maybe [Text]
   -> Maybe Text
   -> Maybe MultiAZStatus
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe ReplicationGroupPendingModifiedValues
   -> Maybe GlobalReplicationGroupInfo
   -> Maybe [Text]
   -> Maybe AutomaticFailoverStatus
   -> ReplicationGroup)
-> Either String (Maybe Bool)
-> Either
     String
     (Maybe Bool
      -> Maybe ISO8601
      -> Maybe Text
      -> Maybe Bool
      -> Maybe [Text]
      -> Maybe Text
      -> Maybe [LogDeliveryConfiguration]
      -> Maybe Endpoint
      -> Maybe Bool
      -> Maybe [Text]
      -> Maybe Text
      -> Maybe MultiAZStatus
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe ReplicationGroupPendingModifiedValues
      -> Maybe GlobalReplicationGroupInfo
      -> Maybe [Text]
      -> Maybe AutomaticFailoverStatus
      -> ReplicationGroup)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe Bool)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"ClusterEnabled")
      Either
  String
  (Maybe Bool
   -> Maybe ISO8601
   -> Maybe Text
   -> Maybe Bool
   -> Maybe [Text]
   -> Maybe Text
   -> Maybe [LogDeliveryConfiguration]
   -> Maybe Endpoint
   -> Maybe Bool
   -> Maybe [Text]
   -> Maybe Text
   -> Maybe MultiAZStatus
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe ReplicationGroupPendingModifiedValues
   -> Maybe GlobalReplicationGroupInfo
   -> Maybe [Text]
   -> Maybe AutomaticFailoverStatus
   -> ReplicationGroup)
-> Either String (Maybe Bool)
-> Either
     String
     (Maybe ISO8601
      -> Maybe Text
      -> Maybe Bool
      -> Maybe [Text]
      -> Maybe Text
      -> Maybe [LogDeliveryConfiguration]
      -> Maybe Endpoint
      -> Maybe Bool
      -> Maybe [Text]
      -> Maybe Text
      -> Maybe MultiAZStatus
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe ReplicationGroupPendingModifiedValues
      -> Maybe GlobalReplicationGroupInfo
      -> Maybe [Text]
      -> Maybe AutomaticFailoverStatus
      -> ReplicationGroup)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe Bool)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"AtRestEncryptionEnabled")
      Either
  String
  (Maybe ISO8601
   -> Maybe Text
   -> Maybe Bool
   -> Maybe [Text]
   -> Maybe Text
   -> Maybe [LogDeliveryConfiguration]
   -> Maybe Endpoint
   -> Maybe Bool
   -> Maybe [Text]
   -> Maybe Text
   -> Maybe MultiAZStatus
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe ReplicationGroupPendingModifiedValues
   -> Maybe GlobalReplicationGroupInfo
   -> Maybe [Text]
   -> Maybe AutomaticFailoverStatus
   -> ReplicationGroup)
-> Either String (Maybe ISO8601)
-> Either
     String
     (Maybe Text
      -> Maybe Bool
      -> Maybe [Text]
      -> Maybe Text
      -> Maybe [LogDeliveryConfiguration]
      -> Maybe Endpoint
      -> Maybe Bool
      -> Maybe [Text]
      -> Maybe Text
      -> Maybe MultiAZStatus
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe ReplicationGroupPendingModifiedValues
      -> Maybe GlobalReplicationGroupInfo
      -> Maybe [Text]
      -> Maybe AutomaticFailoverStatus
      -> ReplicationGroup)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe ISO8601)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"ReplicationGroupCreateTime")
      Either
  String
  (Maybe Text
   -> Maybe Bool
   -> Maybe [Text]
   -> Maybe Text
   -> Maybe [LogDeliveryConfiguration]
   -> Maybe Endpoint
   -> Maybe Bool
   -> Maybe [Text]
   -> Maybe Text
   -> Maybe MultiAZStatus
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe ReplicationGroupPendingModifiedValues
   -> Maybe GlobalReplicationGroupInfo
   -> Maybe [Text]
   -> Maybe AutomaticFailoverStatus
   -> ReplicationGroup)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe Bool
      -> Maybe [Text]
      -> Maybe Text
      -> Maybe [LogDeliveryConfiguration]
      -> Maybe Endpoint
      -> Maybe Bool
      -> Maybe [Text]
      -> Maybe Text
      -> Maybe MultiAZStatus
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe ReplicationGroupPendingModifiedValues
      -> Maybe GlobalReplicationGroupInfo
      -> Maybe [Text]
      -> Maybe AutomaticFailoverStatus
      -> ReplicationGroup)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe Text)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"ARN")
      Either
  String
  (Maybe Bool
   -> Maybe [Text]
   -> Maybe Text
   -> Maybe [LogDeliveryConfiguration]
   -> Maybe Endpoint
   -> Maybe Bool
   -> Maybe [Text]
   -> Maybe Text
   -> Maybe MultiAZStatus
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe ReplicationGroupPendingModifiedValues
   -> Maybe GlobalReplicationGroupInfo
   -> Maybe [Text]
   -> Maybe AutomaticFailoverStatus
   -> ReplicationGroup)
-> Either String (Maybe Bool)
-> Either
     String
     (Maybe [Text]
      -> Maybe Text
      -> Maybe [LogDeliveryConfiguration]
      -> Maybe Endpoint
      -> Maybe Bool
      -> Maybe [Text]
      -> Maybe Text
      -> Maybe MultiAZStatus
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe ReplicationGroupPendingModifiedValues
      -> Maybe GlobalReplicationGroupInfo
      -> Maybe [Text]
      -> Maybe AutomaticFailoverStatus
      -> ReplicationGroup)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe Bool)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"TransitEncryptionEnabled")
      Either
  String
  (Maybe [Text]
   -> Maybe Text
   -> Maybe [LogDeliveryConfiguration]
   -> Maybe Endpoint
   -> Maybe Bool
   -> Maybe [Text]
   -> Maybe Text
   -> Maybe MultiAZStatus
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe ReplicationGroupPendingModifiedValues
   -> Maybe GlobalReplicationGroupInfo
   -> Maybe [Text]
   -> Maybe AutomaticFailoverStatus
   -> ReplicationGroup)
-> Either String (Maybe [Text])
-> Either
     String
     (Maybe Text
      -> Maybe [LogDeliveryConfiguration]
      -> Maybe Endpoint
      -> Maybe Bool
      -> Maybe [Text]
      -> Maybe Text
      -> Maybe MultiAZStatus
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe ReplicationGroupPendingModifiedValues
      -> Maybe GlobalReplicationGroupInfo
      -> Maybe [Text]
      -> Maybe AutomaticFailoverStatus
      -> ReplicationGroup)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( [Node]
x [Node] -> Text -> Either String (Maybe [Node])
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"UserGroupIds" Either String (Maybe [Node]) -> [Node] -> Either String [Node]
forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ [Node]
forall a. Monoid a => a
Prelude.mempty
                      Either String [Node]
-> ([Node] -> Either String (Maybe [Text]))
-> Either String (Maybe [Text])
forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b
Prelude.>>= ([Node] -> Either String [Text])
-> [Node] -> Either String (Maybe [Text])
forall (f :: * -> *) a b.
Applicative f =>
([a] -> f b) -> [a] -> f (Maybe b)
Core.may (Text -> [Node] -> Either String [Text]
forall a. FromXML a => Text -> [Node] -> Either String [a]
Core.parseXMLList Text
"member")
                  )
      Either
  String
  (Maybe Text
   -> Maybe [LogDeliveryConfiguration]
   -> Maybe Endpoint
   -> Maybe Bool
   -> Maybe [Text]
   -> Maybe Text
   -> Maybe MultiAZStatus
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe ReplicationGroupPendingModifiedValues
   -> Maybe GlobalReplicationGroupInfo
   -> Maybe [Text]
   -> Maybe AutomaticFailoverStatus
   -> ReplicationGroup)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe [LogDeliveryConfiguration]
      -> Maybe Endpoint
      -> Maybe Bool
      -> Maybe [Text]
      -> Maybe Text
      -> Maybe MultiAZStatus
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe ReplicationGroupPendingModifiedValues
      -> Maybe GlobalReplicationGroupInfo
      -> Maybe [Text]
      -> Maybe AutomaticFailoverStatus
      -> ReplicationGroup)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe Text)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"SnapshotWindow")
      Either
  String
  (Maybe [LogDeliveryConfiguration]
   -> Maybe Endpoint
   -> Maybe Bool
   -> Maybe [Text]
   -> Maybe Text
   -> Maybe MultiAZStatus
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe ReplicationGroupPendingModifiedValues
   -> Maybe GlobalReplicationGroupInfo
   -> Maybe [Text]
   -> Maybe AutomaticFailoverStatus
   -> ReplicationGroup)
-> Either String (Maybe [LogDeliveryConfiguration])
-> Either
     String
     (Maybe Endpoint
      -> Maybe Bool
      -> Maybe [Text]
      -> Maybe Text
      -> Maybe MultiAZStatus
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe ReplicationGroupPendingModifiedValues
      -> Maybe GlobalReplicationGroupInfo
      -> Maybe [Text]
      -> Maybe AutomaticFailoverStatus
      -> ReplicationGroup)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( [Node]
x [Node] -> Text -> Either String (Maybe [Node])
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"LogDeliveryConfigurations"
                      Either String (Maybe [Node]) -> [Node] -> Either String [Node]
forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ [Node]
forall a. Monoid a => a
Prelude.mempty
                      Either String [Node]
-> ([Node] -> Either String (Maybe [LogDeliveryConfiguration]))
-> Either String (Maybe [LogDeliveryConfiguration])
forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b
Prelude.>>= ([Node] -> Either String [LogDeliveryConfiguration])
-> [Node] -> Either String (Maybe [LogDeliveryConfiguration])
forall (f :: * -> *) a b.
Applicative f =>
([a] -> f b) -> [a] -> f (Maybe b)
Core.may
                        (Text -> [Node] -> Either String [LogDeliveryConfiguration]
forall a. FromXML a => Text -> [Node] -> Either String [a]
Core.parseXMLList Text
"LogDeliveryConfiguration")
                  )
      Either
  String
  (Maybe Endpoint
   -> Maybe Bool
   -> Maybe [Text]
   -> Maybe Text
   -> Maybe MultiAZStatus
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe ReplicationGroupPendingModifiedValues
   -> Maybe GlobalReplicationGroupInfo
   -> Maybe [Text]
   -> Maybe AutomaticFailoverStatus
   -> ReplicationGroup)
-> Either String (Maybe Endpoint)
-> Either
     String
     (Maybe Bool
      -> Maybe [Text]
      -> Maybe Text
      -> Maybe MultiAZStatus
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe ReplicationGroupPendingModifiedValues
      -> Maybe GlobalReplicationGroupInfo
      -> Maybe [Text]
      -> Maybe AutomaticFailoverStatus
      -> ReplicationGroup)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe Endpoint)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"ConfigurationEndpoint")
      Either
  String
  (Maybe Bool
   -> Maybe [Text]
   -> Maybe Text
   -> Maybe MultiAZStatus
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe ReplicationGroupPendingModifiedValues
   -> Maybe GlobalReplicationGroupInfo
   -> Maybe [Text]
   -> Maybe AutomaticFailoverStatus
   -> ReplicationGroup)
-> Either String (Maybe Bool)
-> Either
     String
     (Maybe [Text]
      -> Maybe Text
      -> Maybe MultiAZStatus
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe ReplicationGroupPendingModifiedValues
      -> Maybe GlobalReplicationGroupInfo
      -> Maybe [Text]
      -> Maybe AutomaticFailoverStatus
      -> ReplicationGroup)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe Bool)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"AuthTokenEnabled")
      Either
  String
  (Maybe [Text]
   -> Maybe Text
   -> Maybe MultiAZStatus
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe ReplicationGroupPendingModifiedValues
   -> Maybe GlobalReplicationGroupInfo
   -> Maybe [Text]
   -> Maybe AutomaticFailoverStatus
   -> ReplicationGroup)
-> Either String (Maybe [Text])
-> Either
     String
     (Maybe Text
      -> Maybe MultiAZStatus
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe ReplicationGroupPendingModifiedValues
      -> Maybe GlobalReplicationGroupInfo
      -> Maybe [Text]
      -> Maybe AutomaticFailoverStatus
      -> ReplicationGroup)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( [Node]
x [Node] -> Text -> Either String (Maybe [Node])
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"MemberClusters" Either String (Maybe [Node]) -> [Node] -> Either String [Node]
forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ [Node]
forall a. Monoid a => a
Prelude.mempty
                      Either String [Node]
-> ([Node] -> Either String (Maybe [Text]))
-> Either String (Maybe [Text])
forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b
Prelude.>>= ([Node] -> Either String [Text])
-> [Node] -> Either String (Maybe [Text])
forall (f :: * -> *) a b.
Applicative f =>
([a] -> f b) -> [a] -> f (Maybe b)
Core.may (Text -> [Node] -> Either String [Text]
forall a. FromXML a => Text -> [Node] -> Either String [a]
Core.parseXMLList Text
"ClusterId")
                  )
      Either
  String
  (Maybe Text
   -> Maybe MultiAZStatus
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe ReplicationGroupPendingModifiedValues
   -> Maybe GlobalReplicationGroupInfo
   -> Maybe [Text]
   -> Maybe AutomaticFailoverStatus
   -> ReplicationGroup)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe MultiAZStatus
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe ReplicationGroupPendingModifiedValues
      -> Maybe GlobalReplicationGroupInfo
      -> Maybe [Text]
      -> Maybe AutomaticFailoverStatus
      -> ReplicationGroup)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe Text)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"KmsKeyId")
      Either
  String
  (Maybe MultiAZStatus
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe ReplicationGroupPendingModifiedValues
   -> Maybe GlobalReplicationGroupInfo
   -> Maybe [Text]
   -> Maybe AutomaticFailoverStatus
   -> ReplicationGroup)
-> Either String (Maybe MultiAZStatus)
-> Either
     String
     (Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe ReplicationGroupPendingModifiedValues
      -> Maybe GlobalReplicationGroupInfo
      -> Maybe [Text]
      -> Maybe AutomaticFailoverStatus
      -> ReplicationGroup)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe MultiAZStatus)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"MultiAZ")
      Either
  String
  (Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe ReplicationGroupPendingModifiedValues
   -> Maybe GlobalReplicationGroupInfo
   -> Maybe [Text]
   -> Maybe AutomaticFailoverStatus
   -> ReplicationGroup)
-> Either String (Maybe Int)
-> Either
     String
     (Maybe Text
      -> Maybe Text
      -> Maybe ReplicationGroupPendingModifiedValues
      -> Maybe GlobalReplicationGroupInfo
      -> Maybe [Text]
      -> Maybe AutomaticFailoverStatus
      -> ReplicationGroup)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe Int)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"SnapshotRetentionLimit")
      Either
  String
  (Maybe Text
   -> Maybe Text
   -> Maybe ReplicationGroupPendingModifiedValues
   -> Maybe GlobalReplicationGroupInfo
   -> Maybe [Text]
   -> Maybe AutomaticFailoverStatus
   -> ReplicationGroup)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe Text
      -> Maybe ReplicationGroupPendingModifiedValues
      -> Maybe GlobalReplicationGroupInfo
      -> Maybe [Text]
      -> Maybe AutomaticFailoverStatus
      -> ReplicationGroup)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe Text)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"Description")
      Either
  String
  (Maybe Text
   -> Maybe ReplicationGroupPendingModifiedValues
   -> Maybe GlobalReplicationGroupInfo
   -> Maybe [Text]
   -> Maybe AutomaticFailoverStatus
   -> ReplicationGroup)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe ReplicationGroupPendingModifiedValues
      -> Maybe GlobalReplicationGroupInfo
      -> Maybe [Text]
      -> Maybe AutomaticFailoverStatus
      -> ReplicationGroup)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe Text)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"ReplicationGroupId")
      Either
  String
  (Maybe ReplicationGroupPendingModifiedValues
   -> Maybe GlobalReplicationGroupInfo
   -> Maybe [Text]
   -> Maybe AutomaticFailoverStatus
   -> ReplicationGroup)
-> Either String (Maybe ReplicationGroupPendingModifiedValues)
-> Either
     String
     (Maybe GlobalReplicationGroupInfo
      -> Maybe [Text]
      -> Maybe AutomaticFailoverStatus
      -> ReplicationGroup)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node]
-> Text
-> Either String (Maybe ReplicationGroupPendingModifiedValues)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"PendingModifiedValues")
      Either
  String
  (Maybe GlobalReplicationGroupInfo
   -> Maybe [Text]
   -> Maybe AutomaticFailoverStatus
   -> ReplicationGroup)
-> Either String (Maybe GlobalReplicationGroupInfo)
-> Either
     String
     (Maybe [Text] -> Maybe AutomaticFailoverStatus -> ReplicationGroup)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe GlobalReplicationGroupInfo)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"GlobalReplicationGroupInfo")
      Either
  String
  (Maybe [Text] -> Maybe AutomaticFailoverStatus -> ReplicationGroup)
-> Either String (Maybe [Text])
-> Either
     String (Maybe AutomaticFailoverStatus -> ReplicationGroup)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( [Node]
x [Node] -> Text -> Either String (Maybe [Node])
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"MemberClustersOutpostArns"
                      Either String (Maybe [Node]) -> [Node] -> Either String [Node]
forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ [Node]
forall a. Monoid a => a
Prelude.mempty
                      Either String [Node]
-> ([Node] -> Either String (Maybe [Text]))
-> Either String (Maybe [Text])
forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b
Prelude.>>= ([Node] -> Either String [Text])
-> [Node] -> Either String (Maybe [Text])
forall (f :: * -> *) a b.
Applicative f =>
([a] -> f b) -> [a] -> f (Maybe b)
Core.may
                        (Text -> [Node] -> Either String [Text]
forall a. FromXML a => Text -> [Node] -> Either String [a]
Core.parseXMLList Text
"ReplicationGroupOutpostArn")
                  )
      Either String (Maybe AutomaticFailoverStatus -> ReplicationGroup)
-> Either String (Maybe AutomaticFailoverStatus)
-> Either String ReplicationGroup
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe AutomaticFailoverStatus)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"AutomaticFailover")

instance Prelude.Hashable ReplicationGroup

instance Prelude.NFData ReplicationGroup