diff --git a/apache/rocketmq/v2/definition.proto b/apache/rocketmq/v2/definition.proto index 468c410..757d97f 100644 --- a/apache/rocketmq/v2/definition.proto +++ b/apache/rocketmq/v2/definition.proto @@ -146,6 +146,9 @@ enum MessageType { // Messages that are transactional. Only committed messages are delivered to // subscribers. TRANSACTION = 4; + + // lite topic + LITE = 5; } enum DigestType { @@ -186,6 +189,8 @@ enum ClientType { PUSH_CONSUMER = 2; SIMPLE_CONSUMER = 3; PULL_CONSUMER = 4; + LITE_PUSH_CONSUMER = 5; + LITE_SIMPLE_CONSUMER = 6; } enum Encoding { @@ -270,6 +275,9 @@ message SystemProperties { // Information to identify whether this message is from dead letter queue. optional DeadLetterQueue dead_letter_queue = 20; + + // lite topic + optional string lite_topic = 21; } message DeadLetterQueue { @@ -348,6 +356,8 @@ enum Code { ILLEGAL_POLLING_TIME = 40018; // Offset is illegal. ILLEGAL_OFFSET = 40019; + // Format of lite topic is illegal. + ILLEGAL_LITE_TOPIC = 40020; // Generic code indicates that the client request lacks valid authentication // credentials for the requested resource. @@ -389,6 +399,10 @@ enum Code { // Requests are throttled. TOO_MANY_REQUESTS = 42900; + // LiteTopic related quota exceeded + LITE_TOPIC_QUOTA_EXCEEDED = 42901; + LITE_SUBSCRIPTION_QUOTA_EXCEEDED = 42902; + // Generic code for the case that the server is unwilling to process the request because its header fields are too large. // The request may be resubmitted after reducing the size of the request header fields. REQUEST_HEADER_FIELDS_TOO_LARGE = 43100; @@ -548,6 +562,25 @@ message Subscription { // Long-polling timeout for `ReceiveMessageRequest`, which is essential for // push consumer. optional google.protobuf.Duration long_polling_timeout = 5; + + // Only lite push consumer + // client-side lite subscription quota limit + optional int32 lite_subscription_quota = 6; + + // Only lite push consumer + // Maximum length limit for lite topic + optional int32 max_lite_topic_size = 7; +} + +enum LiteSubscriptionAction { + // incremental add + PARTIAL_ADD = 0; + // incremental remove + PARTIAL_REMOVE = 1; + // all add + COMPLETE_ADD = 2; + // add remove + COMPLETE_REMOVE = 3; } message Metric { diff --git a/apache/rocketmq/v2/service.proto b/apache/rocketmq/v2/service.proto index 18db185..136b3ee 100644 --- a/apache/rocketmq/v2/service.proto +++ b/apache/rocketmq/v2/service.proto @@ -114,6 +114,7 @@ message ReceiveMessageResponse { message AckMessageEntry { string message_id = 1; string receipt_handle = 2; + optional string lite_topic = 3; } message AckMessageRequest { @@ -148,6 +149,7 @@ message ForwardMessageToDeadLetterQueueRequest { string message_id = 4; int32 delivery_attempt = 5; int32 max_delivery_attempts = 6; + optional string lite_topic = 7; } message ForwardMessageToDeadLetterQueueResponse { Status status = 1; } @@ -193,6 +195,10 @@ message RecoverOrphanedTransactionCommand { string transaction_id = 2; } +message NotifyUnsubscribeLiteCommand { + string lite_topic = 1; +} + message TelemetryCommand { optional Status status = 1; @@ -221,6 +227,9 @@ message TelemetryCommand { // Request client to reconnect server use the latest endpoints. ReconnectEndpointsCommand reconnect_endpoints_command = 8; + + // Request client to unsubscribe lite topic. + NotifyUnsubscribeLiteCommand notify_unsubscribe_lite_command = 9; } } @@ -311,6 +320,21 @@ message RecallMessageResponse { string message_id = 2; } +message SyncLiteSubscriptionRequest { + LiteSubscriptionAction action = 1; + // bindTopic for lite push consumer + Resource topic = 2; + // consumer group + Resource group = 3; + // lite subscription set of lite topics + repeated string lite_topic_set = 4; + optional int64 version = 5; +} + +message SyncLiteSubscriptionResponse { + Status status = 1; +} + // For all the RPCs in MessagingService, the following error handling policies // apply: // @@ -440,4 +464,8 @@ service MessagingService { // for normal message, not supported for now. rpc RecallMessage(RecallMessageRequest) returns (RecallMessageResponse) { } + + // Sync lite subscription info, lite push consumer only + rpc SyncLiteSubscription(SyncLiteSubscriptionRequest) returns (SyncLiteSubscriptionResponse) {} + } \ No newline at end of file diff --git a/java/VERSION b/java/VERSION index b9d2bdf..50aea0e 100644 --- a/java/VERSION +++ b/java/VERSION @@ -1 +1 @@ -2.0.5 \ No newline at end of file +2.1.0 \ No newline at end of file