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

import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
import Amazonka.RDS.Types.DBProxyStatus
import Amazonka.RDS.Types.UserAuthConfigInfo

-- | The data structure representing a proxy managed by the RDS Proxy.
--
-- This data type is used as a response element in the @DescribeDBProxies@
-- action.
--
-- /See:/ 'newDBProxy' smart constructor.
data DBProxy = DBProxy'
  { -- | The current status of this proxy. A status of @available@ means the
    -- proxy is ready to handle requests. Other values indicate that you must
    -- wait for the proxy to be ready, or take some action to resolve an issue.
    DBProxy -> Maybe DBProxyStatus
status :: Prelude.Maybe DBProxyStatus,
    -- | The Amazon Resource Name (ARN) for the proxy.
    DBProxy -> Maybe Text
dbProxyArn :: Prelude.Maybe Prelude.Text,
    -- | Whether the proxy includes detailed information about SQL statements in
    -- its logs. This information helps you to debug issues involving SQL
    -- behavior or the performance and scalability of the proxy connections.
    -- The debug information includes the text of SQL statements that you
    -- submit through the proxy. Thus, only enable this setting when needed for
    -- debugging, and only when you have security measures in place to
    -- safeguard any sensitive information that appears in the logs.
    DBProxy -> Maybe Bool
debugLogging :: Prelude.Maybe Prelude.Bool,
    -- | The EC2 subnet IDs for the proxy.
    DBProxy -> Maybe [Text]
vpcSubnetIds :: Prelude.Maybe [Prelude.Text],
    -- | Provides the VPC ID of the DB proxy.
    DBProxy -> Maybe Text
vpcId :: Prelude.Maybe Prelude.Text,
    -- | The engine family applies to MySQL and PostgreSQL for both RDS and
    -- Aurora.
    DBProxy -> Maybe Text
engineFamily :: Prelude.Maybe Prelude.Text,
    -- | One or more data structures specifying the authorization mechanism to
    -- connect to the associated RDS DB instance or Aurora DB cluster.
    DBProxy -> Maybe [UserAuthConfigInfo]
auth :: Prelude.Maybe [UserAuthConfigInfo],
    -- | Indicates whether Transport Layer Security (TLS) encryption is required
    -- for connections to the proxy.
    DBProxy -> Maybe Bool
requireTLS :: Prelude.Maybe Prelude.Bool,
    -- | The number of seconds a connection to the proxy can have no activity
    -- before the proxy drops the client connection. The proxy keeps the
    -- underlying database connection open and puts it back into the connection
    -- pool for reuse by later connection requests.
    --
    -- Default: 1800 (30 minutes)
    --
    -- Constraints: 1 to 28,800
    DBProxy -> Maybe Int
idleClientTimeout :: Prelude.Maybe Prelude.Int,
    -- | The date and time when the proxy was last updated.
    DBProxy -> Maybe ISO8601
updatedDate :: Prelude.Maybe Core.ISO8601,
    -- | The date and time when the proxy was first created.
    DBProxy -> Maybe ISO8601
createdDate :: Prelude.Maybe Core.ISO8601,
    -- | Provides a list of VPC security groups that the proxy belongs to.
    DBProxy -> Maybe [Text]
vpcSecurityGroupIds :: Prelude.Maybe [Prelude.Text],
    -- | The identifier for the proxy. This name must be unique for all proxies
    -- owned by your Amazon Web Services account in the specified Amazon Web
    -- Services Region.
    DBProxy -> Maybe Text
dbProxyName :: Prelude.Maybe Prelude.Text,
    -- | The endpoint that you can use to connect to the DB proxy. You include
    -- the endpoint value in the connection string for a database client
    -- application.
    DBProxy -> Maybe Text
endpoint :: Prelude.Maybe Prelude.Text,
    -- | The Amazon Resource Name (ARN) for the IAM role that the proxy uses to
    -- access Amazon Secrets Manager.
    DBProxy -> Maybe Text
roleArn :: Prelude.Maybe Prelude.Text
  }
  deriving (DBProxy -> DBProxy -> Bool
(DBProxy -> DBProxy -> Bool)
-> (DBProxy -> DBProxy -> Bool) -> Eq DBProxy
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DBProxy -> DBProxy -> Bool
$c/= :: DBProxy -> DBProxy -> Bool
== :: DBProxy -> DBProxy -> Bool
$c== :: DBProxy -> DBProxy -> Bool
Prelude.Eq, ReadPrec [DBProxy]
ReadPrec DBProxy
Int -> ReadS DBProxy
ReadS [DBProxy]
(Int -> ReadS DBProxy)
-> ReadS [DBProxy]
-> ReadPrec DBProxy
-> ReadPrec [DBProxy]
-> Read DBProxy
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DBProxy]
$creadListPrec :: ReadPrec [DBProxy]
readPrec :: ReadPrec DBProxy
$creadPrec :: ReadPrec DBProxy
readList :: ReadS [DBProxy]
$creadList :: ReadS [DBProxy]
readsPrec :: Int -> ReadS DBProxy
$creadsPrec :: Int -> ReadS DBProxy
Prelude.Read, Int -> DBProxy -> ShowS
[DBProxy] -> ShowS
DBProxy -> String
(Int -> DBProxy -> ShowS)
-> (DBProxy -> String) -> ([DBProxy] -> ShowS) -> Show DBProxy
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DBProxy] -> ShowS
$cshowList :: [DBProxy] -> ShowS
show :: DBProxy -> String
$cshow :: DBProxy -> String
showsPrec :: Int -> DBProxy -> ShowS
$cshowsPrec :: Int -> DBProxy -> ShowS
Prelude.Show, (forall x. DBProxy -> Rep DBProxy x)
-> (forall x. Rep DBProxy x -> DBProxy) -> Generic DBProxy
forall x. Rep DBProxy x -> DBProxy
forall x. DBProxy -> Rep DBProxy x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep DBProxy x -> DBProxy
$cfrom :: forall x. DBProxy -> Rep DBProxy x
Prelude.Generic)

-- |
-- Create a value of 'DBProxy' 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:
--
-- 'status', 'dbProxy_status' - The current status of this proxy. A status of @available@ means the
-- proxy is ready to handle requests. Other values indicate that you must
-- wait for the proxy to be ready, or take some action to resolve an issue.
--
-- 'dbProxyArn', 'dbProxy_dbProxyArn' - The Amazon Resource Name (ARN) for the proxy.
--
-- 'debugLogging', 'dbProxy_debugLogging' - Whether the proxy includes detailed information about SQL statements in
-- its logs. This information helps you to debug issues involving SQL
-- behavior or the performance and scalability of the proxy connections.
-- The debug information includes the text of SQL statements that you
-- submit through the proxy. Thus, only enable this setting when needed for
-- debugging, and only when you have security measures in place to
-- safeguard any sensitive information that appears in the logs.
--
-- 'vpcSubnetIds', 'dbProxy_vpcSubnetIds' - The EC2 subnet IDs for the proxy.
--
-- 'vpcId', 'dbProxy_vpcId' - Provides the VPC ID of the DB proxy.
--
-- 'engineFamily', 'dbProxy_engineFamily' - The engine family applies to MySQL and PostgreSQL for both RDS and
-- Aurora.
--
-- 'auth', 'dbProxy_auth' - One or more data structures specifying the authorization mechanism to
-- connect to the associated RDS DB instance or Aurora DB cluster.
--
-- 'requireTLS', 'dbProxy_requireTLS' - Indicates whether Transport Layer Security (TLS) encryption is required
-- for connections to the proxy.
--
-- 'idleClientTimeout', 'dbProxy_idleClientTimeout' - The number of seconds a connection to the proxy can have no activity
-- before the proxy drops the client connection. The proxy keeps the
-- underlying database connection open and puts it back into the connection
-- pool for reuse by later connection requests.
--
-- Default: 1800 (30 minutes)
--
-- Constraints: 1 to 28,800
--
-- 'updatedDate', 'dbProxy_updatedDate' - The date and time when the proxy was last updated.
--
-- 'createdDate', 'dbProxy_createdDate' - The date and time when the proxy was first created.
--
-- 'vpcSecurityGroupIds', 'dbProxy_vpcSecurityGroupIds' - Provides a list of VPC security groups that the proxy belongs to.
--
-- 'dbProxyName', 'dbProxy_dbProxyName' - The identifier for the proxy. This name must be unique for all proxies
-- owned by your Amazon Web Services account in the specified Amazon Web
-- Services Region.
--
-- 'endpoint', 'dbProxy_endpoint' - The endpoint that you can use to connect to the DB proxy. You include
-- the endpoint value in the connection string for a database client
-- application.
--
-- 'roleArn', 'dbProxy_roleArn' - The Amazon Resource Name (ARN) for the IAM role that the proxy uses to
-- access Amazon Secrets Manager.
newDBProxy ::
  DBProxy
newDBProxy :: DBProxy
newDBProxy =
  DBProxy' :: Maybe DBProxyStatus
-> Maybe Text
-> Maybe Bool
-> Maybe [Text]
-> Maybe Text
-> Maybe Text
-> Maybe [UserAuthConfigInfo]
-> Maybe Bool
-> Maybe Int
-> Maybe ISO8601
-> Maybe ISO8601
-> Maybe [Text]
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> DBProxy
DBProxy'
    { $sel:status:DBProxy' :: Maybe DBProxyStatus
status = Maybe DBProxyStatus
forall a. Maybe a
Prelude.Nothing,
      $sel:dbProxyArn:DBProxy' :: Maybe Text
dbProxyArn = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:debugLogging:DBProxy' :: Maybe Bool
debugLogging = Maybe Bool
forall a. Maybe a
Prelude.Nothing,
      $sel:vpcSubnetIds:DBProxy' :: Maybe [Text]
vpcSubnetIds = Maybe [Text]
forall a. Maybe a
Prelude.Nothing,
      $sel:vpcId:DBProxy' :: Maybe Text
vpcId = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:engineFamily:DBProxy' :: Maybe Text
engineFamily = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:auth:DBProxy' :: Maybe [UserAuthConfigInfo]
auth = Maybe [UserAuthConfigInfo]
forall a. Maybe a
Prelude.Nothing,
      $sel:requireTLS:DBProxy' :: Maybe Bool
requireTLS = Maybe Bool
forall a. Maybe a
Prelude.Nothing,
      $sel:idleClientTimeout:DBProxy' :: Maybe Int
idleClientTimeout = Maybe Int
forall a. Maybe a
Prelude.Nothing,
      $sel:updatedDate:DBProxy' :: Maybe ISO8601
updatedDate = Maybe ISO8601
forall a. Maybe a
Prelude.Nothing,
      $sel:createdDate:DBProxy' :: Maybe ISO8601
createdDate = Maybe ISO8601
forall a. Maybe a
Prelude.Nothing,
      $sel:vpcSecurityGroupIds:DBProxy' :: Maybe [Text]
vpcSecurityGroupIds = Maybe [Text]
forall a. Maybe a
Prelude.Nothing,
      $sel:dbProxyName:DBProxy' :: Maybe Text
dbProxyName = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:endpoint:DBProxy' :: Maybe Text
endpoint = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:roleArn:DBProxy' :: Maybe Text
roleArn = Maybe Text
forall a. Maybe a
Prelude.Nothing
    }

-- | The current status of this proxy. A status of @available@ means the
-- proxy is ready to handle requests. Other values indicate that you must
-- wait for the proxy to be ready, or take some action to resolve an issue.
dbProxy_status :: Lens.Lens' DBProxy (Prelude.Maybe DBProxyStatus)
dbProxy_status :: (Maybe DBProxyStatus -> f (Maybe DBProxyStatus))
-> DBProxy -> f DBProxy
dbProxy_status = (DBProxy -> Maybe DBProxyStatus)
-> (DBProxy -> Maybe DBProxyStatus -> DBProxy)
-> Lens DBProxy DBProxy (Maybe DBProxyStatus) (Maybe DBProxyStatus)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DBProxy' {Maybe DBProxyStatus
status :: Maybe DBProxyStatus
$sel:status:DBProxy' :: DBProxy -> Maybe DBProxyStatus
status} -> Maybe DBProxyStatus
status) (\s :: DBProxy
s@DBProxy' {} Maybe DBProxyStatus
a -> DBProxy
s {$sel:status:DBProxy' :: Maybe DBProxyStatus
status = Maybe DBProxyStatus
a} :: DBProxy)

-- | The Amazon Resource Name (ARN) for the proxy.
dbProxy_dbProxyArn :: Lens.Lens' DBProxy (Prelude.Maybe Prelude.Text)
dbProxy_dbProxyArn :: (Maybe Text -> f (Maybe Text)) -> DBProxy -> f DBProxy
dbProxy_dbProxyArn = (DBProxy -> Maybe Text)
-> (DBProxy -> Maybe Text -> DBProxy)
-> Lens DBProxy DBProxy (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DBProxy' {Maybe Text
dbProxyArn :: Maybe Text
$sel:dbProxyArn:DBProxy' :: DBProxy -> Maybe Text
dbProxyArn} -> Maybe Text
dbProxyArn) (\s :: DBProxy
s@DBProxy' {} Maybe Text
a -> DBProxy
s {$sel:dbProxyArn:DBProxy' :: Maybe Text
dbProxyArn = Maybe Text
a} :: DBProxy)

-- | Whether the proxy includes detailed information about SQL statements in
-- its logs. This information helps you to debug issues involving SQL
-- behavior or the performance and scalability of the proxy connections.
-- The debug information includes the text of SQL statements that you
-- submit through the proxy. Thus, only enable this setting when needed for
-- debugging, and only when you have security measures in place to
-- safeguard any sensitive information that appears in the logs.
dbProxy_debugLogging :: Lens.Lens' DBProxy (Prelude.Maybe Prelude.Bool)
dbProxy_debugLogging :: (Maybe Bool -> f (Maybe Bool)) -> DBProxy -> f DBProxy
dbProxy_debugLogging = (DBProxy -> Maybe Bool)
-> (DBProxy -> Maybe Bool -> DBProxy)
-> Lens DBProxy DBProxy (Maybe Bool) (Maybe Bool)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DBProxy' {Maybe Bool
debugLogging :: Maybe Bool
$sel:debugLogging:DBProxy' :: DBProxy -> Maybe Bool
debugLogging} -> Maybe Bool
debugLogging) (\s :: DBProxy
s@DBProxy' {} Maybe Bool
a -> DBProxy
s {$sel:debugLogging:DBProxy' :: Maybe Bool
debugLogging = Maybe Bool
a} :: DBProxy)

-- | The EC2 subnet IDs for the proxy.
dbProxy_vpcSubnetIds :: Lens.Lens' DBProxy (Prelude.Maybe [Prelude.Text])
dbProxy_vpcSubnetIds :: (Maybe [Text] -> f (Maybe [Text])) -> DBProxy -> f DBProxy
dbProxy_vpcSubnetIds = (DBProxy -> Maybe [Text])
-> (DBProxy -> Maybe [Text] -> DBProxy)
-> Lens DBProxy DBProxy (Maybe [Text]) (Maybe [Text])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DBProxy' {Maybe [Text]
vpcSubnetIds :: Maybe [Text]
$sel:vpcSubnetIds:DBProxy' :: DBProxy -> Maybe [Text]
vpcSubnetIds} -> Maybe [Text]
vpcSubnetIds) (\s :: DBProxy
s@DBProxy' {} Maybe [Text]
a -> DBProxy
s {$sel:vpcSubnetIds:DBProxy' :: Maybe [Text]
vpcSubnetIds = Maybe [Text]
a} :: DBProxy) ((Maybe [Text] -> f (Maybe [Text])) -> DBProxy -> f DBProxy)
-> ((Maybe [Text] -> f (Maybe [Text]))
    -> Maybe [Text] -> f (Maybe [Text]))
-> (Maybe [Text] -> f (Maybe [Text]))
-> DBProxy
-> f DBProxy
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso [Text] [Text] [Text] [Text]
-> Iso (Maybe [Text]) (Maybe [Text]) (Maybe [Text]) (Maybe [Text])
forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping AnIso [Text] [Text] [Text] [Text]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | Provides the VPC ID of the DB proxy.
dbProxy_vpcId :: Lens.Lens' DBProxy (Prelude.Maybe Prelude.Text)
dbProxy_vpcId :: (Maybe Text -> f (Maybe Text)) -> DBProxy -> f DBProxy
dbProxy_vpcId = (DBProxy -> Maybe Text)
-> (DBProxy -> Maybe Text -> DBProxy)
-> Lens DBProxy DBProxy (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DBProxy' {Maybe Text
vpcId :: Maybe Text
$sel:vpcId:DBProxy' :: DBProxy -> Maybe Text
vpcId} -> Maybe Text
vpcId) (\s :: DBProxy
s@DBProxy' {} Maybe Text
a -> DBProxy
s {$sel:vpcId:DBProxy' :: Maybe Text
vpcId = Maybe Text
a} :: DBProxy)

-- | The engine family applies to MySQL and PostgreSQL for both RDS and
-- Aurora.
dbProxy_engineFamily :: Lens.Lens' DBProxy (Prelude.Maybe Prelude.Text)
dbProxy_engineFamily :: (Maybe Text -> f (Maybe Text)) -> DBProxy -> f DBProxy
dbProxy_engineFamily = (DBProxy -> Maybe Text)
-> (DBProxy -> Maybe Text -> DBProxy)
-> Lens DBProxy DBProxy (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DBProxy' {Maybe Text
engineFamily :: Maybe Text
$sel:engineFamily:DBProxy' :: DBProxy -> Maybe Text
engineFamily} -> Maybe Text
engineFamily) (\s :: DBProxy
s@DBProxy' {} Maybe Text
a -> DBProxy
s {$sel:engineFamily:DBProxy' :: Maybe Text
engineFamily = Maybe Text
a} :: DBProxy)

-- | One or more data structures specifying the authorization mechanism to
-- connect to the associated RDS DB instance or Aurora DB cluster.
dbProxy_auth :: Lens.Lens' DBProxy (Prelude.Maybe [UserAuthConfigInfo])
dbProxy_auth :: (Maybe [UserAuthConfigInfo] -> f (Maybe [UserAuthConfigInfo]))
-> DBProxy -> f DBProxy
dbProxy_auth = (DBProxy -> Maybe [UserAuthConfigInfo])
-> (DBProxy -> Maybe [UserAuthConfigInfo] -> DBProxy)
-> Lens
     DBProxy
     DBProxy
     (Maybe [UserAuthConfigInfo])
     (Maybe [UserAuthConfigInfo])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DBProxy' {Maybe [UserAuthConfigInfo]
auth :: Maybe [UserAuthConfigInfo]
$sel:auth:DBProxy' :: DBProxy -> Maybe [UserAuthConfigInfo]
auth} -> Maybe [UserAuthConfigInfo]
auth) (\s :: DBProxy
s@DBProxy' {} Maybe [UserAuthConfigInfo]
a -> DBProxy
s {$sel:auth:DBProxy' :: Maybe [UserAuthConfigInfo]
auth = Maybe [UserAuthConfigInfo]
a} :: DBProxy) ((Maybe [UserAuthConfigInfo] -> f (Maybe [UserAuthConfigInfo]))
 -> DBProxy -> f DBProxy)
-> ((Maybe [UserAuthConfigInfo] -> f (Maybe [UserAuthConfigInfo]))
    -> Maybe [UserAuthConfigInfo] -> f (Maybe [UserAuthConfigInfo]))
-> (Maybe [UserAuthConfigInfo] -> f (Maybe [UserAuthConfigInfo]))
-> DBProxy
-> f DBProxy
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
  [UserAuthConfigInfo]
  [UserAuthConfigInfo]
  [UserAuthConfigInfo]
  [UserAuthConfigInfo]
-> Iso
     (Maybe [UserAuthConfigInfo])
     (Maybe [UserAuthConfigInfo])
     (Maybe [UserAuthConfigInfo])
     (Maybe [UserAuthConfigInfo])
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
  [UserAuthConfigInfo]
  [UserAuthConfigInfo]
  [UserAuthConfigInfo]
  [UserAuthConfigInfo]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | Indicates whether Transport Layer Security (TLS) encryption is required
-- for connections to the proxy.
dbProxy_requireTLS :: Lens.Lens' DBProxy (Prelude.Maybe Prelude.Bool)
dbProxy_requireTLS :: (Maybe Bool -> f (Maybe Bool)) -> DBProxy -> f DBProxy
dbProxy_requireTLS = (DBProxy -> Maybe Bool)
-> (DBProxy -> Maybe Bool -> DBProxy)
-> Lens DBProxy DBProxy (Maybe Bool) (Maybe Bool)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DBProxy' {Maybe Bool
requireTLS :: Maybe Bool
$sel:requireTLS:DBProxy' :: DBProxy -> Maybe Bool
requireTLS} -> Maybe Bool
requireTLS) (\s :: DBProxy
s@DBProxy' {} Maybe Bool
a -> DBProxy
s {$sel:requireTLS:DBProxy' :: Maybe Bool
requireTLS = Maybe Bool
a} :: DBProxy)

-- | The number of seconds a connection to the proxy can have no activity
-- before the proxy drops the client connection. The proxy keeps the
-- underlying database connection open and puts it back into the connection
-- pool for reuse by later connection requests.
--
-- Default: 1800 (30 minutes)
--
-- Constraints: 1 to 28,800
dbProxy_idleClientTimeout :: Lens.Lens' DBProxy (Prelude.Maybe Prelude.Int)
dbProxy_idleClientTimeout :: (Maybe Int -> f (Maybe Int)) -> DBProxy -> f DBProxy
dbProxy_idleClientTimeout = (DBProxy -> Maybe Int)
-> (DBProxy -> Maybe Int -> DBProxy)
-> Lens DBProxy DBProxy (Maybe Int) (Maybe Int)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DBProxy' {Maybe Int
idleClientTimeout :: Maybe Int
$sel:idleClientTimeout:DBProxy' :: DBProxy -> Maybe Int
idleClientTimeout} -> Maybe Int
idleClientTimeout) (\s :: DBProxy
s@DBProxy' {} Maybe Int
a -> DBProxy
s {$sel:idleClientTimeout:DBProxy' :: Maybe Int
idleClientTimeout = Maybe Int
a} :: DBProxy)

-- | The date and time when the proxy was last updated.
dbProxy_updatedDate :: Lens.Lens' DBProxy (Prelude.Maybe Prelude.UTCTime)
dbProxy_updatedDate :: (Maybe UTCTime -> f (Maybe UTCTime)) -> DBProxy -> f DBProxy
dbProxy_updatedDate = (DBProxy -> Maybe ISO8601)
-> (DBProxy -> Maybe ISO8601 -> DBProxy)
-> Lens DBProxy DBProxy (Maybe ISO8601) (Maybe ISO8601)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DBProxy' {Maybe ISO8601
updatedDate :: Maybe ISO8601
$sel:updatedDate:DBProxy' :: DBProxy -> Maybe ISO8601
updatedDate} -> Maybe ISO8601
updatedDate) (\s :: DBProxy
s@DBProxy' {} Maybe ISO8601
a -> DBProxy
s {$sel:updatedDate:DBProxy' :: Maybe ISO8601
updatedDate = Maybe ISO8601
a} :: DBProxy) ((Maybe ISO8601 -> f (Maybe ISO8601)) -> DBProxy -> f DBProxy)
-> ((Maybe UTCTime -> f (Maybe UTCTime))
    -> Maybe ISO8601 -> f (Maybe ISO8601))
-> (Maybe UTCTime -> f (Maybe UTCTime))
-> DBProxy
-> f DBProxy
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 date and time when the proxy was first created.
dbProxy_createdDate :: Lens.Lens' DBProxy (Prelude.Maybe Prelude.UTCTime)
dbProxy_createdDate :: (Maybe UTCTime -> f (Maybe UTCTime)) -> DBProxy -> f DBProxy
dbProxy_createdDate = (DBProxy -> Maybe ISO8601)
-> (DBProxy -> Maybe ISO8601 -> DBProxy)
-> Lens DBProxy DBProxy (Maybe ISO8601) (Maybe ISO8601)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DBProxy' {Maybe ISO8601
createdDate :: Maybe ISO8601
$sel:createdDate:DBProxy' :: DBProxy -> Maybe ISO8601
createdDate} -> Maybe ISO8601
createdDate) (\s :: DBProxy
s@DBProxy' {} Maybe ISO8601
a -> DBProxy
s {$sel:createdDate:DBProxy' :: Maybe ISO8601
createdDate = Maybe ISO8601
a} :: DBProxy) ((Maybe ISO8601 -> f (Maybe ISO8601)) -> DBProxy -> f DBProxy)
-> ((Maybe UTCTime -> f (Maybe UTCTime))
    -> Maybe ISO8601 -> f (Maybe ISO8601))
-> (Maybe UTCTime -> f (Maybe UTCTime))
-> DBProxy
-> f DBProxy
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

-- | Provides a list of VPC security groups that the proxy belongs to.
dbProxy_vpcSecurityGroupIds :: Lens.Lens' DBProxy (Prelude.Maybe [Prelude.Text])
dbProxy_vpcSecurityGroupIds :: (Maybe [Text] -> f (Maybe [Text])) -> DBProxy -> f DBProxy
dbProxy_vpcSecurityGroupIds = (DBProxy -> Maybe [Text])
-> (DBProxy -> Maybe [Text] -> DBProxy)
-> Lens DBProxy DBProxy (Maybe [Text]) (Maybe [Text])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DBProxy' {Maybe [Text]
vpcSecurityGroupIds :: Maybe [Text]
$sel:vpcSecurityGroupIds:DBProxy' :: DBProxy -> Maybe [Text]
vpcSecurityGroupIds} -> Maybe [Text]
vpcSecurityGroupIds) (\s :: DBProxy
s@DBProxy' {} Maybe [Text]
a -> DBProxy
s {$sel:vpcSecurityGroupIds:DBProxy' :: Maybe [Text]
vpcSecurityGroupIds = Maybe [Text]
a} :: DBProxy) ((Maybe [Text] -> f (Maybe [Text])) -> DBProxy -> f DBProxy)
-> ((Maybe [Text] -> f (Maybe [Text]))
    -> Maybe [Text] -> f (Maybe [Text]))
-> (Maybe [Text] -> f (Maybe [Text]))
-> DBProxy
-> f DBProxy
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso [Text] [Text] [Text] [Text]
-> Iso (Maybe [Text]) (Maybe [Text]) (Maybe [Text]) (Maybe [Text])
forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping AnIso [Text] [Text] [Text] [Text]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | The identifier for the proxy. This name must be unique for all proxies
-- owned by your Amazon Web Services account in the specified Amazon Web
-- Services Region.
dbProxy_dbProxyName :: Lens.Lens' DBProxy (Prelude.Maybe Prelude.Text)
dbProxy_dbProxyName :: (Maybe Text -> f (Maybe Text)) -> DBProxy -> f DBProxy
dbProxy_dbProxyName = (DBProxy -> Maybe Text)
-> (DBProxy -> Maybe Text -> DBProxy)
-> Lens DBProxy DBProxy (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DBProxy' {Maybe Text
dbProxyName :: Maybe Text
$sel:dbProxyName:DBProxy' :: DBProxy -> Maybe Text
dbProxyName} -> Maybe Text
dbProxyName) (\s :: DBProxy
s@DBProxy' {} Maybe Text
a -> DBProxy
s {$sel:dbProxyName:DBProxy' :: Maybe Text
dbProxyName = Maybe Text
a} :: DBProxy)

-- | The endpoint that you can use to connect to the DB proxy. You include
-- the endpoint value in the connection string for a database client
-- application.
dbProxy_endpoint :: Lens.Lens' DBProxy (Prelude.Maybe Prelude.Text)
dbProxy_endpoint :: (Maybe Text -> f (Maybe Text)) -> DBProxy -> f DBProxy
dbProxy_endpoint = (DBProxy -> Maybe Text)
-> (DBProxy -> Maybe Text -> DBProxy)
-> Lens DBProxy DBProxy (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DBProxy' {Maybe Text
endpoint :: Maybe Text
$sel:endpoint:DBProxy' :: DBProxy -> Maybe Text
endpoint} -> Maybe Text
endpoint) (\s :: DBProxy
s@DBProxy' {} Maybe Text
a -> DBProxy
s {$sel:endpoint:DBProxy' :: Maybe Text
endpoint = Maybe Text
a} :: DBProxy)

-- | The Amazon Resource Name (ARN) for the IAM role that the proxy uses to
-- access Amazon Secrets Manager.
dbProxy_roleArn :: Lens.Lens' DBProxy (Prelude.Maybe Prelude.Text)
dbProxy_roleArn :: (Maybe Text -> f (Maybe Text)) -> DBProxy -> f DBProxy
dbProxy_roleArn = (DBProxy -> Maybe Text)
-> (DBProxy -> Maybe Text -> DBProxy)
-> Lens DBProxy DBProxy (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DBProxy' {Maybe Text
roleArn :: Maybe Text
$sel:roleArn:DBProxy' :: DBProxy -> Maybe Text
roleArn} -> Maybe Text
roleArn) (\s :: DBProxy
s@DBProxy' {} Maybe Text
a -> DBProxy
s {$sel:roleArn:DBProxy' :: Maybe Text
roleArn = Maybe Text
a} :: DBProxy)

instance Core.FromXML DBProxy where
  parseXML :: [Node] -> Either String DBProxy
parseXML [Node]
x =
    Maybe DBProxyStatus
-> Maybe Text
-> Maybe Bool
-> Maybe [Text]
-> Maybe Text
-> Maybe Text
-> Maybe [UserAuthConfigInfo]
-> Maybe Bool
-> Maybe Int
-> Maybe ISO8601
-> Maybe ISO8601
-> Maybe [Text]
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> DBProxy
DBProxy'
      (Maybe DBProxyStatus
 -> Maybe Text
 -> Maybe Bool
 -> Maybe [Text]
 -> Maybe Text
 -> Maybe Text
 -> Maybe [UserAuthConfigInfo]
 -> Maybe Bool
 -> Maybe Int
 -> Maybe ISO8601
 -> Maybe ISO8601
 -> Maybe [Text]
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> DBProxy)
-> Either String (Maybe DBProxyStatus)
-> Either
     String
     (Maybe Text
      -> Maybe Bool
      -> Maybe [Text]
      -> Maybe Text
      -> Maybe Text
      -> Maybe [UserAuthConfigInfo]
      -> Maybe Bool
      -> Maybe Int
      -> Maybe ISO8601
      -> Maybe ISO8601
      -> Maybe [Text]
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> DBProxy)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> ([Node]
x [Node] -> Text -> Either String (Maybe DBProxyStatus)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"Status")
      Either
  String
  (Maybe Text
   -> Maybe Bool
   -> Maybe [Text]
   -> Maybe Text
   -> Maybe Text
   -> Maybe [UserAuthConfigInfo]
   -> Maybe Bool
   -> Maybe Int
   -> Maybe ISO8601
   -> Maybe ISO8601
   -> Maybe [Text]
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> DBProxy)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe Bool
      -> Maybe [Text]
      -> Maybe Text
      -> Maybe Text
      -> Maybe [UserAuthConfigInfo]
      -> Maybe Bool
      -> Maybe Int
      -> Maybe ISO8601
      -> Maybe ISO8601
      -> Maybe [Text]
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> DBProxy)
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
"DBProxyArn")
      Either
  String
  (Maybe Bool
   -> Maybe [Text]
   -> Maybe Text
   -> Maybe Text
   -> Maybe [UserAuthConfigInfo]
   -> Maybe Bool
   -> Maybe Int
   -> Maybe ISO8601
   -> Maybe ISO8601
   -> Maybe [Text]
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> DBProxy)
-> Either String (Maybe Bool)
-> Either
     String
     (Maybe [Text]
      -> Maybe Text
      -> Maybe Text
      -> Maybe [UserAuthConfigInfo]
      -> Maybe Bool
      -> Maybe Int
      -> Maybe ISO8601
      -> Maybe ISO8601
      -> Maybe [Text]
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> DBProxy)
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
"DebugLogging")
      Either
  String
  (Maybe [Text]
   -> Maybe Text
   -> Maybe Text
   -> Maybe [UserAuthConfigInfo]
   -> Maybe Bool
   -> Maybe Int
   -> Maybe ISO8601
   -> Maybe ISO8601
   -> Maybe [Text]
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> DBProxy)
-> Either String (Maybe [Text])
-> Either
     String
     (Maybe Text
      -> Maybe Text
      -> Maybe [UserAuthConfigInfo]
      -> Maybe Bool
      -> Maybe Int
      -> Maybe ISO8601
      -> Maybe ISO8601
      -> Maybe [Text]
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> DBProxy)
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
"VpcSubnetIds" Either String (Maybe [Node]) -> [Node] -> Either String [Node]
forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ [Node]
forall a. Monoid a => a
Prelude.mempty
                      Either String [Node]
-> ([Node] -> Either String (Maybe [Text]))
-> Either String (Maybe [Text])
forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b
Prelude.>>= ([Node] -> Either String [Text])
-> [Node] -> Either String (Maybe [Text])
forall (f :: * -> *) a b.
Applicative f =>
([a] -> f b) -> [a] -> f (Maybe b)
Core.may (Text -> [Node] -> Either String [Text]
forall a. FromXML a => Text -> [Node] -> Either String [a]
Core.parseXMLList Text
"member")
                  )
      Either
  String
  (Maybe Text
   -> Maybe Text
   -> Maybe [UserAuthConfigInfo]
   -> Maybe Bool
   -> Maybe Int
   -> Maybe ISO8601
   -> Maybe ISO8601
   -> Maybe [Text]
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> DBProxy)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe Text
      -> Maybe [UserAuthConfigInfo]
      -> Maybe Bool
      -> Maybe Int
      -> Maybe ISO8601
      -> Maybe ISO8601
      -> Maybe [Text]
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> DBProxy)
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 Text
   -> Maybe [UserAuthConfigInfo]
   -> Maybe Bool
   -> Maybe Int
   -> Maybe ISO8601
   -> Maybe ISO8601
   -> Maybe [Text]
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> DBProxy)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe [UserAuthConfigInfo]
      -> Maybe Bool
      -> Maybe Int
      -> Maybe ISO8601
      -> Maybe ISO8601
      -> Maybe [Text]
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> DBProxy)
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
"EngineFamily")
      Either
  String
  (Maybe [UserAuthConfigInfo]
   -> Maybe Bool
   -> Maybe Int
   -> Maybe ISO8601
   -> Maybe ISO8601
   -> Maybe [Text]
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> DBProxy)
-> Either String (Maybe [UserAuthConfigInfo])
-> Either
     String
     (Maybe Bool
      -> Maybe Int
      -> Maybe ISO8601
      -> Maybe ISO8601
      -> Maybe [Text]
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> DBProxy)
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
"Auth" 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 [UserAuthConfigInfo]))
-> Either String (Maybe [UserAuthConfigInfo])
forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b
Prelude.>>= ([Node] -> Either String [UserAuthConfigInfo])
-> [Node] -> Either String (Maybe [UserAuthConfigInfo])
forall (f :: * -> *) a b.
Applicative f =>
([a] -> f b) -> [a] -> f (Maybe b)
Core.may (Text -> [Node] -> Either String [UserAuthConfigInfo]
forall a. FromXML a => Text -> [Node] -> Either String [a]
Core.parseXMLList Text
"member")
                  )
      Either
  String
  (Maybe Bool
   -> Maybe Int
   -> Maybe ISO8601
   -> Maybe ISO8601
   -> Maybe [Text]
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> DBProxy)
-> Either String (Maybe Bool)
-> Either
     String
     (Maybe Int
      -> Maybe ISO8601
      -> Maybe ISO8601
      -> Maybe [Text]
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> DBProxy)
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
"RequireTLS")
      Either
  String
  (Maybe Int
   -> Maybe ISO8601
   -> Maybe ISO8601
   -> Maybe [Text]
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> DBProxy)
-> Either String (Maybe Int)
-> Either
     String
     (Maybe ISO8601
      -> Maybe ISO8601
      -> Maybe [Text]
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> DBProxy)
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
"IdleClientTimeout")
      Either
  String
  (Maybe ISO8601
   -> Maybe ISO8601
   -> Maybe [Text]
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> DBProxy)
-> Either String (Maybe ISO8601)
-> Either
     String
     (Maybe ISO8601
      -> Maybe [Text]
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> DBProxy)
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
"UpdatedDate")
      Either
  String
  (Maybe ISO8601
   -> Maybe [Text]
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> DBProxy)
-> Either String (Maybe ISO8601)
-> Either
     String
     (Maybe [Text] -> Maybe Text -> Maybe Text -> Maybe Text -> DBProxy)
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
"CreatedDate")
      Either
  String
  (Maybe [Text] -> Maybe Text -> Maybe Text -> Maybe Text -> DBProxy)
-> Either String (Maybe [Text])
-> Either
     String (Maybe Text -> Maybe Text -> Maybe Text -> DBProxy)
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
"VpcSecurityGroupIds"
                      Either String (Maybe [Node]) -> [Node] -> Either String [Node]
forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ [Node]
forall a. Monoid a => a
Prelude.mempty
                      Either String [Node]
-> ([Node] -> Either String (Maybe [Text]))
-> Either String (Maybe [Text])
forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b
Prelude.>>= ([Node] -> Either String [Text])
-> [Node] -> Either String (Maybe [Text])
forall (f :: * -> *) a b.
Applicative f =>
([a] -> f b) -> [a] -> f (Maybe b)
Core.may (Text -> [Node] -> Either String [Text]
forall a. FromXML a => Text -> [Node] -> Either String [a]
Core.parseXMLList Text
"member")
                  )
      Either String (Maybe Text -> Maybe Text -> Maybe Text -> DBProxy)
-> Either String (Maybe Text)
-> Either String (Maybe Text -> Maybe Text -> DBProxy)
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
"DBProxyName")
      Either String (Maybe Text -> Maybe Text -> DBProxy)
-> Either String (Maybe Text)
-> Either String (Maybe Text -> DBProxy)
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
"Endpoint")
      Either String (Maybe Text -> DBProxy)
-> Either String (Maybe Text) -> Either String DBProxy
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
"RoleArn")

instance Prelude.Hashable DBProxy

instance Prelude.NFData DBProxy