A group identifies a set of producers or consumers that share the same publishing or subscription logic. Create a group ID in the ApsaraMQ for RocketMQ console before sending or receiving messages.
Limitations
-
A group ID cannot be shared across instances. A group ID created in instance A cannot be used in instance B.
-
A group ID is required for consumers but is optional for producers.
-
Group IDs cannot be created automatically. You must create group IDs manually through the console or API.
-
RocketMQ 5.x instances support only the clustering consumption mode. Broadcasting consumption cannot be configured directly. To achieve broadcast-like behavior, create multiple consumer groups that each subscribe to the same topic.
-
Messages in the same queue are consumed in parallel by different consumer groups. Consumer groups are independent and do not affect each other.
Create a group
Log on to the ApsaraMQ for RocketMQ console. In the left-side navigation pane, click Instances.
In the top navigation bar, select a region, such as China (Hangzhou). On the Instances page, click the name of the instance that you want to manage.
-
In the left navigation pane, click Groups.
-
On the Groups page, click Create Group.
-
In the Create Group panel, configure the parameters and then click OK.
The parameters include: Group ID (1 to 60 characters), Delivery Order (select Concurrent Delivery or Ordered Delivery; in concurrent mode, message order is not guaranteed), and Description (up to 128 characters). Expand the Retry and Dead-Letter Rules section to configure the Retry Policy (default is exponential backoff), Maximum Retries (default is 16), and the Save Dead-Letter Messages switch. If this switch is turned off, messages are discarded after the maximum number of retries is exceeded.
View group list
Log on to the ApsaraMQ for RocketMQ console. In the left-side navigation pane, click Instances.
In the top navigation bar, select a region, such as China (Hangzhou). On the Instances page, click the name of the instance that you want to manage.
-
In the left navigation pane, click Groups.
-
On the Groups page, you can view all groups in the current instance.
Query group details
-
On the Groups page, find the target group and click Details in the Actions column.
-
On the Group Details page, view the group details.
View runtime information
-
On the Groups page, find the target group and click Details in the Actions column.
-
On the Group Details page, click the Running Information tab.
Edit a group
-
On the Groups page, find the target group and click Details in the Actions column.
-
On the Group Details page, click the Basic Information tab. In the Basic Information section, click Edit.
-
In the Update Group panel, configure the parameters and then click OK.
The parameters include: Group ID (1 to 60 characters), Delivery Order (select Concurrent Delivery or Ordered Delivery; in concurrent mode, message order is not guaranteed), and Description (up to 128 characters). Expand the Retry and Dead-Letter Rules section to configure the Retry Policy (default is exponential backoff), Maximum Retries (default is 16), and the Save Dead-Letter Messages switch. If this switch is turned off, messages are discarded after the maximum number of retries is exceeded.
Delete a group
After you delete a group ID, consumer instances identified by this group ID immediately stop receiving messages, and all associated resources are permanently deleted. Proceed with caution.
-
On the Groups page, find the target group and click Details in the Actions column.
-
On the Group Details page, click the Basic Information tab. In the Basic Information section, click Delete Group.
-
In the Note dialog box, click OK.
Reset consumer offset
-
On the Groups page, find the target group and click Details in the Actions column.
-
On the Group Details page, click the Basic Information tab. In the Basic Information section, click Reset Consumer Offset.
-
In the Reset Consumer Offset panel, select the target topic and a reset method, and then click OK.
WarningIf you select Start Consumption from Latest Offset, all backlogged messages for the group ID in the specified topic are skipped. This operation takes about 2 to 3 minutes to take effect. Do not repeat it during this period. All consumers in the group pause consumption for 2 to 3 minutes. Exercise caution for latency-sensitive services.
-
Start Consumption from Latest Offset: The consumer group skips all backlogged (unconsumed) messages in the specified topic and starts consuming from the latest message.
-
Start Consumption from Offset Corresponding to Specified Point in Time: A time picker appears. Specify a point in time. The consumer group starts consuming messages sent after this time, regardless of whether previous messages have been consumed.
-
-
In the Note dialog box, review the information and click OK.
View dashboard
The dashboard displays producer, billing, and throttling metrics for the instance. For details, see Dashboard.
-
On the Groups page, find the target group and click Details in the Actions column.
-
On the Group Details page, click the Dashboard tab.
More operations
To import and export groups, see Import and export groups.
FAQ
Why does the consumption mode display as "-" in the console group list or after importing a group?
The consumption mode is specified in your consumer client code through the MessageModel parameter, not through the console. The console displays the consumption mode only after the consumer client connects to the broker.
If the consumption mode displays as "-", the consumer has not reported this information yet. This does not indicate that broadcasting consumption is enabled. The default mode is clustering.
The Import Groups feature does not include a consumption mode field. An imported group displays "-" until a consumer client connects and reports its MessageModel configuration.
Troubleshooting steps:
-
Verify that your consumer SDK is configured with
MessageModelcorrectly. -
Force-refresh the browser page (Ctrl+F5) or wait a moment and retry.
-
Navigate to the Topic Details page to check the consumption mode for more accurate information.
How do I pause or stop the delivery of a specific message?
The console and API do not support pausing or stopping the delivery of a specific message.
The following workarounds are available:
-
Skip by message ID — In your consumer code, immediately return a successful consumption acknowledgment for the target message ID. The broker marks the message as consumed and stops redelivering it without executing the actual processing logic.
-
Switch consumer group — Create a new consumer group and reconfigure your consumers to subscribe through the new group. Unconsumed messages in the original group are not delivered to the new group, effectively bypassing problematic messages and avoiding continuous retries.
Is CODE 25 (subscription not latest) returned for a legitimate group related to authentication failure?
CODE 25 (subscription not latest) is typically not related to authentication failures. These are independent error mechanisms.
A common cause is a mismatch in the client access method. For example, using the open-source Apache RocketMQ client instead of the Alibaba Cloud ONS client SDK can cause inconsistent subscription versions or rebalance anomalies, resulting in this error.
Recommended action: Update your client code to follow the standard sample code in the Alibaba Cloud RocketMQ documentation and retest. If the issue persists, verify that the consumer group's subscription configuration is consistent across all consumer instances.
Related documents
You can also manage groups by calling the following API operations: