{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE DuplicateRecordFields #-}
{-# LANGUAGE NamedFieldPuns #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE StrictData #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_GHC -fno-warn-unused-binds #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-unused-matches #-}
module Amazonka.RDS.CreateDBProxy
(
CreateDBProxy (..),
newCreateDBProxy,
createDBProxy_debugLogging,
createDBProxy_requireTLS,
createDBProxy_idleClientTimeout,
createDBProxy_vpcSecurityGroupIds,
createDBProxy_tags,
createDBProxy_dbProxyName,
createDBProxy_engineFamily,
createDBProxy_auth,
createDBProxy_roleArn,
createDBProxy_vpcSubnetIds,
CreateDBProxyResponse (..),
newCreateDBProxyResponse,
createDBProxyResponse_dbProxy,
createDBProxyResponse_httpStatus,
)
where
import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
import Amazonka.RDS.Types
import qualified Amazonka.Request as Request
import qualified Amazonka.Response as Response
data CreateDBProxy = CreateDBProxy'
{
CreateDBProxy -> Maybe Bool
debugLogging :: Prelude.Maybe Prelude.Bool,
CreateDBProxy -> Maybe Bool
requireTLS :: Prelude.Maybe Prelude.Bool,
CreateDBProxy -> Maybe Int
idleClientTimeout :: Prelude.Maybe Prelude.Int,
CreateDBProxy -> Maybe [Text]
vpcSecurityGroupIds :: Prelude.Maybe [Prelude.Text],
CreateDBProxy -> Maybe [Tag]
tags :: Prelude.Maybe [Tag],
CreateDBProxy -> Text
dbProxyName :: Prelude.Text,
CreateDBProxy -> EngineFamily
engineFamily :: EngineFamily,
CreateDBProxy -> [UserAuthConfig]
auth :: [UserAuthConfig],
CreateDBProxy -> Text
roleArn :: Prelude.Text,
CreateDBProxy -> [Text]
vpcSubnetIds :: [Prelude.Text]
}
deriving (CreateDBProxy -> CreateDBProxy -> Bool
(CreateDBProxy -> CreateDBProxy -> Bool)
-> (CreateDBProxy -> CreateDBProxy -> Bool) -> Eq CreateDBProxy
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: CreateDBProxy -> CreateDBProxy -> Bool
$c/= :: CreateDBProxy -> CreateDBProxy -> Bool
== :: CreateDBProxy -> CreateDBProxy -> Bool
$c== :: CreateDBProxy -> CreateDBProxy -> Bool
Prelude.Eq, ReadPrec [CreateDBProxy]
ReadPrec CreateDBProxy
Int -> ReadS CreateDBProxy
ReadS [CreateDBProxy]
(Int -> ReadS CreateDBProxy)
-> ReadS [CreateDBProxy]
-> ReadPrec CreateDBProxy
-> ReadPrec [CreateDBProxy]
-> Read CreateDBProxy
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [CreateDBProxy]
$creadListPrec :: ReadPrec [CreateDBProxy]
readPrec :: ReadPrec CreateDBProxy
$creadPrec :: ReadPrec CreateDBProxy
readList :: ReadS [CreateDBProxy]
$creadList :: ReadS [CreateDBProxy]
readsPrec :: Int -> ReadS CreateDBProxy
$creadsPrec :: Int -> ReadS CreateDBProxy
Prelude.Read, Int -> CreateDBProxy -> ShowS
[CreateDBProxy] -> ShowS
CreateDBProxy -> String
(Int -> CreateDBProxy -> ShowS)
-> (CreateDBProxy -> String)
-> ([CreateDBProxy] -> ShowS)
-> Show CreateDBProxy
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [CreateDBProxy] -> ShowS
$cshowList :: [CreateDBProxy] -> ShowS
show :: CreateDBProxy -> String
$cshow :: CreateDBProxy -> String
showsPrec :: Int -> CreateDBProxy -> ShowS
$cshowsPrec :: Int -> CreateDBProxy -> ShowS
Prelude.Show, (forall x. CreateDBProxy -> Rep CreateDBProxy x)
-> (forall x. Rep CreateDBProxy x -> CreateDBProxy)
-> Generic CreateDBProxy
forall x. Rep CreateDBProxy x -> CreateDBProxy
forall x. CreateDBProxy -> Rep CreateDBProxy x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep CreateDBProxy x -> CreateDBProxy
$cfrom :: forall x. CreateDBProxy -> Rep CreateDBProxy x
Prelude.Generic)
newCreateDBProxy ::
Prelude.Text ->
EngineFamily ->
Prelude.Text ->
CreateDBProxy
newCreateDBProxy :: Text -> EngineFamily -> Text -> CreateDBProxy
newCreateDBProxy
Text
pDBProxyName_
EngineFamily
pEngineFamily_
Text
pRoleArn_ =
CreateDBProxy' :: Maybe Bool
-> Maybe Bool
-> Maybe Int
-> Maybe [Text]
-> Maybe [Tag]
-> Text
-> EngineFamily
-> [UserAuthConfig]
-> Text
-> [Text]
-> CreateDBProxy
CreateDBProxy'
{ $sel:debugLogging:CreateDBProxy' :: Maybe Bool
debugLogging = Maybe Bool
forall a. Maybe a
Prelude.Nothing,
$sel:requireTLS:CreateDBProxy' :: Maybe Bool
requireTLS = Maybe Bool
forall a. Maybe a
Prelude.Nothing,
$sel:idleClientTimeout:CreateDBProxy' :: Maybe Int
idleClientTimeout = Maybe Int
forall a. Maybe a
Prelude.Nothing,
$sel:vpcSecurityGroupIds:CreateDBProxy' :: Maybe [Text]
vpcSecurityGroupIds = Maybe [Text]
forall a. Maybe a
Prelude.Nothing,
$sel:tags:CreateDBProxy' :: Maybe [Tag]
tags = Maybe [Tag]
forall a. Maybe a
Prelude.Nothing,
$sel:dbProxyName:CreateDBProxy' :: Text
dbProxyName = Text
pDBProxyName_,
$sel:engineFamily:CreateDBProxy' :: EngineFamily
engineFamily = EngineFamily
pEngineFamily_,
$sel:auth:CreateDBProxy' :: [UserAuthConfig]
auth = [UserAuthConfig]
forall a. Monoid a => a
Prelude.mempty,
$sel:roleArn:CreateDBProxy' :: Text
roleArn = Text
pRoleArn_,
$sel:vpcSubnetIds:CreateDBProxy' :: [Text]
vpcSubnetIds = [Text]
forall a. Monoid a => a
Prelude.mempty
}
createDBProxy_debugLogging :: Lens.Lens' CreateDBProxy (Prelude.Maybe Prelude.Bool)
createDBProxy_debugLogging :: (Maybe Bool -> f (Maybe Bool)) -> CreateDBProxy -> f CreateDBProxy
createDBProxy_debugLogging = (CreateDBProxy -> Maybe Bool)
-> (CreateDBProxy -> Maybe Bool -> CreateDBProxy)
-> Lens CreateDBProxy CreateDBProxy (Maybe Bool) (Maybe Bool)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateDBProxy' {Maybe Bool
debugLogging :: Maybe Bool
$sel:debugLogging:CreateDBProxy' :: CreateDBProxy -> Maybe Bool
debugLogging} -> Maybe Bool
debugLogging) (\s :: CreateDBProxy
s@CreateDBProxy' {} Maybe Bool
a -> CreateDBProxy
s {$sel:debugLogging:CreateDBProxy' :: Maybe Bool
debugLogging = Maybe Bool
a} :: CreateDBProxy)
createDBProxy_requireTLS :: Lens.Lens' CreateDBProxy (Prelude.Maybe Prelude.Bool)
createDBProxy_requireTLS :: (Maybe Bool -> f (Maybe Bool)) -> CreateDBProxy -> f CreateDBProxy
createDBProxy_requireTLS = (CreateDBProxy -> Maybe Bool)
-> (CreateDBProxy -> Maybe Bool -> CreateDBProxy)
-> Lens CreateDBProxy CreateDBProxy (Maybe Bool) (Maybe Bool)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateDBProxy' {Maybe Bool
requireTLS :: Maybe Bool
$sel:requireTLS:CreateDBProxy' :: CreateDBProxy -> Maybe Bool
requireTLS} -> Maybe Bool
requireTLS) (\s :: CreateDBProxy
s@CreateDBProxy' {} Maybe Bool
a -> CreateDBProxy
s {$sel:requireTLS:CreateDBProxy' :: Maybe Bool
requireTLS = Maybe Bool
a} :: CreateDBProxy)
createDBProxy_idleClientTimeout :: Lens.Lens' CreateDBProxy (Prelude.Maybe Prelude.Int)
createDBProxy_idleClientTimeout :: (Maybe Int -> f (Maybe Int)) -> CreateDBProxy -> f CreateDBProxy
createDBProxy_idleClientTimeout = (CreateDBProxy -> Maybe Int)
-> (CreateDBProxy -> Maybe Int -> CreateDBProxy)
-> Lens CreateDBProxy CreateDBProxy (Maybe Int) (Maybe Int)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateDBProxy' {Maybe Int
idleClientTimeout :: Maybe Int
$sel:idleClientTimeout:CreateDBProxy' :: CreateDBProxy -> Maybe Int
idleClientTimeout} -> Maybe Int
idleClientTimeout) (\s :: CreateDBProxy
s@CreateDBProxy' {} Maybe Int
a -> CreateDBProxy
s {$sel:idleClientTimeout:CreateDBProxy' :: Maybe Int
idleClientTimeout = Maybe Int
a} :: CreateDBProxy)
createDBProxy_vpcSecurityGroupIds :: Lens.Lens' CreateDBProxy (Prelude.Maybe [Prelude.Text])
createDBProxy_vpcSecurityGroupIds :: (Maybe [Text] -> f (Maybe [Text]))
-> CreateDBProxy -> f CreateDBProxy
createDBProxy_vpcSecurityGroupIds = (CreateDBProxy -> Maybe [Text])
-> (CreateDBProxy -> Maybe [Text] -> CreateDBProxy)
-> Lens CreateDBProxy CreateDBProxy (Maybe [Text]) (Maybe [Text])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateDBProxy' {Maybe [Text]
vpcSecurityGroupIds :: Maybe [Text]
$sel:vpcSecurityGroupIds:CreateDBProxy' :: CreateDBProxy -> Maybe [Text]
vpcSecurityGroupIds} -> Maybe [Text]
vpcSecurityGroupIds) (\s :: CreateDBProxy
s@CreateDBProxy' {} Maybe [Text]
a -> CreateDBProxy
s {$sel:vpcSecurityGroupIds:CreateDBProxy' :: Maybe [Text]
vpcSecurityGroupIds = Maybe [Text]
a} :: CreateDBProxy) ((Maybe [Text] -> f (Maybe [Text]))
-> CreateDBProxy -> f CreateDBProxy)
-> ((Maybe [Text] -> f (Maybe [Text]))
-> Maybe [Text] -> f (Maybe [Text]))
-> (Maybe [Text] -> f (Maybe [Text]))
-> CreateDBProxy
-> f CreateDBProxy
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
createDBProxy_tags :: Lens.Lens' CreateDBProxy (Prelude.Maybe [Tag])
createDBProxy_tags :: (Maybe [Tag] -> f (Maybe [Tag]))
-> CreateDBProxy -> f CreateDBProxy
createDBProxy_tags = (CreateDBProxy -> Maybe [Tag])
-> (CreateDBProxy -> Maybe [Tag] -> CreateDBProxy)
-> Lens CreateDBProxy CreateDBProxy (Maybe [Tag]) (Maybe [Tag])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateDBProxy' {Maybe [Tag]
tags :: Maybe [Tag]
$sel:tags:CreateDBProxy' :: CreateDBProxy -> Maybe [Tag]
tags} -> Maybe [Tag]
tags) (\s :: CreateDBProxy
s@CreateDBProxy' {} Maybe [Tag]
a -> CreateDBProxy
s {$sel:tags:CreateDBProxy' :: Maybe [Tag]
tags = Maybe [Tag]
a} :: CreateDBProxy) ((Maybe [Tag] -> f (Maybe [Tag]))
-> CreateDBProxy -> f CreateDBProxy)
-> ((Maybe [Tag] -> f (Maybe [Tag]))
-> Maybe [Tag] -> f (Maybe [Tag]))
-> (Maybe [Tag] -> f (Maybe [Tag]))
-> CreateDBProxy
-> f CreateDBProxy
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso [Tag] [Tag] [Tag] [Tag]
-> Iso (Maybe [Tag]) (Maybe [Tag]) (Maybe [Tag]) (Maybe [Tag])
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 [Tag] [Tag] [Tag] [Tag]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
createDBProxy_dbProxyName :: Lens.Lens' CreateDBProxy Prelude.Text
createDBProxy_dbProxyName :: (Text -> f Text) -> CreateDBProxy -> f CreateDBProxy
createDBProxy_dbProxyName = (CreateDBProxy -> Text)
-> (CreateDBProxy -> Text -> CreateDBProxy)
-> Lens CreateDBProxy CreateDBProxy Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateDBProxy' {Text
dbProxyName :: Text
$sel:dbProxyName:CreateDBProxy' :: CreateDBProxy -> Text
dbProxyName} -> Text
dbProxyName) (\s :: CreateDBProxy
s@CreateDBProxy' {} Text
a -> CreateDBProxy
s {$sel:dbProxyName:CreateDBProxy' :: Text
dbProxyName = Text
a} :: CreateDBProxy)
createDBProxy_engineFamily :: Lens.Lens' CreateDBProxy EngineFamily
createDBProxy_engineFamily :: (EngineFamily -> f EngineFamily)
-> CreateDBProxy -> f CreateDBProxy
createDBProxy_engineFamily = (CreateDBProxy -> EngineFamily)
-> (CreateDBProxy -> EngineFamily -> CreateDBProxy)
-> Lens CreateDBProxy CreateDBProxy EngineFamily EngineFamily
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateDBProxy' {EngineFamily
engineFamily :: EngineFamily
$sel:engineFamily:CreateDBProxy' :: CreateDBProxy -> EngineFamily
engineFamily} -> EngineFamily
engineFamily) (\s :: CreateDBProxy
s@CreateDBProxy' {} EngineFamily
a -> CreateDBProxy
s {$sel:engineFamily:CreateDBProxy' :: EngineFamily
engineFamily = EngineFamily
a} :: CreateDBProxy)
createDBProxy_auth :: Lens.Lens' CreateDBProxy [UserAuthConfig]
createDBProxy_auth :: ([UserAuthConfig] -> f [UserAuthConfig])
-> CreateDBProxy -> f CreateDBProxy
createDBProxy_auth = (CreateDBProxy -> [UserAuthConfig])
-> (CreateDBProxy -> [UserAuthConfig] -> CreateDBProxy)
-> Lens
CreateDBProxy CreateDBProxy [UserAuthConfig] [UserAuthConfig]
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateDBProxy' {[UserAuthConfig]
auth :: [UserAuthConfig]
$sel:auth:CreateDBProxy' :: CreateDBProxy -> [UserAuthConfig]
auth} -> [UserAuthConfig]
auth) (\s :: CreateDBProxy
s@CreateDBProxy' {} [UserAuthConfig]
a -> CreateDBProxy
s {$sel:auth:CreateDBProxy' :: [UserAuthConfig]
auth = [UserAuthConfig]
a} :: CreateDBProxy) (([UserAuthConfig] -> f [UserAuthConfig])
-> CreateDBProxy -> f CreateDBProxy)
-> (([UserAuthConfig] -> f [UserAuthConfig])
-> [UserAuthConfig] -> f [UserAuthConfig])
-> ([UserAuthConfig] -> f [UserAuthConfig])
-> CreateDBProxy
-> f CreateDBProxy
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. ([UserAuthConfig] -> f [UserAuthConfig])
-> [UserAuthConfig] -> f [UserAuthConfig]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
createDBProxy_roleArn :: Lens.Lens' CreateDBProxy Prelude.Text
createDBProxy_roleArn :: (Text -> f Text) -> CreateDBProxy -> f CreateDBProxy
createDBProxy_roleArn = (CreateDBProxy -> Text)
-> (CreateDBProxy -> Text -> CreateDBProxy)
-> Lens CreateDBProxy CreateDBProxy Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateDBProxy' {Text
roleArn :: Text
$sel:roleArn:CreateDBProxy' :: CreateDBProxy -> Text
roleArn} -> Text
roleArn) (\s :: CreateDBProxy
s@CreateDBProxy' {} Text
a -> CreateDBProxy
s {$sel:roleArn:CreateDBProxy' :: Text
roleArn = Text
a} :: CreateDBProxy)
createDBProxy_vpcSubnetIds :: Lens.Lens' CreateDBProxy [Prelude.Text]
createDBProxy_vpcSubnetIds :: ([Text] -> f [Text]) -> CreateDBProxy -> f CreateDBProxy
createDBProxy_vpcSubnetIds = (CreateDBProxy -> [Text])
-> (CreateDBProxy -> [Text] -> CreateDBProxy)
-> Lens CreateDBProxy CreateDBProxy [Text] [Text]
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateDBProxy' {[Text]
vpcSubnetIds :: [Text]
$sel:vpcSubnetIds:CreateDBProxy' :: CreateDBProxy -> [Text]
vpcSubnetIds} -> [Text]
vpcSubnetIds) (\s :: CreateDBProxy
s@CreateDBProxy' {} [Text]
a -> CreateDBProxy
s {$sel:vpcSubnetIds:CreateDBProxy' :: [Text]
vpcSubnetIds = [Text]
a} :: CreateDBProxy) (([Text] -> f [Text]) -> CreateDBProxy -> f CreateDBProxy)
-> (([Text] -> f [Text]) -> [Text] -> f [Text])
-> ([Text] -> f [Text])
-> CreateDBProxy
-> f CreateDBProxy
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. ([Text] -> f [Text]) -> [Text] -> f [Text]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
instance Core.AWSRequest CreateDBProxy where
type
AWSResponse CreateDBProxy =
CreateDBProxyResponse
request :: CreateDBProxy -> Request CreateDBProxy
request = Service -> CreateDBProxy -> Request CreateDBProxy
forall a. ToRequest a => Service -> a -> Request a
Request.postQuery Service
defaultService
response :: Logger
-> Service
-> Proxy CreateDBProxy
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse CreateDBProxy)))
response =
Text
-> (Int
-> ResponseHeaders
-> [Node]
-> Either String (AWSResponse CreateDBProxy))
-> Logger
-> Service
-> Proxy CreateDBProxy
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse CreateDBProxy)))
forall (m :: * -> *) a.
MonadResource m =>
Text
-> (Int
-> ResponseHeaders -> [Node] -> Either String (AWSResponse a))
-> Logger
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveXMLWrapper
Text
"CreateDBProxyResult"
( \Int
s ResponseHeaders
h [Node]
x ->
Maybe DBProxy -> Int -> CreateDBProxyResponse
CreateDBProxyResponse'
(Maybe DBProxy -> Int -> CreateDBProxyResponse)
-> Either String (Maybe DBProxy)
-> Either String (Int -> CreateDBProxyResponse)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> ([Node]
x [Node] -> Text -> Either String (Maybe DBProxy)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"DBProxy")
Either String (Int -> CreateDBProxyResponse)
-> Either String Int -> Either String CreateDBProxyResponse
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Int -> Either String Int
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure (Int -> Int
forall a. Enum a => a -> Int
Prelude.fromEnum Int
s))
)
instance Prelude.Hashable CreateDBProxy
instance Prelude.NFData CreateDBProxy
instance Core.ToHeaders CreateDBProxy where
toHeaders :: CreateDBProxy -> ResponseHeaders
toHeaders = ResponseHeaders -> CreateDBProxy -> ResponseHeaders
forall a b. a -> b -> a
Prelude.const ResponseHeaders
forall a. Monoid a => a
Prelude.mempty
instance Core.ToPath CreateDBProxy where
toPath :: CreateDBProxy -> ByteString
toPath = ByteString -> CreateDBProxy -> ByteString
forall a b. a -> b -> a
Prelude.const ByteString
"/"
instance Core.ToQuery CreateDBProxy where
toQuery :: CreateDBProxy -> QueryString
toQuery CreateDBProxy' {[Text]
[UserAuthConfig]
Maybe Bool
Maybe Int
Maybe [Text]
Maybe [Tag]
Text
EngineFamily
vpcSubnetIds :: [Text]
roleArn :: Text
auth :: [UserAuthConfig]
engineFamily :: EngineFamily
dbProxyName :: Text
tags :: Maybe [Tag]
vpcSecurityGroupIds :: Maybe [Text]
idleClientTimeout :: Maybe Int
requireTLS :: Maybe Bool
debugLogging :: Maybe Bool
$sel:vpcSubnetIds:CreateDBProxy' :: CreateDBProxy -> [Text]
$sel:roleArn:CreateDBProxy' :: CreateDBProxy -> Text
$sel:auth:CreateDBProxy' :: CreateDBProxy -> [UserAuthConfig]
$sel:engineFamily:CreateDBProxy' :: CreateDBProxy -> EngineFamily
$sel:dbProxyName:CreateDBProxy' :: CreateDBProxy -> Text
$sel:tags:CreateDBProxy' :: CreateDBProxy -> Maybe [Tag]
$sel:vpcSecurityGroupIds:CreateDBProxy' :: CreateDBProxy -> Maybe [Text]
$sel:idleClientTimeout:CreateDBProxy' :: CreateDBProxy -> Maybe Int
$sel:requireTLS:CreateDBProxy' :: CreateDBProxy -> Maybe Bool
$sel:debugLogging:CreateDBProxy' :: CreateDBProxy -> Maybe Bool
..} =
[QueryString] -> QueryString
forall a. Monoid a => [a] -> a
Prelude.mconcat
[ ByteString
"Action"
ByteString -> ByteString -> QueryString
forall a. ToQuery a => ByteString -> a -> QueryString
Core.=: (ByteString
"CreateDBProxy" :: Prelude.ByteString),
ByteString
"Version"
ByteString -> ByteString -> QueryString
forall a. ToQuery a => ByteString -> a -> QueryString
Core.=: (ByteString
"2014-10-31" :: Prelude.ByteString),
ByteString
"DebugLogging" ByteString -> Maybe Bool -> QueryString
forall a. ToQuery a => ByteString -> a -> QueryString
Core.=: Maybe Bool
debugLogging,
ByteString
"RequireTLS" ByteString -> Maybe Bool -> QueryString
forall a. ToQuery a => ByteString -> a -> QueryString
Core.=: Maybe Bool
requireTLS,
ByteString
"IdleClientTimeout" ByteString -> Maybe Int -> QueryString
forall a. ToQuery a => ByteString -> a -> QueryString
Core.=: Maybe Int
idleClientTimeout,
ByteString
"VpcSecurityGroupIds"
ByteString -> QueryString -> QueryString
forall a. ToQuery a => ByteString -> a -> QueryString
Core.=: Maybe QueryString -> QueryString
forall a. ToQuery a => a -> QueryString
Core.toQuery
( ByteString -> [Text] -> QueryString
forall a.
(IsList a, ToQuery (Item a)) =>
ByteString -> a -> QueryString
Core.toQueryList ByteString
"member"
([Text] -> QueryString) -> Maybe [Text] -> Maybe QueryString
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [Text]
vpcSecurityGroupIds
),
ByteString
"Tags"
ByteString -> QueryString -> QueryString
forall a. ToQuery a => ByteString -> a -> QueryString
Core.=: Maybe QueryString -> QueryString
forall a. ToQuery a => a -> QueryString
Core.toQuery
(ByteString -> [Tag] -> QueryString
forall a.
(IsList a, ToQuery (Item a)) =>
ByteString -> a -> QueryString
Core.toQueryList ByteString
"Tag" ([Tag] -> QueryString) -> Maybe [Tag] -> Maybe QueryString
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [Tag]
tags),
ByteString
"DBProxyName" ByteString -> Text -> QueryString
forall a. ToQuery a => ByteString -> a -> QueryString
Core.=: Text
dbProxyName,
ByteString
"EngineFamily" ByteString -> EngineFamily -> QueryString
forall a. ToQuery a => ByteString -> a -> QueryString
Core.=: EngineFamily
engineFamily,
ByteString
"Auth" ByteString -> QueryString -> QueryString
forall a. ToQuery a => ByteString -> a -> QueryString
Core.=: ByteString -> [UserAuthConfig] -> QueryString
forall a.
(IsList a, ToQuery (Item a)) =>
ByteString -> a -> QueryString
Core.toQueryList ByteString
"member" [UserAuthConfig]
auth,
ByteString
"RoleArn" ByteString -> Text -> QueryString
forall a. ToQuery a => ByteString -> a -> QueryString
Core.=: Text
roleArn,
ByteString
"VpcSubnetIds"
ByteString -> QueryString -> QueryString
forall a. ToQuery a => ByteString -> a -> QueryString
Core.=: ByteString -> [Text] -> QueryString
forall a.
(IsList a, ToQuery (Item a)) =>
ByteString -> a -> QueryString
Core.toQueryList ByteString
"member" [Text]
vpcSubnetIds
]
data CreateDBProxyResponse = CreateDBProxyResponse'
{
CreateDBProxyResponse -> Maybe DBProxy
dbProxy :: Prelude.Maybe DBProxy,
CreateDBProxyResponse -> Int
httpStatus :: Prelude.Int
}
deriving (CreateDBProxyResponse -> CreateDBProxyResponse -> Bool
(CreateDBProxyResponse -> CreateDBProxyResponse -> Bool)
-> (CreateDBProxyResponse -> CreateDBProxyResponse -> Bool)
-> Eq CreateDBProxyResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: CreateDBProxyResponse -> CreateDBProxyResponse -> Bool
$c/= :: CreateDBProxyResponse -> CreateDBProxyResponse -> Bool
== :: CreateDBProxyResponse -> CreateDBProxyResponse -> Bool
$c== :: CreateDBProxyResponse -> CreateDBProxyResponse -> Bool
Prelude.Eq, ReadPrec [CreateDBProxyResponse]
ReadPrec CreateDBProxyResponse
Int -> ReadS CreateDBProxyResponse
ReadS [CreateDBProxyResponse]
(Int -> ReadS CreateDBProxyResponse)
-> ReadS [CreateDBProxyResponse]
-> ReadPrec CreateDBProxyResponse
-> ReadPrec [CreateDBProxyResponse]
-> Read CreateDBProxyResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [CreateDBProxyResponse]
$creadListPrec :: ReadPrec [CreateDBProxyResponse]
readPrec :: ReadPrec CreateDBProxyResponse
$creadPrec :: ReadPrec CreateDBProxyResponse
readList :: ReadS [CreateDBProxyResponse]
$creadList :: ReadS [CreateDBProxyResponse]
readsPrec :: Int -> ReadS CreateDBProxyResponse
$creadsPrec :: Int -> ReadS CreateDBProxyResponse
Prelude.Read, Int -> CreateDBProxyResponse -> ShowS
[CreateDBProxyResponse] -> ShowS
CreateDBProxyResponse -> String
(Int -> CreateDBProxyResponse -> ShowS)
-> (CreateDBProxyResponse -> String)
-> ([CreateDBProxyResponse] -> ShowS)
-> Show CreateDBProxyResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [CreateDBProxyResponse] -> ShowS
$cshowList :: [CreateDBProxyResponse] -> ShowS
show :: CreateDBProxyResponse -> String
$cshow :: CreateDBProxyResponse -> String
showsPrec :: Int -> CreateDBProxyResponse -> ShowS
$cshowsPrec :: Int -> CreateDBProxyResponse -> ShowS
Prelude.Show, (forall x. CreateDBProxyResponse -> Rep CreateDBProxyResponse x)
-> (forall x. Rep CreateDBProxyResponse x -> CreateDBProxyResponse)
-> Generic CreateDBProxyResponse
forall x. Rep CreateDBProxyResponse x -> CreateDBProxyResponse
forall x. CreateDBProxyResponse -> Rep CreateDBProxyResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep CreateDBProxyResponse x -> CreateDBProxyResponse
$cfrom :: forall x. CreateDBProxyResponse -> Rep CreateDBProxyResponse x
Prelude.Generic)
newCreateDBProxyResponse ::
Prelude.Int ->
CreateDBProxyResponse
newCreateDBProxyResponse :: Int -> CreateDBProxyResponse
newCreateDBProxyResponse Int
pHttpStatus_ =
CreateDBProxyResponse' :: Maybe DBProxy -> Int -> CreateDBProxyResponse
CreateDBProxyResponse'
{ $sel:dbProxy:CreateDBProxyResponse' :: Maybe DBProxy
dbProxy = Maybe DBProxy
forall a. Maybe a
Prelude.Nothing,
$sel:httpStatus:CreateDBProxyResponse' :: Int
httpStatus = Int
pHttpStatus_
}
createDBProxyResponse_dbProxy :: Lens.Lens' CreateDBProxyResponse (Prelude.Maybe DBProxy)
createDBProxyResponse_dbProxy :: (Maybe DBProxy -> f (Maybe DBProxy))
-> CreateDBProxyResponse -> f CreateDBProxyResponse
createDBProxyResponse_dbProxy = (CreateDBProxyResponse -> Maybe DBProxy)
-> (CreateDBProxyResponse
-> Maybe DBProxy -> CreateDBProxyResponse)
-> Lens
CreateDBProxyResponse
CreateDBProxyResponse
(Maybe DBProxy)
(Maybe DBProxy)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateDBProxyResponse' {Maybe DBProxy
dbProxy :: Maybe DBProxy
$sel:dbProxy:CreateDBProxyResponse' :: CreateDBProxyResponse -> Maybe DBProxy
dbProxy} -> Maybe DBProxy
dbProxy) (\s :: CreateDBProxyResponse
s@CreateDBProxyResponse' {} Maybe DBProxy
a -> CreateDBProxyResponse
s {$sel:dbProxy:CreateDBProxyResponse' :: Maybe DBProxy
dbProxy = Maybe DBProxy
a} :: CreateDBProxyResponse)
createDBProxyResponse_httpStatus :: Lens.Lens' CreateDBProxyResponse Prelude.Int
createDBProxyResponse_httpStatus :: (Int -> f Int) -> CreateDBProxyResponse -> f CreateDBProxyResponse
createDBProxyResponse_httpStatus = (CreateDBProxyResponse -> Int)
-> (CreateDBProxyResponse -> Int -> CreateDBProxyResponse)
-> Lens CreateDBProxyResponse CreateDBProxyResponse Int Int
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\CreateDBProxyResponse' {Int
httpStatus :: Int
$sel:httpStatus:CreateDBProxyResponse' :: CreateDBProxyResponse -> Int
httpStatus} -> Int
httpStatus) (\s :: CreateDBProxyResponse
s@CreateDBProxyResponse' {} Int
a -> CreateDBProxyResponse
s {$sel:httpStatus:CreateDBProxyResponse' :: Int
httpStatus = Int
a} :: CreateDBProxyResponse)
instance Prelude.NFData CreateDBProxyResponse