{-# 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.RDS.Types.DBInstanceAutomatedBackup
-- 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.RDS.Types.DBInstanceAutomatedBackup where

import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
import Amazonka.RDS.Types.DBInstanceAutomatedBackupsReplication
import Amazonka.RDS.Types.RestoreWindow

-- | An automated backup of a DB instance. It consists of system backups,
-- transaction logs, and the database instance properties that existed at
-- the time you deleted the source instance.
--
-- /See:/ 'newDBInstanceAutomatedBackup' smart constructor.
data DBInstanceAutomatedBackup = DBInstanceAutomatedBackup'
  { -- | Earliest and latest time an instance can be restored to.
    DBInstanceAutomatedBackup -> Maybe RestoreWindow
restoreWindow :: Prelude.Maybe RestoreWindow,
    -- | The version of the database engine for the automated backup.
    DBInstanceAutomatedBackup -> Maybe Text
engineVersion :: Prelude.Maybe Prelude.Text,
    -- | Provides a list of status information for an automated backup:
    --
    -- -   @active@ - automated backups for current instances
    --
    -- -   @retained@ - automated backups for deleted instances
    --
    -- -   @creating@ - automated backups that are waiting for the first
    --     automated snapshot to be available.
    DBInstanceAutomatedBackup -> Maybe Text
status :: Prelude.Maybe Prelude.Text,
    -- | The Amazon Resource Name (ARN) for the automated backups.
    DBInstanceAutomatedBackup -> Maybe Text
dbInstanceArn :: Prelude.Maybe Prelude.Text,
    -- | The license model of an automated backup.
    DBInstanceAutomatedBackup -> Maybe Text
masterUsername :: Prelude.Maybe Prelude.Text,
    -- | True if mapping of Amazon Web Services Identity and Access Management
    -- (IAM) accounts to database accounts is enabled, and otherwise false.
    DBInstanceAutomatedBackup -> Maybe Bool
iAMDatabaseAuthenticationEnabled :: Prelude.Maybe Prelude.Bool,
    -- | The IOPS (I\/O operations per second) value for the automated backup.
    DBInstanceAutomatedBackup -> Maybe Int
iops :: Prelude.Maybe Prelude.Int,
    -- | Provides the VPC ID associated with the DB instance
    DBInstanceAutomatedBackup -> Maybe Text
vpcId :: Prelude.Maybe Prelude.Text,
    -- | Provides the date and time that the DB instance was created.
    DBInstanceAutomatedBackup -> Maybe ISO8601
instanceCreateTime :: Prelude.Maybe Core.ISO8601,
    -- | The name of the database engine for this automated backup.
    DBInstanceAutomatedBackup -> Maybe Text
engine :: Prelude.Maybe Prelude.Text,
    -- | Specifies whether the automated backup is encrypted.
    DBInstanceAutomatedBackup -> Maybe Bool
encrypted :: Prelude.Maybe Prelude.Bool,
    -- | License model information for the automated backup.
    DBInstanceAutomatedBackup -> Maybe Text
licenseModel :: Prelude.Maybe Prelude.Text,
    -- | The customer id of the instance that is\/was associated with the
    -- automated backup.
    DBInstanceAutomatedBackup -> Maybe Text
dbInstanceIdentifier :: Prelude.Maybe Prelude.Text,
    -- | The Amazon Web Services KMS key ID for an automated backup.
    --
    -- The Amazon Web Services KMS key identifier is the key ARN, key ID, alias
    -- ARN, or alias name for the Amazon Web Services KMS customer master key
    -- (CMK).
    DBInstanceAutomatedBackup -> Maybe Text
kmsKeyId :: Prelude.Maybe Prelude.Text,
    -- | The Availability Zone that the automated backup was created in. For
    -- information on Amazon Web Services Regions and Availability Zones, see
    -- <https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/Concepts.RegionsAndAvailabilityZones.html Regions and Availability Zones>.
    DBInstanceAutomatedBackup -> Maybe Text
availabilityZone :: Prelude.Maybe Prelude.Text,
    -- | The retention period for the automated backups.
    DBInstanceAutomatedBackup -> Maybe Int
backupRetentionPeriod :: Prelude.Maybe Prelude.Int,
    -- | The Amazon Web Services Region associated with the automated backup.
    DBInstanceAutomatedBackup -> Maybe Text
region :: Prelude.Maybe Prelude.Text,
    -- | Specifies the allocated storage size in gibibytes (GiB).
    DBInstanceAutomatedBackup -> Maybe Int
allocatedStorage :: Prelude.Maybe Prelude.Int,
    -- | The identifier for the source DB instance, which can\'t be changed and
    -- which is unique to an Amazon Web Services Region.
    DBInstanceAutomatedBackup -> Maybe Text
dbiResourceId :: Prelude.Maybe Prelude.Text,
    -- | The option group the automated backup is associated with. If omitted,
    -- the default option group for the engine specified is used.
    DBInstanceAutomatedBackup -> Maybe Text
optionGroupName :: Prelude.Maybe Prelude.Text,
    -- | The time zone of the automated backup. In most cases, the @Timezone@
    -- element is empty. @Timezone@ content appears only for Microsoft SQL
    -- Server DB instances that were created with a time zone specified.
    DBInstanceAutomatedBackup -> Maybe Text
timezone :: Prelude.Maybe Prelude.Text,
    -- | The ARN from the key store with which the automated backup is associated
    -- for TDE encryption.
    DBInstanceAutomatedBackup -> Maybe Text
tdeCredentialArn :: Prelude.Maybe Prelude.Text,
    -- | The list of replications to different Amazon Web Services Regions
    -- associated with the automated backup.
    DBInstanceAutomatedBackup
-> Maybe [DBInstanceAutomatedBackupsReplication]
dbInstanceAutomatedBackupsReplications :: Prelude.Maybe [DBInstanceAutomatedBackupsReplication],
    -- | The Amazon Resource Name (ARN) for the replicated automated backups.
    DBInstanceAutomatedBackup -> Maybe Text
dbInstanceAutomatedBackupsArn :: Prelude.Maybe Prelude.Text,
    -- | The port number that the automated backup used for connections.
    --
    -- Default: Inherits from the source DB instance
    --
    -- Valid Values: @1150-65535@
    DBInstanceAutomatedBackup -> Maybe Int
port :: Prelude.Maybe Prelude.Int,
    -- | Specifies the storage type associated with the automated backup.
    DBInstanceAutomatedBackup -> Maybe Text
storageType :: Prelude.Maybe Prelude.Text
  }
  deriving (DBInstanceAutomatedBackup -> DBInstanceAutomatedBackup -> Bool
(DBInstanceAutomatedBackup -> DBInstanceAutomatedBackup -> Bool)
-> (DBInstanceAutomatedBackup -> DBInstanceAutomatedBackup -> Bool)
-> Eq DBInstanceAutomatedBackup
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DBInstanceAutomatedBackup -> DBInstanceAutomatedBackup -> Bool
$c/= :: DBInstanceAutomatedBackup -> DBInstanceAutomatedBackup -> Bool
== :: DBInstanceAutomatedBackup -> DBInstanceAutomatedBackup -> Bool
$c== :: DBInstanceAutomatedBackup -> DBInstanceAutomatedBackup -> Bool
Prelude.Eq, ReadPrec [DBInstanceAutomatedBackup]
ReadPrec DBInstanceAutomatedBackup
Int -> ReadS DBInstanceAutomatedBackup
ReadS [DBInstanceAutomatedBackup]
(Int -> ReadS DBInstanceAutomatedBackup)
-> ReadS [DBInstanceAutomatedBackup]
-> ReadPrec DBInstanceAutomatedBackup
-> ReadPrec [DBInstanceAutomatedBackup]
-> Read DBInstanceAutomatedBackup
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DBInstanceAutomatedBackup]
$creadListPrec :: ReadPrec [DBInstanceAutomatedBackup]
readPrec :: ReadPrec DBInstanceAutomatedBackup
$creadPrec :: ReadPrec DBInstanceAutomatedBackup
readList :: ReadS [DBInstanceAutomatedBackup]
$creadList :: ReadS [DBInstanceAutomatedBackup]
readsPrec :: Int -> ReadS DBInstanceAutomatedBackup
$creadsPrec :: Int -> ReadS DBInstanceAutomatedBackup
Prelude.Read, Int -> DBInstanceAutomatedBackup -> ShowS
[DBInstanceAutomatedBackup] -> ShowS
DBInstanceAutomatedBackup -> String
(Int -> DBInstanceAutomatedBackup -> ShowS)
-> (DBInstanceAutomatedBackup -> String)
-> ([DBInstanceAutomatedBackup] -> ShowS)
-> Show DBInstanceAutomatedBackup
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DBInstanceAutomatedBackup] -> ShowS
$cshowList :: [DBInstanceAutomatedBackup] -> ShowS
show :: DBInstanceAutomatedBackup -> String
$cshow :: DBInstanceAutomatedBackup -> String
showsPrec :: Int -> DBInstanceAutomatedBackup -> ShowS
$cshowsPrec :: Int -> DBInstanceAutomatedBackup -> ShowS
Prelude.Show, (forall x.
 DBInstanceAutomatedBackup -> Rep DBInstanceAutomatedBackup x)
-> (forall x.
    Rep DBInstanceAutomatedBackup x -> DBInstanceAutomatedBackup)
-> Generic DBInstanceAutomatedBackup
forall x.
Rep DBInstanceAutomatedBackup x -> DBInstanceAutomatedBackup
forall x.
DBInstanceAutomatedBackup -> Rep DBInstanceAutomatedBackup x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep DBInstanceAutomatedBackup x -> DBInstanceAutomatedBackup
$cfrom :: forall x.
DBInstanceAutomatedBackup -> Rep DBInstanceAutomatedBackup x
Prelude.Generic)

-- |
-- Create a value of 'DBInstanceAutomatedBackup' 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:
--
-- 'restoreWindow', 'dbInstanceAutomatedBackup_restoreWindow' - Earliest and latest time an instance can be restored to.
--
-- 'engineVersion', 'dbInstanceAutomatedBackup_engineVersion' - The version of the database engine for the automated backup.
--
-- 'status', 'dbInstanceAutomatedBackup_status' - Provides a list of status information for an automated backup:
--
-- -   @active@ - automated backups for current instances
--
-- -   @retained@ - automated backups for deleted instances
--
-- -   @creating@ - automated backups that are waiting for the first
--     automated snapshot to be available.
--
-- 'dbInstanceArn', 'dbInstanceAutomatedBackup_dbInstanceArn' - The Amazon Resource Name (ARN) for the automated backups.
--
-- 'masterUsername', 'dbInstanceAutomatedBackup_masterUsername' - The license model of an automated backup.
--
-- 'iAMDatabaseAuthenticationEnabled', 'dbInstanceAutomatedBackup_iAMDatabaseAuthenticationEnabled' - True if mapping of Amazon Web Services Identity and Access Management
-- (IAM) accounts to database accounts is enabled, and otherwise false.
--
-- 'iops', 'dbInstanceAutomatedBackup_iops' - The IOPS (I\/O operations per second) value for the automated backup.
--
-- 'vpcId', 'dbInstanceAutomatedBackup_vpcId' - Provides the VPC ID associated with the DB instance
--
-- 'instanceCreateTime', 'dbInstanceAutomatedBackup_instanceCreateTime' - Provides the date and time that the DB instance was created.
--
-- 'engine', 'dbInstanceAutomatedBackup_engine' - The name of the database engine for this automated backup.
--
-- 'encrypted', 'dbInstanceAutomatedBackup_encrypted' - Specifies whether the automated backup is encrypted.
--
-- 'licenseModel', 'dbInstanceAutomatedBackup_licenseModel' - License model information for the automated backup.
--
-- 'dbInstanceIdentifier', 'dbInstanceAutomatedBackup_dbInstanceIdentifier' - The customer id of the instance that is\/was associated with the
-- automated backup.
--
-- 'kmsKeyId', 'dbInstanceAutomatedBackup_kmsKeyId' - The Amazon Web Services KMS key ID for an automated backup.
--
-- The Amazon Web Services KMS key identifier is the key ARN, key ID, alias
-- ARN, or alias name for the Amazon Web Services KMS customer master key
-- (CMK).
--
-- 'availabilityZone', 'dbInstanceAutomatedBackup_availabilityZone' - The Availability Zone that the automated backup was created in. For
-- information on Amazon Web Services Regions and Availability Zones, see
-- <https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/Concepts.RegionsAndAvailabilityZones.html Regions and Availability Zones>.
--
-- 'backupRetentionPeriod', 'dbInstanceAutomatedBackup_backupRetentionPeriod' - The retention period for the automated backups.
--
-- 'region', 'dbInstanceAutomatedBackup_region' - The Amazon Web Services Region associated with the automated backup.
--
-- 'allocatedStorage', 'dbInstanceAutomatedBackup_allocatedStorage' - Specifies the allocated storage size in gibibytes (GiB).
--
-- 'dbiResourceId', 'dbInstanceAutomatedBackup_dbiResourceId' - The identifier for the source DB instance, which can\'t be changed and
-- which is unique to an Amazon Web Services Region.
--
-- 'optionGroupName', 'dbInstanceAutomatedBackup_optionGroupName' - The option group the automated backup is associated with. If omitted,
-- the default option group for the engine specified is used.
--
-- 'timezone', 'dbInstanceAutomatedBackup_timezone' - The time zone of the automated backup. In most cases, the @Timezone@
-- element is empty. @Timezone@ content appears only for Microsoft SQL
-- Server DB instances that were created with a time zone specified.
--
-- 'tdeCredentialArn', 'dbInstanceAutomatedBackup_tdeCredentialArn' - The ARN from the key store with which the automated backup is associated
-- for TDE encryption.
--
-- 'dbInstanceAutomatedBackupsReplications', 'dbInstanceAutomatedBackup_dbInstanceAutomatedBackupsReplications' - The list of replications to different Amazon Web Services Regions
-- associated with the automated backup.
--
-- 'dbInstanceAutomatedBackupsArn', 'dbInstanceAutomatedBackup_dbInstanceAutomatedBackupsArn' - The Amazon Resource Name (ARN) for the replicated automated backups.
--
-- 'port', 'dbInstanceAutomatedBackup_port' - The port number that the automated backup used for connections.
--
-- Default: Inherits from the source DB instance
--
-- Valid Values: @1150-65535@
--
-- 'storageType', 'dbInstanceAutomatedBackup_storageType' - Specifies the storage type associated with the automated backup.
newDBInstanceAutomatedBackup ::
  DBInstanceAutomatedBackup
newDBInstanceAutomatedBackup :: DBInstanceAutomatedBackup
newDBInstanceAutomatedBackup =
  DBInstanceAutomatedBackup' :: Maybe RestoreWindow
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Bool
-> Maybe Int
-> Maybe Text
-> Maybe ISO8601
-> Maybe Text
-> Maybe Bool
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Int
-> Maybe Text
-> Maybe Int
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe [DBInstanceAutomatedBackupsReplication]
-> Maybe Text
-> Maybe Int
-> Maybe Text
-> DBInstanceAutomatedBackup
DBInstanceAutomatedBackup'
    { $sel:restoreWindow:DBInstanceAutomatedBackup' :: Maybe RestoreWindow
restoreWindow =
        Maybe RestoreWindow
forall a. Maybe a
Prelude.Nothing,
      $sel:engineVersion:DBInstanceAutomatedBackup' :: Maybe Text
engineVersion = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:status:DBInstanceAutomatedBackup' :: Maybe Text
status = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:dbInstanceArn:DBInstanceAutomatedBackup' :: Maybe Text
dbInstanceArn = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:masterUsername:DBInstanceAutomatedBackup' :: Maybe Text
masterUsername = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:iAMDatabaseAuthenticationEnabled:DBInstanceAutomatedBackup' :: Maybe Bool
iAMDatabaseAuthenticationEnabled =
        Maybe Bool
forall a. Maybe a
Prelude.Nothing,
      $sel:iops:DBInstanceAutomatedBackup' :: Maybe Int
iops = Maybe Int
forall a. Maybe a
Prelude.Nothing,
      $sel:vpcId:DBInstanceAutomatedBackup' :: Maybe Text
vpcId = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:instanceCreateTime:DBInstanceAutomatedBackup' :: Maybe ISO8601
instanceCreateTime = Maybe ISO8601
forall a. Maybe a
Prelude.Nothing,
      $sel:engine:DBInstanceAutomatedBackup' :: Maybe Text
engine = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:encrypted:DBInstanceAutomatedBackup' :: Maybe Bool
encrypted = Maybe Bool
forall a. Maybe a
Prelude.Nothing,
      $sel:licenseModel:DBInstanceAutomatedBackup' :: Maybe Text
licenseModel = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:dbInstanceIdentifier:DBInstanceAutomatedBackup' :: Maybe Text
dbInstanceIdentifier = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:kmsKeyId:DBInstanceAutomatedBackup' :: Maybe Text
kmsKeyId = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:availabilityZone:DBInstanceAutomatedBackup' :: Maybe Text
availabilityZone = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:backupRetentionPeriod:DBInstanceAutomatedBackup' :: Maybe Int
backupRetentionPeriod = Maybe Int
forall a. Maybe a
Prelude.Nothing,
      $sel:region:DBInstanceAutomatedBackup' :: Maybe Text
region = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:allocatedStorage:DBInstanceAutomatedBackup' :: Maybe Int
allocatedStorage = Maybe Int
forall a. Maybe a
Prelude.Nothing,
      $sel:dbiResourceId:DBInstanceAutomatedBackup' :: Maybe Text
dbiResourceId = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:optionGroupName:DBInstanceAutomatedBackup' :: Maybe Text
optionGroupName = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:timezone:DBInstanceAutomatedBackup' :: Maybe Text
timezone = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:tdeCredentialArn:DBInstanceAutomatedBackup' :: Maybe Text
tdeCredentialArn = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:dbInstanceAutomatedBackupsReplications:DBInstanceAutomatedBackup' :: Maybe [DBInstanceAutomatedBackupsReplication]
dbInstanceAutomatedBackupsReplications =
        Maybe [DBInstanceAutomatedBackupsReplication]
forall a. Maybe a
Prelude.Nothing,
      $sel:dbInstanceAutomatedBackupsArn:DBInstanceAutomatedBackup' :: Maybe Text
dbInstanceAutomatedBackupsArn = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:port:DBInstanceAutomatedBackup' :: Maybe Int
port = Maybe Int
forall a. Maybe a
Prelude.Nothing,
      $sel:storageType:DBInstanceAutomatedBackup' :: Maybe Text
storageType = Maybe Text
forall a. Maybe a
Prelude.Nothing
    }

-- | Earliest and latest time an instance can be restored to.
dbInstanceAutomatedBackup_restoreWindow :: Lens.Lens' DBInstanceAutomatedBackup (Prelude.Maybe RestoreWindow)
dbInstanceAutomatedBackup_restoreWindow :: (Maybe RestoreWindow -> f (Maybe RestoreWindow))
-> DBInstanceAutomatedBackup -> f DBInstanceAutomatedBackup
dbInstanceAutomatedBackup_restoreWindow = (DBInstanceAutomatedBackup -> Maybe RestoreWindow)
-> (DBInstanceAutomatedBackup
    -> Maybe RestoreWindow -> DBInstanceAutomatedBackup)
-> Lens
     DBInstanceAutomatedBackup
     DBInstanceAutomatedBackup
     (Maybe RestoreWindow)
     (Maybe RestoreWindow)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DBInstanceAutomatedBackup' {Maybe RestoreWindow
restoreWindow :: Maybe RestoreWindow
$sel:restoreWindow:DBInstanceAutomatedBackup' :: DBInstanceAutomatedBackup -> Maybe RestoreWindow
restoreWindow} -> Maybe RestoreWindow
restoreWindow) (\s :: DBInstanceAutomatedBackup
s@DBInstanceAutomatedBackup' {} Maybe RestoreWindow
a -> DBInstanceAutomatedBackup
s {$sel:restoreWindow:DBInstanceAutomatedBackup' :: Maybe RestoreWindow
restoreWindow = Maybe RestoreWindow
a} :: DBInstanceAutomatedBackup)

-- | The version of the database engine for the automated backup.
dbInstanceAutomatedBackup_engineVersion :: Lens.Lens' DBInstanceAutomatedBackup (Prelude.Maybe Prelude.Text)
dbInstanceAutomatedBackup_engineVersion :: (Maybe Text -> f (Maybe Text))
-> DBInstanceAutomatedBackup -> f DBInstanceAutomatedBackup
dbInstanceAutomatedBackup_engineVersion = (DBInstanceAutomatedBackup -> Maybe Text)
-> (DBInstanceAutomatedBackup
    -> Maybe Text -> DBInstanceAutomatedBackup)
-> Lens
     DBInstanceAutomatedBackup
     DBInstanceAutomatedBackup
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DBInstanceAutomatedBackup' {Maybe Text
engineVersion :: Maybe Text
$sel:engineVersion:DBInstanceAutomatedBackup' :: DBInstanceAutomatedBackup -> Maybe Text
engineVersion} -> Maybe Text
engineVersion) (\s :: DBInstanceAutomatedBackup
s@DBInstanceAutomatedBackup' {} Maybe Text
a -> DBInstanceAutomatedBackup
s {$sel:engineVersion:DBInstanceAutomatedBackup' :: Maybe Text
engineVersion = Maybe Text
a} :: DBInstanceAutomatedBackup)

-- | Provides a list of status information for an automated backup:
--
-- -   @active@ - automated backups for current instances
--
-- -   @retained@ - automated backups for deleted instances
--
-- -   @creating@ - automated backups that are waiting for the first
--     automated snapshot to be available.
dbInstanceAutomatedBackup_status :: Lens.Lens' DBInstanceAutomatedBackup (Prelude.Maybe Prelude.Text)
dbInstanceAutomatedBackup_status :: (Maybe Text -> f (Maybe Text))
-> DBInstanceAutomatedBackup -> f DBInstanceAutomatedBackup
dbInstanceAutomatedBackup_status = (DBInstanceAutomatedBackup -> Maybe Text)
-> (DBInstanceAutomatedBackup
    -> Maybe Text -> DBInstanceAutomatedBackup)
-> Lens
     DBInstanceAutomatedBackup
     DBInstanceAutomatedBackup
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DBInstanceAutomatedBackup' {Maybe Text
status :: Maybe Text
$sel:status:DBInstanceAutomatedBackup' :: DBInstanceAutomatedBackup -> Maybe Text
status} -> Maybe Text
status) (\s :: DBInstanceAutomatedBackup
s@DBInstanceAutomatedBackup' {} Maybe Text
a -> DBInstanceAutomatedBackup
s {$sel:status:DBInstanceAutomatedBackup' :: Maybe Text
status = Maybe Text
a} :: DBInstanceAutomatedBackup)

-- | The Amazon Resource Name (ARN) for the automated backups.
dbInstanceAutomatedBackup_dbInstanceArn :: Lens.Lens' DBInstanceAutomatedBackup (Prelude.Maybe Prelude.Text)
dbInstanceAutomatedBackup_dbInstanceArn :: (Maybe Text -> f (Maybe Text))
-> DBInstanceAutomatedBackup -> f DBInstanceAutomatedBackup
dbInstanceAutomatedBackup_dbInstanceArn = (DBInstanceAutomatedBackup -> Maybe Text)
-> (DBInstanceAutomatedBackup
    -> Maybe Text -> DBInstanceAutomatedBackup)
-> Lens
     DBInstanceAutomatedBackup
     DBInstanceAutomatedBackup
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DBInstanceAutomatedBackup' {Maybe Text
dbInstanceArn :: Maybe Text
$sel:dbInstanceArn:DBInstanceAutomatedBackup' :: DBInstanceAutomatedBackup -> Maybe Text
dbInstanceArn} -> Maybe Text
dbInstanceArn) (\s :: DBInstanceAutomatedBackup
s@DBInstanceAutomatedBackup' {} Maybe Text
a -> DBInstanceAutomatedBackup
s {$sel:dbInstanceArn:DBInstanceAutomatedBackup' :: Maybe Text
dbInstanceArn = Maybe Text
a} :: DBInstanceAutomatedBackup)

-- | The license model of an automated backup.
dbInstanceAutomatedBackup_masterUsername :: Lens.Lens' DBInstanceAutomatedBackup (Prelude.Maybe Prelude.Text)
dbInstanceAutomatedBackup_masterUsername :: (Maybe Text -> f (Maybe Text))
-> DBInstanceAutomatedBackup -> f DBInstanceAutomatedBackup
dbInstanceAutomatedBackup_masterUsername = (DBInstanceAutomatedBackup -> Maybe Text)
-> (DBInstanceAutomatedBackup
    -> Maybe Text -> DBInstanceAutomatedBackup)
-> Lens
     DBInstanceAutomatedBackup
     DBInstanceAutomatedBackup
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DBInstanceAutomatedBackup' {Maybe Text
masterUsername :: Maybe Text
$sel:masterUsername:DBInstanceAutomatedBackup' :: DBInstanceAutomatedBackup -> Maybe Text
masterUsername} -> Maybe Text
masterUsername) (\s :: DBInstanceAutomatedBackup
s@DBInstanceAutomatedBackup' {} Maybe Text
a -> DBInstanceAutomatedBackup
s {$sel:masterUsername:DBInstanceAutomatedBackup' :: Maybe Text
masterUsername = Maybe Text
a} :: DBInstanceAutomatedBackup)

-- | True if mapping of Amazon Web Services Identity and Access Management
-- (IAM) accounts to database accounts is enabled, and otherwise false.
dbInstanceAutomatedBackup_iAMDatabaseAuthenticationEnabled :: Lens.Lens' DBInstanceAutomatedBackup (Prelude.Maybe Prelude.Bool)
dbInstanceAutomatedBackup_iAMDatabaseAuthenticationEnabled :: (Maybe Bool -> f (Maybe Bool))
-> DBInstanceAutomatedBackup -> f DBInstanceAutomatedBackup
dbInstanceAutomatedBackup_iAMDatabaseAuthenticationEnabled = (DBInstanceAutomatedBackup -> Maybe Bool)
-> (DBInstanceAutomatedBackup
    -> Maybe Bool -> DBInstanceAutomatedBackup)
-> Lens
     DBInstanceAutomatedBackup
     DBInstanceAutomatedBackup
     (Maybe Bool)
     (Maybe Bool)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DBInstanceAutomatedBackup' {Maybe Bool
iAMDatabaseAuthenticationEnabled :: Maybe Bool
$sel:iAMDatabaseAuthenticationEnabled:DBInstanceAutomatedBackup' :: DBInstanceAutomatedBackup -> Maybe Bool
iAMDatabaseAuthenticationEnabled} -> Maybe Bool
iAMDatabaseAuthenticationEnabled) (\s :: DBInstanceAutomatedBackup
s@DBInstanceAutomatedBackup' {} Maybe Bool
a -> DBInstanceAutomatedBackup
s {$sel:iAMDatabaseAuthenticationEnabled:DBInstanceAutomatedBackup' :: Maybe Bool
iAMDatabaseAuthenticationEnabled = Maybe Bool
a} :: DBInstanceAutomatedBackup)

-- | The IOPS (I\/O operations per second) value for the automated backup.
dbInstanceAutomatedBackup_iops :: Lens.Lens' DBInstanceAutomatedBackup (Prelude.Maybe Prelude.Int)
dbInstanceAutomatedBackup_iops :: (Maybe Int -> f (Maybe Int))
-> DBInstanceAutomatedBackup -> f DBInstanceAutomatedBackup
dbInstanceAutomatedBackup_iops = (DBInstanceAutomatedBackup -> Maybe Int)
-> (DBInstanceAutomatedBackup
    -> Maybe Int -> DBInstanceAutomatedBackup)
-> Lens
     DBInstanceAutomatedBackup
     DBInstanceAutomatedBackup
     (Maybe Int)
     (Maybe Int)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DBInstanceAutomatedBackup' {Maybe Int
iops :: Maybe Int
$sel:iops:DBInstanceAutomatedBackup' :: DBInstanceAutomatedBackup -> Maybe Int
iops} -> Maybe Int
iops) (\s :: DBInstanceAutomatedBackup
s@DBInstanceAutomatedBackup' {} Maybe Int
a -> DBInstanceAutomatedBackup
s {$sel:iops:DBInstanceAutomatedBackup' :: Maybe Int
iops = Maybe Int
a} :: DBInstanceAutomatedBackup)

-- | Provides the VPC ID associated with the DB instance
dbInstanceAutomatedBackup_vpcId :: Lens.Lens' DBInstanceAutomatedBackup (Prelude.Maybe Prelude.Text)
dbInstanceAutomatedBackup_vpcId :: (Maybe Text -> f (Maybe Text))
-> DBInstanceAutomatedBackup -> f DBInstanceAutomatedBackup
dbInstanceAutomatedBackup_vpcId = (DBInstanceAutomatedBackup -> Maybe Text)
-> (DBInstanceAutomatedBackup
    -> Maybe Text -> DBInstanceAutomatedBackup)
-> Lens
     DBInstanceAutomatedBackup
     DBInstanceAutomatedBackup
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DBInstanceAutomatedBackup' {Maybe Text
vpcId :: Maybe Text
$sel:vpcId:DBInstanceAutomatedBackup' :: DBInstanceAutomatedBackup -> Maybe Text
vpcId} -> Maybe Text
vpcId) (\s :: DBInstanceAutomatedBackup
s@DBInstanceAutomatedBackup' {} Maybe Text
a -> DBInstanceAutomatedBackup
s {$sel:vpcId:DBInstanceAutomatedBackup' :: Maybe Text
vpcId = Maybe Text
a} :: DBInstanceAutomatedBackup)

-- | Provides the date and time that the DB instance was created.
dbInstanceAutomatedBackup_instanceCreateTime :: Lens.Lens' DBInstanceAutomatedBackup (Prelude.Maybe Prelude.UTCTime)
dbInstanceAutomatedBackup_instanceCreateTime :: (Maybe UTCTime -> f (Maybe UTCTime))
-> DBInstanceAutomatedBackup -> f DBInstanceAutomatedBackup
dbInstanceAutomatedBackup_instanceCreateTime = (DBInstanceAutomatedBackup -> Maybe ISO8601)
-> (DBInstanceAutomatedBackup
    -> Maybe ISO8601 -> DBInstanceAutomatedBackup)
-> Lens
     DBInstanceAutomatedBackup
     DBInstanceAutomatedBackup
     (Maybe ISO8601)
     (Maybe ISO8601)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DBInstanceAutomatedBackup' {Maybe ISO8601
instanceCreateTime :: Maybe ISO8601
$sel:instanceCreateTime:DBInstanceAutomatedBackup' :: DBInstanceAutomatedBackup -> Maybe ISO8601
instanceCreateTime} -> Maybe ISO8601
instanceCreateTime) (\s :: DBInstanceAutomatedBackup
s@DBInstanceAutomatedBackup' {} Maybe ISO8601
a -> DBInstanceAutomatedBackup
s {$sel:instanceCreateTime:DBInstanceAutomatedBackup' :: Maybe ISO8601
instanceCreateTime = Maybe ISO8601
a} :: DBInstanceAutomatedBackup) ((Maybe ISO8601 -> f (Maybe ISO8601))
 -> DBInstanceAutomatedBackup -> f DBInstanceAutomatedBackup)
-> ((Maybe UTCTime -> f (Maybe UTCTime))
    -> Maybe ISO8601 -> f (Maybe ISO8601))
-> (Maybe UTCTime -> f (Maybe UTCTime))
-> DBInstanceAutomatedBackup
-> f DBInstanceAutomatedBackup
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 name of the database engine for this automated backup.
dbInstanceAutomatedBackup_engine :: Lens.Lens' DBInstanceAutomatedBackup (Prelude.Maybe Prelude.Text)
dbInstanceAutomatedBackup_engine :: (Maybe Text -> f (Maybe Text))
-> DBInstanceAutomatedBackup -> f DBInstanceAutomatedBackup
dbInstanceAutomatedBackup_engine = (DBInstanceAutomatedBackup -> Maybe Text)
-> (DBInstanceAutomatedBackup
    -> Maybe Text -> DBInstanceAutomatedBackup)
-> Lens
     DBInstanceAutomatedBackup
     DBInstanceAutomatedBackup
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DBInstanceAutomatedBackup' {Maybe Text
engine :: Maybe Text
$sel:engine:DBInstanceAutomatedBackup' :: DBInstanceAutomatedBackup -> Maybe Text
engine} -> Maybe Text
engine) (\s :: DBInstanceAutomatedBackup
s@DBInstanceAutomatedBackup' {} Maybe Text
a -> DBInstanceAutomatedBackup
s {$sel:engine:DBInstanceAutomatedBackup' :: Maybe Text
engine = Maybe Text
a} :: DBInstanceAutomatedBackup)

-- | Specifies whether the automated backup is encrypted.
dbInstanceAutomatedBackup_encrypted :: Lens.Lens' DBInstanceAutomatedBackup (Prelude.Maybe Prelude.Bool)
dbInstanceAutomatedBackup_encrypted :: (Maybe Bool -> f (Maybe Bool))
-> DBInstanceAutomatedBackup -> f DBInstanceAutomatedBackup
dbInstanceAutomatedBackup_encrypted = (DBInstanceAutomatedBackup -> Maybe Bool)
-> (DBInstanceAutomatedBackup
    -> Maybe Bool -> DBInstanceAutomatedBackup)
-> Lens
     DBInstanceAutomatedBackup
     DBInstanceAutomatedBackup
     (Maybe Bool)
     (Maybe Bool)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DBInstanceAutomatedBackup' {Maybe Bool
encrypted :: Maybe Bool
$sel:encrypted:DBInstanceAutomatedBackup' :: DBInstanceAutomatedBackup -> Maybe Bool
encrypted} -> Maybe Bool
encrypted) (\s :: DBInstanceAutomatedBackup
s@DBInstanceAutomatedBackup' {} Maybe Bool
a -> DBInstanceAutomatedBackup
s {$sel:encrypted:DBInstanceAutomatedBackup' :: Maybe Bool
encrypted = Maybe Bool
a} :: DBInstanceAutomatedBackup)

-- | License model information for the automated backup.
dbInstanceAutomatedBackup_licenseModel :: Lens.Lens' DBInstanceAutomatedBackup (Prelude.Maybe Prelude.Text)
dbInstanceAutomatedBackup_licenseModel :: (Maybe Text -> f (Maybe Text))
-> DBInstanceAutomatedBackup -> f DBInstanceAutomatedBackup
dbInstanceAutomatedBackup_licenseModel = (DBInstanceAutomatedBackup -> Maybe Text)
-> (DBInstanceAutomatedBackup
    -> Maybe Text -> DBInstanceAutomatedBackup)
-> Lens
     DBInstanceAutomatedBackup
     DBInstanceAutomatedBackup
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DBInstanceAutomatedBackup' {Maybe Text
licenseModel :: Maybe Text
$sel:licenseModel:DBInstanceAutomatedBackup' :: DBInstanceAutomatedBackup -> Maybe Text
licenseModel} -> Maybe Text
licenseModel) (\s :: DBInstanceAutomatedBackup
s@DBInstanceAutomatedBackup' {} Maybe Text
a -> DBInstanceAutomatedBackup
s {$sel:licenseModel:DBInstanceAutomatedBackup' :: Maybe Text
licenseModel = Maybe Text
a} :: DBInstanceAutomatedBackup)

-- | The customer id of the instance that is\/was associated with the
-- automated backup.
dbInstanceAutomatedBackup_dbInstanceIdentifier :: Lens.Lens' DBInstanceAutomatedBackup (Prelude.Maybe Prelude.Text)
dbInstanceAutomatedBackup_dbInstanceIdentifier :: (Maybe Text -> f (Maybe Text))
-> DBInstanceAutomatedBackup -> f DBInstanceAutomatedBackup
dbInstanceAutomatedBackup_dbInstanceIdentifier = (DBInstanceAutomatedBackup -> Maybe Text)
-> (DBInstanceAutomatedBackup
    -> Maybe Text -> DBInstanceAutomatedBackup)
-> Lens
     DBInstanceAutomatedBackup
     DBInstanceAutomatedBackup
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DBInstanceAutomatedBackup' {Maybe Text
dbInstanceIdentifier :: Maybe Text
$sel:dbInstanceIdentifier:DBInstanceAutomatedBackup' :: DBInstanceAutomatedBackup -> Maybe Text
dbInstanceIdentifier} -> Maybe Text
dbInstanceIdentifier) (\s :: DBInstanceAutomatedBackup
s@DBInstanceAutomatedBackup' {} Maybe Text
a -> DBInstanceAutomatedBackup
s {$sel:dbInstanceIdentifier:DBInstanceAutomatedBackup' :: Maybe Text
dbInstanceIdentifier = Maybe Text
a} :: DBInstanceAutomatedBackup)

-- | The Amazon Web Services KMS key ID for an automated backup.
--
-- The Amazon Web Services KMS key identifier is the key ARN, key ID, alias
-- ARN, or alias name for the Amazon Web Services KMS customer master key
-- (CMK).
dbInstanceAutomatedBackup_kmsKeyId :: Lens.Lens' DBInstanceAutomatedBackup (Prelude.Maybe Prelude.Text)
dbInstanceAutomatedBackup_kmsKeyId :: (Maybe Text -> f (Maybe Text))
-> DBInstanceAutomatedBackup -> f DBInstanceAutomatedBackup
dbInstanceAutomatedBackup_kmsKeyId = (DBInstanceAutomatedBackup -> Maybe Text)
-> (DBInstanceAutomatedBackup
    -> Maybe Text -> DBInstanceAutomatedBackup)
-> Lens
     DBInstanceAutomatedBackup
     DBInstanceAutomatedBackup
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DBInstanceAutomatedBackup' {Maybe Text
kmsKeyId :: Maybe Text
$sel:kmsKeyId:DBInstanceAutomatedBackup' :: DBInstanceAutomatedBackup -> Maybe Text
kmsKeyId} -> Maybe Text
kmsKeyId) (\s :: DBInstanceAutomatedBackup
s@DBInstanceAutomatedBackup' {} Maybe Text
a -> DBInstanceAutomatedBackup
s {$sel:kmsKeyId:DBInstanceAutomatedBackup' :: Maybe Text
kmsKeyId = Maybe Text
a} :: DBInstanceAutomatedBackup)

-- | The Availability Zone that the automated backup was created in. For
-- information on Amazon Web Services Regions and Availability Zones, see
-- <https://docs.aws.amazon.com/AmazonRDS/latest/UserGuide/Concepts.RegionsAndAvailabilityZones.html Regions and Availability Zones>.
dbInstanceAutomatedBackup_availabilityZone :: Lens.Lens' DBInstanceAutomatedBackup (Prelude.Maybe Prelude.Text)
dbInstanceAutomatedBackup_availabilityZone :: (Maybe Text -> f (Maybe Text))
-> DBInstanceAutomatedBackup -> f DBInstanceAutomatedBackup
dbInstanceAutomatedBackup_availabilityZone = (DBInstanceAutomatedBackup -> Maybe Text)
-> (DBInstanceAutomatedBackup
    -> Maybe Text -> DBInstanceAutomatedBackup)
-> Lens
     DBInstanceAutomatedBackup
     DBInstanceAutomatedBackup
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DBInstanceAutomatedBackup' {Maybe Text
availabilityZone :: Maybe Text
$sel:availabilityZone:DBInstanceAutomatedBackup' :: DBInstanceAutomatedBackup -> Maybe Text
availabilityZone} -> Maybe Text
availabilityZone) (\s :: DBInstanceAutomatedBackup
s@DBInstanceAutomatedBackup' {} Maybe Text
a -> DBInstanceAutomatedBackup
s {$sel:availabilityZone:DBInstanceAutomatedBackup' :: Maybe Text
availabilityZone = Maybe Text
a} :: DBInstanceAutomatedBackup)

-- | The retention period for the automated backups.
dbInstanceAutomatedBackup_backupRetentionPeriod :: Lens.Lens' DBInstanceAutomatedBackup (Prelude.Maybe Prelude.Int)
dbInstanceAutomatedBackup_backupRetentionPeriod :: (Maybe Int -> f (Maybe Int))
-> DBInstanceAutomatedBackup -> f DBInstanceAutomatedBackup
dbInstanceAutomatedBackup_backupRetentionPeriod = (DBInstanceAutomatedBackup -> Maybe Int)
-> (DBInstanceAutomatedBackup
    -> Maybe Int -> DBInstanceAutomatedBackup)
-> Lens
     DBInstanceAutomatedBackup
     DBInstanceAutomatedBackup
     (Maybe Int)
     (Maybe Int)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DBInstanceAutomatedBackup' {Maybe Int
backupRetentionPeriod :: Maybe Int
$sel:backupRetentionPeriod:DBInstanceAutomatedBackup' :: DBInstanceAutomatedBackup -> Maybe Int
backupRetentionPeriod} -> Maybe Int
backupRetentionPeriod) (\s :: DBInstanceAutomatedBackup
s@DBInstanceAutomatedBackup' {} Maybe Int
a -> DBInstanceAutomatedBackup
s {$sel:backupRetentionPeriod:DBInstanceAutomatedBackup' :: Maybe Int
backupRetentionPeriod = Maybe Int
a} :: DBInstanceAutomatedBackup)

-- | The Amazon Web Services Region associated with the automated backup.
dbInstanceAutomatedBackup_region :: Lens.Lens' DBInstanceAutomatedBackup (Prelude.Maybe Prelude.Text)
dbInstanceAutomatedBackup_region :: (Maybe Text -> f (Maybe Text))
-> DBInstanceAutomatedBackup -> f DBInstanceAutomatedBackup
dbInstanceAutomatedBackup_region = (DBInstanceAutomatedBackup -> Maybe Text)
-> (DBInstanceAutomatedBackup
    -> Maybe Text -> DBInstanceAutomatedBackup)
-> Lens
     DBInstanceAutomatedBackup
     DBInstanceAutomatedBackup
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DBInstanceAutomatedBackup' {Maybe Text
region :: Maybe Text
$sel:region:DBInstanceAutomatedBackup' :: DBInstanceAutomatedBackup -> Maybe Text
region} -> Maybe Text
region) (\s :: DBInstanceAutomatedBackup
s@DBInstanceAutomatedBackup' {} Maybe Text
a -> DBInstanceAutomatedBackup
s {$sel:region:DBInstanceAutomatedBackup' :: Maybe Text
region = Maybe Text
a} :: DBInstanceAutomatedBackup)

-- | Specifies the allocated storage size in gibibytes (GiB).
dbInstanceAutomatedBackup_allocatedStorage :: Lens.Lens' DBInstanceAutomatedBackup (Prelude.Maybe Prelude.Int)
dbInstanceAutomatedBackup_allocatedStorage :: (Maybe Int -> f (Maybe Int))
-> DBInstanceAutomatedBackup -> f DBInstanceAutomatedBackup
dbInstanceAutomatedBackup_allocatedStorage = (DBInstanceAutomatedBackup -> Maybe Int)
-> (DBInstanceAutomatedBackup
    -> Maybe Int -> DBInstanceAutomatedBackup)
-> Lens
     DBInstanceAutomatedBackup
     DBInstanceAutomatedBackup
     (Maybe Int)
     (Maybe Int)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DBInstanceAutomatedBackup' {Maybe Int
allocatedStorage :: Maybe Int
$sel:allocatedStorage:DBInstanceAutomatedBackup' :: DBInstanceAutomatedBackup -> Maybe Int
allocatedStorage} -> Maybe Int
allocatedStorage) (\s :: DBInstanceAutomatedBackup
s@DBInstanceAutomatedBackup' {} Maybe Int
a -> DBInstanceAutomatedBackup
s {$sel:allocatedStorage:DBInstanceAutomatedBackup' :: Maybe Int
allocatedStorage = Maybe Int
a} :: DBInstanceAutomatedBackup)

-- | The identifier for the source DB instance, which can\'t be changed and
-- which is unique to an Amazon Web Services Region.
dbInstanceAutomatedBackup_dbiResourceId :: Lens.Lens' DBInstanceAutomatedBackup (Prelude.Maybe Prelude.Text)
dbInstanceAutomatedBackup_dbiResourceId :: (Maybe Text -> f (Maybe Text))
-> DBInstanceAutomatedBackup -> f DBInstanceAutomatedBackup
dbInstanceAutomatedBackup_dbiResourceId = (DBInstanceAutomatedBackup -> Maybe Text)
-> (DBInstanceAutomatedBackup
    -> Maybe Text -> DBInstanceAutomatedBackup)
-> Lens
     DBInstanceAutomatedBackup
     DBInstanceAutomatedBackup
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DBInstanceAutomatedBackup' {Maybe Text
dbiResourceId :: Maybe Text
$sel:dbiResourceId:DBInstanceAutomatedBackup' :: DBInstanceAutomatedBackup -> Maybe Text
dbiResourceId} -> Maybe Text
dbiResourceId) (\s :: DBInstanceAutomatedBackup
s@DBInstanceAutomatedBackup' {} Maybe Text
a -> DBInstanceAutomatedBackup
s {$sel:dbiResourceId:DBInstanceAutomatedBackup' :: Maybe Text
dbiResourceId = Maybe Text
a} :: DBInstanceAutomatedBackup)

-- | The option group the automated backup is associated with. If omitted,
-- the default option group for the engine specified is used.
dbInstanceAutomatedBackup_optionGroupName :: Lens.Lens' DBInstanceAutomatedBackup (Prelude.Maybe Prelude.Text)
dbInstanceAutomatedBackup_optionGroupName :: (Maybe Text -> f (Maybe Text))
-> DBInstanceAutomatedBackup -> f DBInstanceAutomatedBackup
dbInstanceAutomatedBackup_optionGroupName = (DBInstanceAutomatedBackup -> Maybe Text)
-> (DBInstanceAutomatedBackup
    -> Maybe Text -> DBInstanceAutomatedBackup)
-> Lens
     DBInstanceAutomatedBackup
     DBInstanceAutomatedBackup
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DBInstanceAutomatedBackup' {Maybe Text
optionGroupName :: Maybe Text
$sel:optionGroupName:DBInstanceAutomatedBackup' :: DBInstanceAutomatedBackup -> Maybe Text
optionGroupName} -> Maybe Text
optionGroupName) (\s :: DBInstanceAutomatedBackup
s@DBInstanceAutomatedBackup' {} Maybe Text
a -> DBInstanceAutomatedBackup
s {$sel:optionGroupName:DBInstanceAutomatedBackup' :: Maybe Text
optionGroupName = Maybe Text
a} :: DBInstanceAutomatedBackup)

-- | The time zone of the automated backup. In most cases, the @Timezone@
-- element is empty. @Timezone@ content appears only for Microsoft SQL
-- Server DB instances that were created with a time zone specified.
dbInstanceAutomatedBackup_timezone :: Lens.Lens' DBInstanceAutomatedBackup (Prelude.Maybe Prelude.Text)
dbInstanceAutomatedBackup_timezone :: (Maybe Text -> f (Maybe Text))
-> DBInstanceAutomatedBackup -> f DBInstanceAutomatedBackup
dbInstanceAutomatedBackup_timezone = (DBInstanceAutomatedBackup -> Maybe Text)
-> (DBInstanceAutomatedBackup
    -> Maybe Text -> DBInstanceAutomatedBackup)
-> Lens
     DBInstanceAutomatedBackup
     DBInstanceAutomatedBackup
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DBInstanceAutomatedBackup' {Maybe Text
timezone :: Maybe Text
$sel:timezone:DBInstanceAutomatedBackup' :: DBInstanceAutomatedBackup -> Maybe Text
timezone} -> Maybe Text
timezone) (\s :: DBInstanceAutomatedBackup
s@DBInstanceAutomatedBackup' {} Maybe Text
a -> DBInstanceAutomatedBackup
s {$sel:timezone:DBInstanceAutomatedBackup' :: Maybe Text
timezone = Maybe Text
a} :: DBInstanceAutomatedBackup)

-- | The ARN from the key store with which the automated backup is associated
-- for TDE encryption.
dbInstanceAutomatedBackup_tdeCredentialArn :: Lens.Lens' DBInstanceAutomatedBackup (Prelude.Maybe Prelude.Text)
dbInstanceAutomatedBackup_tdeCredentialArn :: (Maybe Text -> f (Maybe Text))
-> DBInstanceAutomatedBackup -> f DBInstanceAutomatedBackup
dbInstanceAutomatedBackup_tdeCredentialArn = (DBInstanceAutomatedBackup -> Maybe Text)
-> (DBInstanceAutomatedBackup
    -> Maybe Text -> DBInstanceAutomatedBackup)
-> Lens
     DBInstanceAutomatedBackup
     DBInstanceAutomatedBackup
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DBInstanceAutomatedBackup' {Maybe Text
tdeCredentialArn :: Maybe Text
$sel:tdeCredentialArn:DBInstanceAutomatedBackup' :: DBInstanceAutomatedBackup -> Maybe Text
tdeCredentialArn} -> Maybe Text
tdeCredentialArn) (\s :: DBInstanceAutomatedBackup
s@DBInstanceAutomatedBackup' {} Maybe Text
a -> DBInstanceAutomatedBackup
s {$sel:tdeCredentialArn:DBInstanceAutomatedBackup' :: Maybe Text
tdeCredentialArn = Maybe Text
a} :: DBInstanceAutomatedBackup)

-- | The list of replications to different Amazon Web Services Regions
-- associated with the automated backup.
dbInstanceAutomatedBackup_dbInstanceAutomatedBackupsReplications :: Lens.Lens' DBInstanceAutomatedBackup (Prelude.Maybe [DBInstanceAutomatedBackupsReplication])
dbInstanceAutomatedBackup_dbInstanceAutomatedBackupsReplications :: (Maybe [DBInstanceAutomatedBackupsReplication]
 -> f (Maybe [DBInstanceAutomatedBackupsReplication]))
-> DBInstanceAutomatedBackup -> f DBInstanceAutomatedBackup
dbInstanceAutomatedBackup_dbInstanceAutomatedBackupsReplications = (DBInstanceAutomatedBackup
 -> Maybe [DBInstanceAutomatedBackupsReplication])
-> (DBInstanceAutomatedBackup
    -> Maybe [DBInstanceAutomatedBackupsReplication]
    -> DBInstanceAutomatedBackup)
-> Lens
     DBInstanceAutomatedBackup
     DBInstanceAutomatedBackup
     (Maybe [DBInstanceAutomatedBackupsReplication])
     (Maybe [DBInstanceAutomatedBackupsReplication])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DBInstanceAutomatedBackup' {Maybe [DBInstanceAutomatedBackupsReplication]
dbInstanceAutomatedBackupsReplications :: Maybe [DBInstanceAutomatedBackupsReplication]
$sel:dbInstanceAutomatedBackupsReplications:DBInstanceAutomatedBackup' :: DBInstanceAutomatedBackup
-> Maybe [DBInstanceAutomatedBackupsReplication]
dbInstanceAutomatedBackupsReplications} -> Maybe [DBInstanceAutomatedBackupsReplication]
dbInstanceAutomatedBackupsReplications) (\s :: DBInstanceAutomatedBackup
s@DBInstanceAutomatedBackup' {} Maybe [DBInstanceAutomatedBackupsReplication]
a -> DBInstanceAutomatedBackup
s {$sel:dbInstanceAutomatedBackupsReplications:DBInstanceAutomatedBackup' :: Maybe [DBInstanceAutomatedBackupsReplication]
dbInstanceAutomatedBackupsReplications = Maybe [DBInstanceAutomatedBackupsReplication]
a} :: DBInstanceAutomatedBackup) ((Maybe [DBInstanceAutomatedBackupsReplication]
  -> f (Maybe [DBInstanceAutomatedBackupsReplication]))
 -> DBInstanceAutomatedBackup -> f DBInstanceAutomatedBackup)
-> ((Maybe [DBInstanceAutomatedBackupsReplication]
     -> f (Maybe [DBInstanceAutomatedBackupsReplication]))
    -> Maybe [DBInstanceAutomatedBackupsReplication]
    -> f (Maybe [DBInstanceAutomatedBackupsReplication]))
-> (Maybe [DBInstanceAutomatedBackupsReplication]
    -> f (Maybe [DBInstanceAutomatedBackupsReplication]))
-> DBInstanceAutomatedBackup
-> f DBInstanceAutomatedBackup
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
  [DBInstanceAutomatedBackupsReplication]
  [DBInstanceAutomatedBackupsReplication]
  [DBInstanceAutomatedBackupsReplication]
  [DBInstanceAutomatedBackupsReplication]
-> Iso
     (Maybe [DBInstanceAutomatedBackupsReplication])
     (Maybe [DBInstanceAutomatedBackupsReplication])
     (Maybe [DBInstanceAutomatedBackupsReplication])
     (Maybe [DBInstanceAutomatedBackupsReplication])
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
  [DBInstanceAutomatedBackupsReplication]
  [DBInstanceAutomatedBackupsReplication]
  [DBInstanceAutomatedBackupsReplication]
  [DBInstanceAutomatedBackupsReplication]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | The Amazon Resource Name (ARN) for the replicated automated backups.
dbInstanceAutomatedBackup_dbInstanceAutomatedBackupsArn :: Lens.Lens' DBInstanceAutomatedBackup (Prelude.Maybe Prelude.Text)
dbInstanceAutomatedBackup_dbInstanceAutomatedBackupsArn :: (Maybe Text -> f (Maybe Text))
-> DBInstanceAutomatedBackup -> f DBInstanceAutomatedBackup
dbInstanceAutomatedBackup_dbInstanceAutomatedBackupsArn = (DBInstanceAutomatedBackup -> Maybe Text)
-> (DBInstanceAutomatedBackup
    -> Maybe Text -> DBInstanceAutomatedBackup)
-> Lens
     DBInstanceAutomatedBackup
     DBInstanceAutomatedBackup
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DBInstanceAutomatedBackup' {Maybe Text
dbInstanceAutomatedBackupsArn :: Maybe Text
$sel:dbInstanceAutomatedBackupsArn:DBInstanceAutomatedBackup' :: DBInstanceAutomatedBackup -> Maybe Text
dbInstanceAutomatedBackupsArn} -> Maybe Text
dbInstanceAutomatedBackupsArn) (\s :: DBInstanceAutomatedBackup
s@DBInstanceAutomatedBackup' {} Maybe Text
a -> DBInstanceAutomatedBackup
s {$sel:dbInstanceAutomatedBackupsArn:DBInstanceAutomatedBackup' :: Maybe Text
dbInstanceAutomatedBackupsArn = Maybe Text
a} :: DBInstanceAutomatedBackup)

-- | The port number that the automated backup used for connections.
--
-- Default: Inherits from the source DB instance
--
-- Valid Values: @1150-65535@
dbInstanceAutomatedBackup_port :: Lens.Lens' DBInstanceAutomatedBackup (Prelude.Maybe Prelude.Int)
dbInstanceAutomatedBackup_port :: (Maybe Int -> f (Maybe Int))
-> DBInstanceAutomatedBackup -> f DBInstanceAutomatedBackup
dbInstanceAutomatedBackup_port = (DBInstanceAutomatedBackup -> Maybe Int)
-> (DBInstanceAutomatedBackup
    -> Maybe Int -> DBInstanceAutomatedBackup)
-> Lens
     DBInstanceAutomatedBackup
     DBInstanceAutomatedBackup
     (Maybe Int)
     (Maybe Int)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DBInstanceAutomatedBackup' {Maybe Int
port :: Maybe Int
$sel:port:DBInstanceAutomatedBackup' :: DBInstanceAutomatedBackup -> Maybe Int
port} -> Maybe Int
port) (\s :: DBInstanceAutomatedBackup
s@DBInstanceAutomatedBackup' {} Maybe Int
a -> DBInstanceAutomatedBackup
s {$sel:port:DBInstanceAutomatedBackup' :: Maybe Int
port = Maybe Int
a} :: DBInstanceAutomatedBackup)

-- | Specifies the storage type associated with the automated backup.
dbInstanceAutomatedBackup_storageType :: Lens.Lens' DBInstanceAutomatedBackup (Prelude.Maybe Prelude.Text)
dbInstanceAutomatedBackup_storageType :: (Maybe Text -> f (Maybe Text))
-> DBInstanceAutomatedBackup -> f DBInstanceAutomatedBackup
dbInstanceAutomatedBackup_storageType = (DBInstanceAutomatedBackup -> Maybe Text)
-> (DBInstanceAutomatedBackup
    -> Maybe Text -> DBInstanceAutomatedBackup)
-> Lens
     DBInstanceAutomatedBackup
     DBInstanceAutomatedBackup
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DBInstanceAutomatedBackup' {Maybe Text
storageType :: Maybe Text
$sel:storageType:DBInstanceAutomatedBackup' :: DBInstanceAutomatedBackup -> Maybe Text
storageType} -> Maybe Text
storageType) (\s :: DBInstanceAutomatedBackup
s@DBInstanceAutomatedBackup' {} Maybe Text
a -> DBInstanceAutomatedBackup
s {$sel:storageType:DBInstanceAutomatedBackup' :: Maybe Text
storageType = Maybe Text
a} :: DBInstanceAutomatedBackup)

instance Core.FromXML DBInstanceAutomatedBackup where
  parseXML :: [Node] -> Either String DBInstanceAutomatedBackup
parseXML [Node]
x =
    Maybe RestoreWindow
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Bool
-> Maybe Int
-> Maybe Text
-> Maybe ISO8601
-> Maybe Text
-> Maybe Bool
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Int
-> Maybe Text
-> Maybe Int
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe [DBInstanceAutomatedBackupsReplication]
-> Maybe Text
-> Maybe Int
-> Maybe Text
-> DBInstanceAutomatedBackup
DBInstanceAutomatedBackup'
      (Maybe RestoreWindow
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe Bool
 -> Maybe Int
 -> Maybe Text
 -> Maybe ISO8601
 -> Maybe Text
 -> Maybe Bool
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe Int
 -> Maybe Text
 -> Maybe Int
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe [DBInstanceAutomatedBackupsReplication]
 -> Maybe Text
 -> Maybe Int
 -> Maybe Text
 -> DBInstanceAutomatedBackup)
-> Either String (Maybe RestoreWindow)
-> Either
     String
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Int
      -> Maybe Text
      -> Maybe ISO8601
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe [DBInstanceAutomatedBackupsReplication]
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> DBInstanceAutomatedBackup)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> ([Node]
x [Node] -> Text -> Either String (Maybe RestoreWindow)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"RestoreWindow")
      Either
  String
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Int
   -> Maybe Text
   -> Maybe ISO8601
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe [DBInstanceAutomatedBackupsReplication]
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> DBInstanceAutomatedBackup)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Int
      -> Maybe Text
      -> Maybe ISO8601
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe [DBInstanceAutomatedBackupsReplication]
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> DBInstanceAutomatedBackup)
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
"EngineVersion")
      Either
  String
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Int
   -> Maybe Text
   -> Maybe ISO8601
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe [DBInstanceAutomatedBackupsReplication]
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> DBInstanceAutomatedBackup)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe Text
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Int
      -> Maybe Text
      -> Maybe ISO8601
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe [DBInstanceAutomatedBackupsReplication]
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> DBInstanceAutomatedBackup)
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 Text
   -> Maybe Bool
   -> Maybe Int
   -> Maybe Text
   -> Maybe ISO8601
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe [DBInstanceAutomatedBackupsReplication]
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> DBInstanceAutomatedBackup)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe Text
      -> Maybe Bool
      -> Maybe Int
      -> Maybe Text
      -> Maybe ISO8601
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe [DBInstanceAutomatedBackupsReplication]
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> DBInstanceAutomatedBackup)
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
"DBInstanceArn")
      Either
  String
  (Maybe Text
   -> Maybe Bool
   -> Maybe Int
   -> Maybe Text
   -> Maybe ISO8601
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe [DBInstanceAutomatedBackupsReplication]
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> DBInstanceAutomatedBackup)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe Bool
      -> Maybe Int
      -> Maybe Text
      -> Maybe ISO8601
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe [DBInstanceAutomatedBackupsReplication]
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> DBInstanceAutomatedBackup)
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
"MasterUsername")
      Either
  String
  (Maybe Bool
   -> Maybe Int
   -> Maybe Text
   -> Maybe ISO8601
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe [DBInstanceAutomatedBackupsReplication]
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> DBInstanceAutomatedBackup)
-> Either String (Maybe Bool)
-> Either
     String
     (Maybe Int
      -> Maybe Text
      -> Maybe ISO8601
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe [DBInstanceAutomatedBackupsReplication]
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> DBInstanceAutomatedBackup)
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
"IAMDatabaseAuthenticationEnabled")
      Either
  String
  (Maybe Int
   -> Maybe Text
   -> Maybe ISO8601
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe [DBInstanceAutomatedBackupsReplication]
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> DBInstanceAutomatedBackup)
-> Either String (Maybe Int)
-> Either
     String
     (Maybe Text
      -> Maybe ISO8601
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe [DBInstanceAutomatedBackupsReplication]
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> DBInstanceAutomatedBackup)
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
"Iops")
      Either
  String
  (Maybe Text
   -> Maybe ISO8601
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe [DBInstanceAutomatedBackupsReplication]
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> DBInstanceAutomatedBackup)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe ISO8601
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe [DBInstanceAutomatedBackupsReplication]
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> DBInstanceAutomatedBackup)
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
"VpcId")
      Either
  String
  (Maybe ISO8601
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe [DBInstanceAutomatedBackupsReplication]
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> DBInstanceAutomatedBackup)
-> Either String (Maybe ISO8601)
-> Either
     String
     (Maybe Text
      -> Maybe Bool
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe [DBInstanceAutomatedBackupsReplication]
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> DBInstanceAutomatedBackup)
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
"InstanceCreateTime")
      Either
  String
  (Maybe Text
   -> Maybe Bool
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe [DBInstanceAutomatedBackupsReplication]
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> DBInstanceAutomatedBackup)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe Bool
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe [DBInstanceAutomatedBackupsReplication]
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> DBInstanceAutomatedBackup)
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
"Engine")
      Either
  String
  (Maybe Bool
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe [DBInstanceAutomatedBackupsReplication]
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> DBInstanceAutomatedBackup)
-> Either String (Maybe Bool)
-> Either
     String
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe [DBInstanceAutomatedBackupsReplication]
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> DBInstanceAutomatedBackup)
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
"Encrypted")
      Either
  String
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe [DBInstanceAutomatedBackupsReplication]
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> DBInstanceAutomatedBackup)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe [DBInstanceAutomatedBackupsReplication]
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> DBInstanceAutomatedBackup)
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
"LicenseModel")
      Either
  String
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe [DBInstanceAutomatedBackupsReplication]
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> DBInstanceAutomatedBackup)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe Text
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe [DBInstanceAutomatedBackupsReplication]
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> DBInstanceAutomatedBackup)
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
"DBInstanceIdentifier")
      Either
  String
  (Maybe Text
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe [DBInstanceAutomatedBackupsReplication]
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> DBInstanceAutomatedBackup)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe [DBInstanceAutomatedBackupsReplication]
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> DBInstanceAutomatedBackup)
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 Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe [DBInstanceAutomatedBackupsReplication]
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> DBInstanceAutomatedBackup)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe Int
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe [DBInstanceAutomatedBackupsReplication]
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> DBInstanceAutomatedBackup)
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
"AvailabilityZone")
      Either
  String
  (Maybe Int
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe [DBInstanceAutomatedBackupsReplication]
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> DBInstanceAutomatedBackup)
-> Either String (Maybe Int)
-> Either
     String
     (Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe [DBInstanceAutomatedBackupsReplication]
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> DBInstanceAutomatedBackup)
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
"BackupRetentionPeriod")
      Either
  String
  (Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe [DBInstanceAutomatedBackupsReplication]
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> DBInstanceAutomatedBackup)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe [DBInstanceAutomatedBackupsReplication]
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> DBInstanceAutomatedBackup)
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
"Region")
      Either
  String
  (Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe [DBInstanceAutomatedBackupsReplication]
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> DBInstanceAutomatedBackup)
-> Either String (Maybe Int)
-> Either
     String
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe [DBInstanceAutomatedBackupsReplication]
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> DBInstanceAutomatedBackup)
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
"AllocatedStorage")
      Either
  String
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe [DBInstanceAutomatedBackupsReplication]
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> DBInstanceAutomatedBackup)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe [DBInstanceAutomatedBackupsReplication]
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> DBInstanceAutomatedBackup)
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
"DbiResourceId")
      Either
  String
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe [DBInstanceAutomatedBackupsReplication]
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> DBInstanceAutomatedBackup)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe Text
      -> Maybe Text
      -> Maybe [DBInstanceAutomatedBackupsReplication]
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> DBInstanceAutomatedBackup)
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
"OptionGroupName")
      Either
  String
  (Maybe Text
   -> Maybe Text
   -> Maybe [DBInstanceAutomatedBackupsReplication]
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> DBInstanceAutomatedBackup)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe Text
      -> Maybe [DBInstanceAutomatedBackupsReplication]
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> DBInstanceAutomatedBackup)
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
"Timezone")
      Either
  String
  (Maybe Text
   -> Maybe [DBInstanceAutomatedBackupsReplication]
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> DBInstanceAutomatedBackup)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe [DBInstanceAutomatedBackupsReplication]
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> DBInstanceAutomatedBackup)
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
"TdeCredentialArn")
      Either
  String
  (Maybe [DBInstanceAutomatedBackupsReplication]
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> DBInstanceAutomatedBackup)
-> Either String (Maybe [DBInstanceAutomatedBackupsReplication])
-> Either
     String
     (Maybe Text
      -> Maybe Int -> Maybe Text -> DBInstanceAutomatedBackup)
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
"DBInstanceAutomatedBackupsReplications"
                      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 [DBInstanceAutomatedBackupsReplication]))
-> Either String (Maybe [DBInstanceAutomatedBackupsReplication])
forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b
Prelude.>>= ([Node] -> Either String [DBInstanceAutomatedBackupsReplication])
-> [Node]
-> Either String (Maybe [DBInstanceAutomatedBackupsReplication])
forall (f :: * -> *) a b.
Applicative f =>
([a] -> f b) -> [a] -> f (Maybe b)
Core.may
                        ( Text
-> [Node] -> Either String [DBInstanceAutomatedBackupsReplication]
forall a. FromXML a => Text -> [Node] -> Either String [a]
Core.parseXMLList
                            Text
"DBInstanceAutomatedBackupsReplication"
                        )
                  )
      Either
  String
  (Maybe Text
   -> Maybe Int -> Maybe Text -> DBInstanceAutomatedBackup)
-> Either String (Maybe Text)
-> Either
     String (Maybe Int -> Maybe Text -> DBInstanceAutomatedBackup)
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
"DBInstanceAutomatedBackupsArn")
      Either
  String (Maybe Int -> Maybe Text -> DBInstanceAutomatedBackup)
-> Either String (Maybe Int)
-> Either String (Maybe Text -> DBInstanceAutomatedBackup)
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
"Port")
      Either String (Maybe Text -> DBInstanceAutomatedBackup)
-> Either String (Maybe Text)
-> Either String DBInstanceAutomatedBackup
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
"StorageType")

instance Prelude.Hashable DBInstanceAutomatedBackup

instance Prelude.NFData DBInstanceAutomatedBackup