interface ClusterProps
Language | Type name |
---|---|
.NET | Amazon.CDK.AWS.MSK.ClusterProps |
Java | software.amazon.awscdk.services.msk.ClusterProps |
Python | aws_cdk.aws_msk.ClusterProps |
TypeScript (source) | @aws-cdk/aws-msk » ClusterProps |
Properties for a MSK Cluster.
Example
declare const vpc: ec2.Vpc;
const cluster = new msk.Cluster(this, 'cluster', {
clusterName: 'myCluster',
kafkaVersion: msk.KafkaVersion.V2_8_1,
vpc,
encryptionInTransit: {
clientBroker: msk.ClientBrokerEncryption.TLS,
},
clientAuthentication: msk.ClientAuthentication.sasl({
scram: true,
}),
});
Properties
Name | Type | Description |
---|---|---|
cluster | string | The physical name of the cluster. |
kafka | Kafka | The version of Apache Kafka. |
vpc | IVpc | Defines the virtual networking environment for this cluster. |
client | Client | Configuration properties for client authentication. |
configuration | Cluster | The Amazon MSK configuration to use for the cluster. |
ebs | Ebs | Information about storage volumes attached to MSK broker nodes. |
encryption | Encryption | Config details for encryption in transit. |
instance | Instance | The EC2 instance type that you want Amazon MSK to use when it creates your brokers. |
logging? | Broker | Configure your MSK cluster to send broker logs to different destination types. |
monitoring? | Monitoring | Cluster monitoring configuration. |
number | number | Number of Apache Kafka brokers deployed in each Availability Zone. |
removal | Removal | What to do when this resource is deleted from a stack. |
security | ISecurity [] | The AWS security groups to associate with the elastic network interfaces in order to specify who can connect to and communicate with the Amazon MSK cluster. |
vpc | Subnet | Where to place the nodes within the VPC. |
clusterName
Type:
string
The physical name of the cluster.
kafkaVersion
Type:
Kafka
The version of Apache Kafka.
vpc
Type:
IVpc
Defines the virtual networking environment for this cluster.
Must have at least 2 subnets in two different AZs.
clientAuthentication?
Type:
Client
(optional, default: disabled)
Configuration properties for client authentication.
MSK supports using private TLS certificates or SASL/SCRAM to authenticate the identity of clients.
configurationInfo?
Type:
Cluster
(optional, default: none)
The Amazon MSK configuration to use for the cluster.
ebsStorageInfo?
Type:
Ebs
(optional, default: 1000 GiB EBS volume)
Information about storage volumes attached to MSK broker nodes.
encryptionInTransit?
Type:
Encryption
(optional, default: enabled)
Config details for encryption in transit.
instanceType?
Type:
Instance
(optional, default: kafka.m5.large)
The EC2 instance type that you want Amazon MSK to use when it creates your brokers.
logging?
Type:
Broker
(optional, default: disabled)
Configure your MSK cluster to send broker logs to different destination types.
monitoring?
Type:
Monitoring
(optional, default: DEFAULT monitoring level)
Cluster monitoring configuration.
numberOfBrokerNodes?
Type:
number
(optional, default: 1)
Number of Apache Kafka brokers deployed in each Availability Zone.
removalPolicy?
Type:
Removal
(optional, default: RemovalPolicy.RETAIN)
What to do when this resource is deleted from a stack.
securityGroups?
Type:
ISecurity
[]
(optional, default: create new security group)
The AWS security groups to associate with the elastic network interfaces in order to specify who can connect to and communicate with the Amazon MSK cluster.
vpcSubnets?
Type:
Subnet
(optional, default: the Vpc default strategy if not specified.)
Where to place the nodes within the VPC.
Amazon MSK distributes the broker nodes evenly across the subnets that you specify. The subnets that you specify must be in distinct Availability Zones. Client subnets can't be in Availability Zone us-east-1e.