ApsaraMQ for Kafka has limits on specific metrics. When you use ApsaraMQ for Kafka, you must not exceed these limits to prevent errors in your program.
The Service-Level Agreement (SLA) and its compensation terms do not cover instability caused by instance configurations that exceed the following limits.
Limits
The following table describes the limits for ApsaraMQ for Kafka.
Limit | Limit | Description |
Limiting the total number of topics and partitions | Support | The storage and coordination mechanism of ApsaraMQ for Kafka is based on partition granularity, and an excessive number of topics (and therefore partitions) leads to storage fragmentation and a decrease in cluster performance and stability. |
Minimum number of partitions per topic |
| If traffic is high, a single partition can cause data skew and hot spot issues. Set the number of partitions appropriately. |
Reducing the number of partitions for a topic | Not supported | This is a limitation of the Apache Kafka design. |
Exposing ZooKeeper | Not supported | You do not need to access ZooKeeper to use clients in Apache Kafka V0.9.0 and later. ZooKeeper in ApsaraMQ for Kafka is partially shared and is not exposed for security reasons. You do not need to understand how ZooKeeper works. |
Log on to the machine where ApsaraMQ for Kafka is deployed | Not supported | None. |
Version | Supports versions 2.2.x to 3.3.x |
To upgrade the instance version, see Upgrade instance version. |
Ratio of partitions to topics | 1:1 | The number of available topics is directly related to the total number of partitions. For example, you purchase an instance with 50 partitions, the alikafka.hw.2xlarge throughput specification, and 1,000 bonus partitions included in the specification. The total number of partitions for this instance is 50 (purchased) + 1,000 (bonus) = 1,050. The number of available topics is 1,050. Note This applies only to non-Serverless instances. |
Changing the instance region | Not supported | After an instance is purchased and deployed, its region is tied to physical resources and cannot be changed. To change the instance region, release the instance and purchase a new one. |
Changing instance network properties | Supported | You can change network properties as needed. For more information, see Upgrade instance configurations. |
Message size | 10 MB | The message size cannot exceed 10 MB. Otherwise, the message fails to be sent. |
Monitoring and alerts | Supported | Data latency is 1 minute. |
Endpoints | Specifications |
|
Single partition with cloud storage | May become unavailable during downtime or upgrades | Create more than one partition. If you must use a single partition, use local storage. Note
|
Maximum number of messages per batch | 32767 | If a single message is small, set Note This limit applies only to non-Serverless instances. |
You can no longer purchase non-Serverless ApsaraMQ for Kafka instances based on topic specifications. If your existing instance was purchased based on topic specifications, the topic-to-partition ratio is 1:16. For Professional Edition instances, the number of topics is calculated as the number of purchased topics × 2.
Quota limits
The following table describes the quota limits for ApsaraMQ for Kafka. Exceeding these limits may cause stability issues. The 'Other limits' section describes scenarios that can adversely affect the server. You must exercise caution in these scenarios to prevent server overload and related stability issues.
Unless stated otherwise, these limits apply to each cluster. To request a quota increase, submit a ticket.
In the table, `//` represents integer division, which rounds down to the nearest integer.
Limit | Condition | Description | ||
Subscription/Pay-as-you-go instances | Serverless (Basic Edition) | Serverless (Standard/Professional Edition) | ||
Connections (single node) |
Formula:
|
Formula:
| The number of TCP connections to a single broker. If you require a higher connection limit, submit a ticket. | |
Internet (SSL) connections (single node) |
Formula:
|
Formula:
| The number of Internet (SSL) TCP connections to a single broker. | |
Connection frequency (single node) | 50 per second | 150 per second | 150 per second | The number of connection attempts from a client to the server per second. This includes failed connections due to reasons such as authentication failures. |
Internet (SSL) connection frequency (single node) | 10 per second | The number of Internet (SSL) connection attempts from a client to the server per second. This includes failed connections due to reasons such as authentication failures. | ||
batch size | A batch size with a 50th percentile (TP50) of less than 4 KB is considered fragmented sending. | The size of a message batch in a PRODUCE request after the messages are batched by the sending client. To improve batching capabilities, use a client of version 2.4 or later. For more information, see Improve sending performance (reduce fragmented sending requests). | ||
Sending request frequency (cluster) |
Formula:
|
Formula:
|
Formula:
| The number of PRODUCE requests that are sent by the client per second. If you require a higher request limit, submit a ticket. |
Consumption request frequency (cluster) |
Formula:
|
Formula:
|
Formula:
| The number of FETCH requests that are sent by the client per second. If you require a higher request limit, submit a ticket. |
Consumer offset commit frequency (single node) |
Formula:
|
Formula:
| The number of `OFFSET_COMMIT` requests that are sent by the client per second. If you require a higher request limit, submit a ticket. | |
Metadata request frequency (cluster) |
Formula:
|
Formula:
| The number of metadata requests that the server receives from the client, such as METADATA, INIT_PRODUCER_ID, CREATE_ACL, and Warning Excessive requests can affect cluster stability. | |
Maximum number of partitions | For information about the maximum number of partitions for each instance specification, see Instance partitions. | The number of partitions includes partitions for different types of topics that you create. If you require a higher partition limit, submit a ticket. | ||
Create/delete partition frequency (cluster) | 900 partitions per 10 seconds | This limit includes all partition operations that are initiated from the console, OpenAPI, or Kafka Admin. | ||
Number of consumer groups (cluster) | 2,000 per cluster The recommended topic-to-group subscription ratio is 1:1 and must not exceed 3:1. | The number of consumer groups that you use. If you require a higher limit on the number of groups, submit a ticket. Warning An excessive number of consumer groups can increase the server-side coordination load and the complexity of metadata management. This may affect performance and fault recovery time. | ||
Message format version | You must use a message format version later than V1 for sending and consuming messages. | Use a client of version 2.4 or later. Warning Using an earlier Kafka message format can cause issues such as increased server-side CPU utilization, decreased throughput, and compatibility and security problems. | ||
Other limits |
| None | ||