Class CfnDBSecurityGroup
- All Implemented Interfaces:
IConstruct
,IDependable
,IInspectable
,software.amazon.jsii.JsiiSerializable
,software.constructs.IConstruct
AWS::RDS::DBSecurityGroup
.
The AWS::RDS::DBSecurityGroup
resource creates or updates an Amazon RDS DB security group.
EC2-Classic was retired on August 15, 2022. If you haven't migrated from EC2-Classic to a VPC, we recommend that you migrate as soon as possible. For more information, see Migrate from EC2-Classic to a VPC in the Amazon EC2 User Guide , the blog EC2-Classic Networking is Retiring – Here’s How to Prepare , and Moving a DB instance not in a VPC into a VPC in the Amazon RDS User Guide .
Example:
// The code below shows an example of how to instantiate this type. // The values are placeholders you should change. import software.amazon.awscdk.services.rds.*; CfnDBSecurityGroup cfnDBSecurityGroup = CfnDBSecurityGroup.Builder.create(this, "MyCfnDBSecurityGroup") .dbSecurityGroupIngress(List.of(IngressProperty.builder() .cidrip("cidrip") .ec2SecurityGroupId("ec2SecurityGroupId") .ec2SecurityGroupName("ec2SecurityGroupName") .ec2SecurityGroupOwnerId("ec2SecurityGroupOwnerId") .build())) .groupDescription("groupDescription") // the properties below are optional .ec2VpcId("ec2VpcId") .tags(List.of(CfnTag.builder() .key("key") .value("value") .build())) .build();
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic final class
A fluent builder forCfnDBSecurityGroup
.static interface
TheIngress
property type specifies an individual ingress rule within anAWS::RDS::DBSecurityGroup
resource.Nested classes/interfaces inherited from class software.amazon.jsii.JsiiObject
software.amazon.jsii.JsiiObject.InitializationMode
Nested classes/interfaces inherited from interface software.amazon.awscdk.core.IConstruct
IConstruct.Jsii$Default
Nested classes/interfaces inherited from interface software.constructs.IConstruct
software.constructs.IConstruct.Jsii$Default
Nested classes/interfaces inherited from interface software.amazon.awscdk.core.IInspectable
IInspectable.Jsii$Default, IInspectable.Jsii$Proxy
-
Field Summary
Modifier and TypeFieldDescriptionstatic final String
The CloudFormation resource type name for this resource class. -
Constructor Summary
ModifierConstructorDescriptionCfnDBSecurityGroup
(Construct scope, String id, CfnDBSecurityGroupProps props) Create a newAWS::RDS::DBSecurityGroup
.protected
CfnDBSecurityGroup
(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) protected
CfnDBSecurityGroup
(software.amazon.jsii.JsiiObjectRef objRef) -
Method Summary
Modifier and TypeMethodDescriptionIngress rules to be applied to the DB security group.The identifier of an Amazon VPC.Provides the description of the DB security group.getTags()
An optional array of key-value pairs to apply to this DB security group.void
inspect
(TreeInspector inspector) Examines the CloudFormation resource and discloses attributes.renderProperties
(Map<String, Object> props) void
setDbSecurityGroupIngress
(List<Object> value) Ingress rules to be applied to the DB security group.void
Ingress rules to be applied to the DB security group.void
setEc2VpcId
(String value) The identifier of an Amazon VPC.void
setGroupDescription
(String value) Provides the description of the DB security group.Methods inherited from class software.amazon.awscdk.core.CfnResource
addDeletionOverride, addDependsOn, addMetadata, addOverride, addPropertyDeletionOverride, addPropertyOverride, applyRemovalPolicy, applyRemovalPolicy, applyRemovalPolicy, getAtt, getCfnOptions, getCfnResourceType, getMetadata, getUpdatedProperites, isCfnResource, shouldSynthesize, toString, validateProperties
Methods inherited from class software.amazon.awscdk.core.CfnRefElement
getRef
Methods inherited from class software.amazon.awscdk.core.CfnElement
getCreationStack, getLogicalId, getStack, isCfnElement, overrideLogicalId
Methods inherited from class software.amazon.awscdk.core.Construct
getNode, isConstruct, onPrepare, onSynthesize, onValidate, prepare, synthesize, validate
Methods inherited from class software.amazon.jsii.JsiiObject
jsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSet
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface software.amazon.jsii.JsiiSerializable
$jsii$toJson
-
Field Details
-
CFN_RESOURCE_TYPE_NAME
The CloudFormation resource type name for this resource class.
-
-
Constructor Details
-
CfnDBSecurityGroup
protected CfnDBSecurityGroup(software.amazon.jsii.JsiiObjectRef objRef) -
CfnDBSecurityGroup
protected CfnDBSecurityGroup(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) -
CfnDBSecurityGroup
@Stability(Stable) public CfnDBSecurityGroup(@NotNull Construct scope, @NotNull String id, @NotNull CfnDBSecurityGroupProps props) Create a newAWS::RDS::DBSecurityGroup
.- Parameters:
scope
-- scope in which this resource is defined.
id
-- scoped id of the resource.
props
-- resource properties.
-
-
Method Details
-
inspect
Examines the CloudFormation resource and discloses attributes.- Specified by:
inspect
in interfaceIInspectable
- Parameters:
inspector
-- tree inspector to collect and process attributes.
-
renderProperties
@Stability(Stable) @NotNull protected Map<String,Object> renderProperties(@NotNull Map<String, Object> props) - Overrides:
renderProperties
in classCfnResource
- Parameters:
props
- This parameter is required.
-
getCfnProperties
- Overrides:
getCfnProperties
in classCfnResource
-
getTags
An optional array of key-value pairs to apply to this DB security group. -
getDbSecurityGroupIngress
Ingress rules to be applied to the DB security group. -
setDbSecurityGroupIngress
Ingress rules to be applied to the DB security group. -
setDbSecurityGroupIngress
Ingress rules to be applied to the DB security group. -
getGroupDescription
Provides the description of the DB security group. -
setGroupDescription
Provides the description of the DB security group. -
getEc2VpcId
The identifier of an Amazon VPC. This property indicates the VPC that this DB security group belongs to.The
EC2VpcId
property is for backward compatibility with older regions, and is no longer recommended for providing security information to an RDS DB instance. -
setEc2VpcId
The identifier of an Amazon VPC. This property indicates the VPC that this DB security group belongs to.The
EC2VpcId
property is for backward compatibility with older regions, and is no longer recommended for providing security information to an RDS DB instance.
-