Kafka instances are tenant-exclusive, and physically isolated in deployment. You can customize the computing capabilities and storage space of a Kafka instance as required.
Before creating a Kafka instance, prepare the resources listed in Table 1.
Resource |
Requirement |
Operations |
---|---|---|
VPC and subnet |
You need to configure a VPC and subnet for the Kafka instance as required. You can use the current account's existing VPC and subnet, or create new ones. Note: VPCs must be created in the same region as the Kafka instance. |
For details on how to create a VPC and a subnet, see Creating a VPC. If you need to create and use a new subnet in an existing VPC, see Creating a Subnet for the VPC. |
Security group |
Different Kafka instances can use the same or different security groups. Before accessing a Kafka instance, configure security groups based on the access mode. For details, see Table 2. |
For details on how to create a security group, see Creating a Security Group. For details on how to add rules to a security group, see Adding a Security Group Rule. |
EIP |
To create a Kafka instance and access it over a public network, create EIPs in advance. Note the following when creating EIPs:
|
For details about how to create an EIP, see Assigning an EIP. |
KMS key |
To encrypt the disk for a Kafka instance, prepare a KMS key. The KMS key must be created in the same region as the Kafka instance. |
For details about how to create a KMS key, see Creating a Key. |
Select a region near you to ensure the lowest latency possible.
Select one AZ or at least three AZs.
You can customize a name that complies with the rules: 4–64 characters; starts with a letter; can contain only letters, digits, hyphens (-), and underscores (_).
This parameter is for enterprise users. An enterprise project manages cloud resources. The enterprise project management service unifies cloud resources in projects, and resources and members in a project. The default project is default.
Specifications: Select Cluster or Single-node.
If you select Cluster, specify the version, broker flavor and quantity, disk type, and storage space to be supported by the Kafka instance as required.
Maximum number of partitions per broker x Number of brokers = Maximum number of partitions of an instance. If the total number of partitions of all topics exceeds the upper limit of partitions, topic creation fails.
The disk type cannot be changed once the Kafka instance is created.
The storage space is consumed by message replicas, logs, and metadata. Specify the storage space based on the expected service message size, the number of replicas, and the reserved disk space. Each Kafka broker reserves 33 GB disk space for storing logs and metadata.
Disks are formatted when an instance is created. As a result, the actual available disk space is 93% to 95% of the total disk space.
The disk supports high I/O and ultra-high I/O types. For more information, see Disk Types and Performance.
Each broker of a 3.x instance can only have 100 GB storage space (not changeable).
Enabling disk encryption improves data security, but slows down disk read/write. Disk encryption depends on Key Management Service (KMS). If you enable disk encryption, select a KMS key. This parameter cannot be modified once the Kafka instance is created.
If you select Single-node, a v2.7 instance with one broker will be created.
The disk type cannot be changed once the Kafka instance is created.
The storage space is consumed by message replicas, logs, and metadata. Specify the storage space based on the expected service message size, the number of replicas, and the reserved disk space. Each Kafka broker reserves 33 GB disk space for storing logs and metadata.
Disks are formatted when an instance is created. As a result, the actual available disk space is 93% to 95% of the total disk space.
The disk supports high I/O and ultra-high I/O types. For more information, see Disk Types and Performance.
Enabling disk encryption improves data security, but slows down disk read/write. Disk encryption depends on Key Management Service (KMS). If you enable disk encryption, select a KMS key. This parameter cannot be modified once the Kafka instance is created.
A VPC provides an isolated virtual network for your Kafka instances. You can configure and manage the network as required.
After the Kafka instance is created, its VPC and subnet cannot be changed.
A security group is a set of rules for accessing a Kafka instance. You can click Manage Security Group to view or create security groups on the network console.
Before accessing a Kafka instance on the client, configure security group rules based on the access mode. For details about security group rules, see Table 2.
Public or Private Network |
Plaintext or Ciphertext |
Description |
---|---|---|
Private Network Access |
Plaintext Access |
Clients connect to the Kafka instance without SASL authentication. Once enabled, private network access cannot be disabled. Enable plaintext or ciphertext access, or both. |
Ciphertext Access |
Clients connect to the Kafka instance with SASL authentication. Once enabled, private network access cannot be disabled. Enable plaintext or ciphertext access, or both. To disable ciphertext access, contact customer service. If you enable Ciphertext Access, specify a security protocol, SASL/PLAIN, username, and password. After an instance is created, disabling and re-enabling Ciphertext Access do not affect users. |
|
Public Network Access |
Plaintext Access |
Clients connect to the Kafka instance without SASL authentication. Enable or disable plaintext access, and configure addresses for public network access. |
Ciphertext Access |
Clients connect to the Kafka instance with SASL authentication. Enable or disable ciphertext access, and configure addresses for public network access. If you enable Ciphertext Access, specify a security protocol, SASL/PLAIN, username, and password. After an instance is created, disabling and re-enabling Ciphertext Access do not affect users. |
|
Public IP Addresses |
Select the number of public IP addresses as required. If EIPs are insufficient, click Create Elastic IP to create EIPs. Then, return to the Kafka console and click Kafka instances only support IPv4 EIPs. |
Ciphertext access is unavailable for single-node instances.
The security protocol, SASL/PLAIN mechanism, username, and password are described as follows.
Parameter |
Value |
Description |
---|---|---|
Security Protocol |
SASL_SSL |
SASL is used for authentication. Data is encrypted with SSL certificates for high-security transmission. SCRAM-SHA-512 is enabled by default. To use PLAIN, enable SASL/PLAIN. What are SCRAM-SHA-512 and PLAIN mechanisms?
|
SASL_PLAINTEXT |
SASL is used for authentication. Data is transmitted in plaintext for high performance. SCRAM-SHA-512 is enabled by default. To use PLAIN, enable SASL/PLAIN. SCRAM-SHA-512 authentication is recommended for plaintext transmission. |
|
SASL/PLAIN |
- |
The SASL/PLAIN setting cannot be changed once ciphertext access is enabled. |
Username and Password |
- |
Username and password used by the client to connect to the Kafka instance. A username should contain 4 to 64 characters, start with a letter, and contain only letters, digits, hyphens (-), and underscores (_). A password must meet the following requirements:
The username cannot be changed once ciphertext access is enabled. |
This setting is disabled by default. You can enable or disable it as required.
If this option is enabled, a topic will be automatically created when a message is produced in or consumed from a topic that does not exist. By default, the topic has parameters listed in Table 4.
After you change the value of the log.retention.hours, default.replication.factor, or num.partitions parameter, the value will be used in later topics that are automatically created. For example, assume that num.partitions is changed to 5, an automatically created topic has parameters listed in Table 4.
Tags are used to identify cloud resources. When you have multiple cloud resources of the same type, you can use tags to classify them based on usage, owner, or environment.
Up to 20 tags can be added to each Kafka instance. For details about the requirements on tags, see Configuring Kafka Instance Tags.
It takes 3 to 15 minutes to create an instance. During this period, the instance status is Creating.
Instances that fail to be created do not occupy other resources.