{-# 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.ReplicationGroupPendingModifiedValues
-- 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.ReplicationGroupPendingModifiedValues where

import qualified Amazonka.Core as Core
import Amazonka.ElastiCache.Types.AuthTokenUpdateStatus
import Amazonka.ElastiCache.Types.PendingAutomaticFailoverStatus
import Amazonka.ElastiCache.Types.PendingLogDeliveryConfiguration
import Amazonka.ElastiCache.Types.ReshardingStatus
import Amazonka.ElastiCache.Types.UserGroupsUpdateStatus
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude

-- | The settings to be applied to the Redis replication group, either
-- immediately or during the next maintenance window.
--
-- /See:/ 'newReplicationGroupPendingModifiedValues' smart constructor.
data ReplicationGroupPendingModifiedValues = ReplicationGroupPendingModifiedValues'
  { -- | The auth token status
    ReplicationGroupPendingModifiedValues
-> Maybe AuthTokenUpdateStatus
authTokenStatus :: Prelude.Maybe AuthTokenUpdateStatus,
    -- | The user group being modified.
    ReplicationGroupPendingModifiedValues
-> Maybe UserGroupsUpdateStatus
userGroups :: Prelude.Maybe UserGroupsUpdateStatus,
    -- | The log delivery configurations being modified
    ReplicationGroupPendingModifiedValues
-> Maybe [PendingLogDeliveryConfiguration]
logDeliveryConfigurations :: Prelude.Maybe [PendingLogDeliveryConfiguration],
    -- | The status of an online resharding operation.
    ReplicationGroupPendingModifiedValues -> Maybe ReshardingStatus
resharding :: Prelude.Maybe ReshardingStatus,
    -- | The primary cluster ID that is applied immediately (if
    -- @--apply-immediately@ was specified), or during the next maintenance
    -- window.
    ReplicationGroupPendingModifiedValues -> Maybe Text
primaryClusterId :: Prelude.Maybe Prelude.Text,
    -- | Indicates the status of automatic failover for this Redis replication
    -- group.
    ReplicationGroupPendingModifiedValues
-> Maybe PendingAutomaticFailoverStatus
automaticFailoverStatus :: Prelude.Maybe PendingAutomaticFailoverStatus
  }
  deriving (ReplicationGroupPendingModifiedValues
-> ReplicationGroupPendingModifiedValues -> Bool
(ReplicationGroupPendingModifiedValues
 -> ReplicationGroupPendingModifiedValues -> Bool)
-> (ReplicationGroupPendingModifiedValues
    -> ReplicationGroupPendingModifiedValues -> Bool)
-> Eq ReplicationGroupPendingModifiedValues
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: ReplicationGroupPendingModifiedValues
-> ReplicationGroupPendingModifiedValues -> Bool
$c/= :: ReplicationGroupPendingModifiedValues
-> ReplicationGroupPendingModifiedValues -> Bool
== :: ReplicationGroupPendingModifiedValues
-> ReplicationGroupPendingModifiedValues -> Bool
$c== :: ReplicationGroupPendingModifiedValues
-> ReplicationGroupPendingModifiedValues -> Bool
Prelude.Eq, ReadPrec [ReplicationGroupPendingModifiedValues]
ReadPrec ReplicationGroupPendingModifiedValues
Int -> ReadS ReplicationGroupPendingModifiedValues
ReadS [ReplicationGroupPendingModifiedValues]
(Int -> ReadS ReplicationGroupPendingModifiedValues)
-> ReadS [ReplicationGroupPendingModifiedValues]
-> ReadPrec ReplicationGroupPendingModifiedValues
-> ReadPrec [ReplicationGroupPendingModifiedValues]
-> Read ReplicationGroupPendingModifiedValues
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [ReplicationGroupPendingModifiedValues]
$creadListPrec :: ReadPrec [ReplicationGroupPendingModifiedValues]
readPrec :: ReadPrec ReplicationGroupPendingModifiedValues
$creadPrec :: ReadPrec ReplicationGroupPendingModifiedValues
readList :: ReadS [ReplicationGroupPendingModifiedValues]
$creadList :: ReadS [ReplicationGroupPendingModifiedValues]
readsPrec :: Int -> ReadS ReplicationGroupPendingModifiedValues
$creadsPrec :: Int -> ReadS ReplicationGroupPendingModifiedValues
Prelude.Read, Int -> ReplicationGroupPendingModifiedValues -> ShowS
[ReplicationGroupPendingModifiedValues] -> ShowS
ReplicationGroupPendingModifiedValues -> String
(Int -> ReplicationGroupPendingModifiedValues -> ShowS)
-> (ReplicationGroupPendingModifiedValues -> String)
-> ([ReplicationGroupPendingModifiedValues] -> ShowS)
-> Show ReplicationGroupPendingModifiedValues
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [ReplicationGroupPendingModifiedValues] -> ShowS
$cshowList :: [ReplicationGroupPendingModifiedValues] -> ShowS
show :: ReplicationGroupPendingModifiedValues -> String
$cshow :: ReplicationGroupPendingModifiedValues -> String
showsPrec :: Int -> ReplicationGroupPendingModifiedValues -> ShowS
$cshowsPrec :: Int -> ReplicationGroupPendingModifiedValues -> ShowS
Prelude.Show, (forall x.
 ReplicationGroupPendingModifiedValues
 -> Rep ReplicationGroupPendingModifiedValues x)
-> (forall x.
    Rep ReplicationGroupPendingModifiedValues x
    -> ReplicationGroupPendingModifiedValues)
-> Generic ReplicationGroupPendingModifiedValues
forall x.
Rep ReplicationGroupPendingModifiedValues x
-> ReplicationGroupPendingModifiedValues
forall x.
ReplicationGroupPendingModifiedValues
-> Rep ReplicationGroupPendingModifiedValues x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep ReplicationGroupPendingModifiedValues x
-> ReplicationGroupPendingModifiedValues
$cfrom :: forall x.
ReplicationGroupPendingModifiedValues
-> Rep ReplicationGroupPendingModifiedValues x
Prelude.Generic)

-- |
-- Create a value of 'ReplicationGroupPendingModifiedValues' 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:
--
-- 'authTokenStatus', 'replicationGroupPendingModifiedValues_authTokenStatus' - The auth token status
--
-- 'userGroups', 'replicationGroupPendingModifiedValues_userGroups' - The user group being modified.
--
-- 'logDeliveryConfigurations', 'replicationGroupPendingModifiedValues_logDeliveryConfigurations' - The log delivery configurations being modified
--
-- 'resharding', 'replicationGroupPendingModifiedValues_resharding' - The status of an online resharding operation.
--
-- 'primaryClusterId', 'replicationGroupPendingModifiedValues_primaryClusterId' - The primary cluster ID that is applied immediately (if
-- @--apply-immediately@ was specified), or during the next maintenance
-- window.
--
-- 'automaticFailoverStatus', 'replicationGroupPendingModifiedValues_automaticFailoverStatus' - Indicates the status of automatic failover for this Redis replication
-- group.
newReplicationGroupPendingModifiedValues ::
  ReplicationGroupPendingModifiedValues
newReplicationGroupPendingModifiedValues :: ReplicationGroupPendingModifiedValues
newReplicationGroupPendingModifiedValues =
  ReplicationGroupPendingModifiedValues' :: Maybe AuthTokenUpdateStatus
-> Maybe UserGroupsUpdateStatus
-> Maybe [PendingLogDeliveryConfiguration]
-> Maybe ReshardingStatus
-> Maybe Text
-> Maybe PendingAutomaticFailoverStatus
-> ReplicationGroupPendingModifiedValues
ReplicationGroupPendingModifiedValues'
    { $sel:authTokenStatus:ReplicationGroupPendingModifiedValues' :: Maybe AuthTokenUpdateStatus
authTokenStatus =
        Maybe AuthTokenUpdateStatus
forall a. Maybe a
Prelude.Nothing,
      $sel:userGroups:ReplicationGroupPendingModifiedValues' :: Maybe UserGroupsUpdateStatus
userGroups = Maybe UserGroupsUpdateStatus
forall a. Maybe a
Prelude.Nothing,
      $sel:logDeliveryConfigurations:ReplicationGroupPendingModifiedValues' :: Maybe [PendingLogDeliveryConfiguration]
logDeliveryConfigurations =
        Maybe [PendingLogDeliveryConfiguration]
forall a. Maybe a
Prelude.Nothing,
      $sel:resharding:ReplicationGroupPendingModifiedValues' :: Maybe ReshardingStatus
resharding = Maybe ReshardingStatus
forall a. Maybe a
Prelude.Nothing,
      $sel:primaryClusterId:ReplicationGroupPendingModifiedValues' :: Maybe Text
primaryClusterId = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:automaticFailoverStatus:ReplicationGroupPendingModifiedValues' :: Maybe PendingAutomaticFailoverStatus
automaticFailoverStatus =
        Maybe PendingAutomaticFailoverStatus
forall a. Maybe a
Prelude.Nothing
    }

-- | The auth token status
replicationGroupPendingModifiedValues_authTokenStatus :: Lens.Lens' ReplicationGroupPendingModifiedValues (Prelude.Maybe AuthTokenUpdateStatus)
replicationGroupPendingModifiedValues_authTokenStatus :: (Maybe AuthTokenUpdateStatus -> f (Maybe AuthTokenUpdateStatus))
-> ReplicationGroupPendingModifiedValues
-> f ReplicationGroupPendingModifiedValues
replicationGroupPendingModifiedValues_authTokenStatus = (ReplicationGroupPendingModifiedValues
 -> Maybe AuthTokenUpdateStatus)
-> (ReplicationGroupPendingModifiedValues
    -> Maybe AuthTokenUpdateStatus
    -> ReplicationGroupPendingModifiedValues)
-> Lens
     ReplicationGroupPendingModifiedValues
     ReplicationGroupPendingModifiedValues
     (Maybe AuthTokenUpdateStatus)
     (Maybe AuthTokenUpdateStatus)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ReplicationGroupPendingModifiedValues' {Maybe AuthTokenUpdateStatus
authTokenStatus :: Maybe AuthTokenUpdateStatus
$sel:authTokenStatus:ReplicationGroupPendingModifiedValues' :: ReplicationGroupPendingModifiedValues
-> Maybe AuthTokenUpdateStatus
authTokenStatus} -> Maybe AuthTokenUpdateStatus
authTokenStatus) (\s :: ReplicationGroupPendingModifiedValues
s@ReplicationGroupPendingModifiedValues' {} Maybe AuthTokenUpdateStatus
a -> ReplicationGroupPendingModifiedValues
s {$sel:authTokenStatus:ReplicationGroupPendingModifiedValues' :: Maybe AuthTokenUpdateStatus
authTokenStatus = Maybe AuthTokenUpdateStatus
a} :: ReplicationGroupPendingModifiedValues)

-- | The user group being modified.
replicationGroupPendingModifiedValues_userGroups :: Lens.Lens' ReplicationGroupPendingModifiedValues (Prelude.Maybe UserGroupsUpdateStatus)
replicationGroupPendingModifiedValues_userGroups :: (Maybe UserGroupsUpdateStatus -> f (Maybe UserGroupsUpdateStatus))
-> ReplicationGroupPendingModifiedValues
-> f ReplicationGroupPendingModifiedValues
replicationGroupPendingModifiedValues_userGroups = (ReplicationGroupPendingModifiedValues
 -> Maybe UserGroupsUpdateStatus)
-> (ReplicationGroupPendingModifiedValues
    -> Maybe UserGroupsUpdateStatus
    -> ReplicationGroupPendingModifiedValues)
-> Lens
     ReplicationGroupPendingModifiedValues
     ReplicationGroupPendingModifiedValues
     (Maybe UserGroupsUpdateStatus)
     (Maybe UserGroupsUpdateStatus)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ReplicationGroupPendingModifiedValues' {Maybe UserGroupsUpdateStatus
userGroups :: Maybe UserGroupsUpdateStatus
$sel:userGroups:ReplicationGroupPendingModifiedValues' :: ReplicationGroupPendingModifiedValues
-> Maybe UserGroupsUpdateStatus
userGroups} -> Maybe UserGroupsUpdateStatus
userGroups) (\s :: ReplicationGroupPendingModifiedValues
s@ReplicationGroupPendingModifiedValues' {} Maybe UserGroupsUpdateStatus
a -> ReplicationGroupPendingModifiedValues
s {$sel:userGroups:ReplicationGroupPendingModifiedValues' :: Maybe UserGroupsUpdateStatus
userGroups = Maybe UserGroupsUpdateStatus
a} :: ReplicationGroupPendingModifiedValues)

-- | The log delivery configurations being modified
replicationGroupPendingModifiedValues_logDeliveryConfigurations :: Lens.Lens' ReplicationGroupPendingModifiedValues (Prelude.Maybe [PendingLogDeliveryConfiguration])
replicationGroupPendingModifiedValues_logDeliveryConfigurations :: (Maybe [PendingLogDeliveryConfiguration]
 -> f (Maybe [PendingLogDeliveryConfiguration]))
-> ReplicationGroupPendingModifiedValues
-> f ReplicationGroupPendingModifiedValues
replicationGroupPendingModifiedValues_logDeliveryConfigurations = (ReplicationGroupPendingModifiedValues
 -> Maybe [PendingLogDeliveryConfiguration])
-> (ReplicationGroupPendingModifiedValues
    -> Maybe [PendingLogDeliveryConfiguration]
    -> ReplicationGroupPendingModifiedValues)
-> Lens
     ReplicationGroupPendingModifiedValues
     ReplicationGroupPendingModifiedValues
     (Maybe [PendingLogDeliveryConfiguration])
     (Maybe [PendingLogDeliveryConfiguration])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ReplicationGroupPendingModifiedValues' {Maybe [PendingLogDeliveryConfiguration]
logDeliveryConfigurations :: Maybe [PendingLogDeliveryConfiguration]
$sel:logDeliveryConfigurations:ReplicationGroupPendingModifiedValues' :: ReplicationGroupPendingModifiedValues
-> Maybe [PendingLogDeliveryConfiguration]
logDeliveryConfigurations} -> Maybe [PendingLogDeliveryConfiguration]
logDeliveryConfigurations) (\s :: ReplicationGroupPendingModifiedValues
s@ReplicationGroupPendingModifiedValues' {} Maybe [PendingLogDeliveryConfiguration]
a -> ReplicationGroupPendingModifiedValues
s {$sel:logDeliveryConfigurations:ReplicationGroupPendingModifiedValues' :: Maybe [PendingLogDeliveryConfiguration]
logDeliveryConfigurations = Maybe [PendingLogDeliveryConfiguration]
a} :: ReplicationGroupPendingModifiedValues) ((Maybe [PendingLogDeliveryConfiguration]
  -> f (Maybe [PendingLogDeliveryConfiguration]))
 -> ReplicationGroupPendingModifiedValues
 -> f ReplicationGroupPendingModifiedValues)
-> ((Maybe [PendingLogDeliveryConfiguration]
     -> f (Maybe [PendingLogDeliveryConfiguration]))
    -> Maybe [PendingLogDeliveryConfiguration]
    -> f (Maybe [PendingLogDeliveryConfiguration]))
-> (Maybe [PendingLogDeliveryConfiguration]
    -> f (Maybe [PendingLogDeliveryConfiguration]))
-> ReplicationGroupPendingModifiedValues
-> f ReplicationGroupPendingModifiedValues
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
  [PendingLogDeliveryConfiguration]
  [PendingLogDeliveryConfiguration]
  [PendingLogDeliveryConfiguration]
  [PendingLogDeliveryConfiguration]
-> Iso
     (Maybe [PendingLogDeliveryConfiguration])
     (Maybe [PendingLogDeliveryConfiguration])
     (Maybe [PendingLogDeliveryConfiguration])
     (Maybe [PendingLogDeliveryConfiguration])
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
  [PendingLogDeliveryConfiguration]
  [PendingLogDeliveryConfiguration]
  [PendingLogDeliveryConfiguration]
  [PendingLogDeliveryConfiguration]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | The status of an online resharding operation.
replicationGroupPendingModifiedValues_resharding :: Lens.Lens' ReplicationGroupPendingModifiedValues (Prelude.Maybe ReshardingStatus)
replicationGroupPendingModifiedValues_resharding :: (Maybe ReshardingStatus -> f (Maybe ReshardingStatus))
-> ReplicationGroupPendingModifiedValues
-> f ReplicationGroupPendingModifiedValues
replicationGroupPendingModifiedValues_resharding = (ReplicationGroupPendingModifiedValues -> Maybe ReshardingStatus)
-> (ReplicationGroupPendingModifiedValues
    -> Maybe ReshardingStatus -> ReplicationGroupPendingModifiedValues)
-> Lens
     ReplicationGroupPendingModifiedValues
     ReplicationGroupPendingModifiedValues
     (Maybe ReshardingStatus)
     (Maybe ReshardingStatus)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ReplicationGroupPendingModifiedValues' {Maybe ReshardingStatus
resharding :: Maybe ReshardingStatus
$sel:resharding:ReplicationGroupPendingModifiedValues' :: ReplicationGroupPendingModifiedValues -> Maybe ReshardingStatus
resharding} -> Maybe ReshardingStatus
resharding) (\s :: ReplicationGroupPendingModifiedValues
s@ReplicationGroupPendingModifiedValues' {} Maybe ReshardingStatus
a -> ReplicationGroupPendingModifiedValues
s {$sel:resharding:ReplicationGroupPendingModifiedValues' :: Maybe ReshardingStatus
resharding = Maybe ReshardingStatus
a} :: ReplicationGroupPendingModifiedValues)

-- | The primary cluster ID that is applied immediately (if
-- @--apply-immediately@ was specified), or during the next maintenance
-- window.
replicationGroupPendingModifiedValues_primaryClusterId :: Lens.Lens' ReplicationGroupPendingModifiedValues (Prelude.Maybe Prelude.Text)
replicationGroupPendingModifiedValues_primaryClusterId :: (Maybe Text -> f (Maybe Text))
-> ReplicationGroupPendingModifiedValues
-> f ReplicationGroupPendingModifiedValues
replicationGroupPendingModifiedValues_primaryClusterId = (ReplicationGroupPendingModifiedValues -> Maybe Text)
-> (ReplicationGroupPendingModifiedValues
    -> Maybe Text -> ReplicationGroupPendingModifiedValues)
-> Lens
     ReplicationGroupPendingModifiedValues
     ReplicationGroupPendingModifiedValues
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\ReplicationGroupPendingModifiedValues' {Maybe Text
primaryClusterId :: Maybe Text
$sel:primaryClusterId:ReplicationGroupPendingModifiedValues' :: ReplicationGroupPendingModifiedValues -> Maybe Text
primaryClusterId} -> Maybe Text
primaryClusterId) (\s :: ReplicationGroupPendingModifiedValues
s@ReplicationGroupPendingModifiedValues' {} Maybe Text
a -> ReplicationGroupPendingModifiedValues
s {$sel:primaryClusterId:ReplicationGroupPendingModifiedValues' :: Maybe Text
primaryClusterId = Maybe Text
a} :: ReplicationGroupPendingModifiedValues)

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

instance
  Core.FromXML
    ReplicationGroupPendingModifiedValues
  where
  parseXML :: [Node] -> Either String ReplicationGroupPendingModifiedValues
parseXML [Node]
x =
    Maybe AuthTokenUpdateStatus
-> Maybe UserGroupsUpdateStatus
-> Maybe [PendingLogDeliveryConfiguration]
-> Maybe ReshardingStatus
-> Maybe Text
-> Maybe PendingAutomaticFailoverStatus
-> ReplicationGroupPendingModifiedValues
ReplicationGroupPendingModifiedValues'
      (Maybe AuthTokenUpdateStatus
 -> Maybe UserGroupsUpdateStatus
 -> Maybe [PendingLogDeliveryConfiguration]
 -> Maybe ReshardingStatus
 -> Maybe Text
 -> Maybe PendingAutomaticFailoverStatus
 -> ReplicationGroupPendingModifiedValues)
-> Either String (Maybe AuthTokenUpdateStatus)
-> Either
     String
     (Maybe UserGroupsUpdateStatus
      -> Maybe [PendingLogDeliveryConfiguration]
      -> Maybe ReshardingStatus
      -> Maybe Text
      -> Maybe PendingAutomaticFailoverStatus
      -> ReplicationGroupPendingModifiedValues)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> ([Node]
x [Node] -> Text -> Either String (Maybe AuthTokenUpdateStatus)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"AuthTokenStatus")
      Either
  String
  (Maybe UserGroupsUpdateStatus
   -> Maybe [PendingLogDeliveryConfiguration]
   -> Maybe ReshardingStatus
   -> Maybe Text
   -> Maybe PendingAutomaticFailoverStatus
   -> ReplicationGroupPendingModifiedValues)
-> Either String (Maybe UserGroupsUpdateStatus)
-> Either
     String
     (Maybe [PendingLogDeliveryConfiguration]
      -> Maybe ReshardingStatus
      -> Maybe Text
      -> Maybe PendingAutomaticFailoverStatus
      -> ReplicationGroupPendingModifiedValues)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe UserGroupsUpdateStatus)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"UserGroups")
      Either
  String
  (Maybe [PendingLogDeliveryConfiguration]
   -> Maybe ReshardingStatus
   -> Maybe Text
   -> Maybe PendingAutomaticFailoverStatus
   -> ReplicationGroupPendingModifiedValues)
-> Either String (Maybe [PendingLogDeliveryConfiguration])
-> Either
     String
     (Maybe ReshardingStatus
      -> Maybe Text
      -> Maybe PendingAutomaticFailoverStatus
      -> ReplicationGroupPendingModifiedValues)
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 [PendingLogDeliveryConfiguration]))
-> Either String (Maybe [PendingLogDeliveryConfiguration])
forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b
Prelude.>>= ([Node] -> Either String [PendingLogDeliveryConfiguration])
-> [Node]
-> Either String (Maybe [PendingLogDeliveryConfiguration])
forall (f :: * -> *) a b.
Applicative f =>
([a] -> f b) -> [a] -> f (Maybe b)
Core.may (Text -> [Node] -> Either String [PendingLogDeliveryConfiguration]
forall a. FromXML a => Text -> [Node] -> Either String [a]
Core.parseXMLList Text
"member")
                  )
      Either
  String
  (Maybe ReshardingStatus
   -> Maybe Text
   -> Maybe PendingAutomaticFailoverStatus
   -> ReplicationGroupPendingModifiedValues)
-> Either String (Maybe ReshardingStatus)
-> Either
     String
     (Maybe Text
      -> Maybe PendingAutomaticFailoverStatus
      -> ReplicationGroupPendingModifiedValues)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe ReshardingStatus)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"Resharding")
      Either
  String
  (Maybe Text
   -> Maybe PendingAutomaticFailoverStatus
   -> ReplicationGroupPendingModifiedValues)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe PendingAutomaticFailoverStatus
      -> ReplicationGroupPendingModifiedValues)
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
"PrimaryClusterId")
      Either
  String
  (Maybe PendingAutomaticFailoverStatus
   -> ReplicationGroupPendingModifiedValues)
-> Either String (Maybe PendingAutomaticFailoverStatus)
-> Either String ReplicationGroupPendingModifiedValues
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node]
-> Text -> Either String (Maybe PendingAutomaticFailoverStatus)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"AutomaticFailoverStatus")

instance
  Prelude.Hashable
    ReplicationGroupPendingModifiedValues

instance
  Prelude.NFData
    ReplicationGroupPendingModifiedValues