You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@rocketmq.apache.org by li...@apache.org on 2022/04/18 08:17:20 UTC
[rocketmq-apis] branch v2 updated: Add code: illegal message (#20)
This is an automated email from the ASF dual-hosted git repository.
lizhanhui pushed a commit to branch v2
in repository https://gitbox.apache.org/repos/asf/rocketmq-apis.git
The following commit(s) were added to refs/heads/v2 by this push:
new 147c57f Add code: illegal message (#20)
147c57f is described below
commit 147c57f1f2fcda124e999fafb0d1a6d2abc2b7f6
Author: Aaron Ai <ya...@alibaba-inc.com>
AuthorDate: Mon Apr 18 16:17:16 2022 +0800
Add code: illegal message (#20)
* Add code: illegal message
* Remove redundant fields
---
apache/rocketmq/v2/definition.proto | 11 +++++++++--
apache/rocketmq/v2/service.proto | 10 +++-------
2 files changed, 12 insertions(+), 9 deletions(-)
diff --git a/apache/rocketmq/v2/definition.proto b/apache/rocketmq/v2/definition.proto
index 6679253..cc5df5c 100644
--- a/apache/rocketmq/v2/definition.proto
+++ b/apache/rocketmq/v2/definition.proto
@@ -441,10 +441,10 @@ enum Code {
// Slave persistence timeout.
SLAVE_PERSISTENCE_TIMEOUT = 26;
- // The HA-machanism is not working now.
+ // The HA-mechanism is not working now.
HA_NOT_AVAILABLE = 27;
- // Operation is not allowd in current version.
+ // Operation is not allowed in current version.
VERSION_UNSUPPORTED = 28;
// Message not found from server.
@@ -453,6 +453,13 @@ enum Code {
// Message offset is illegal.
ILLEGAL_MESSAGE_OFFSET = 30;
+ // Illegal message is for the sake of backward compatibility. In most case,
+ // more definitive code is better, e.g. `ILLEGAL_MESSAGE_TAG`.
+ ILLEGAL_MESSAGE = 31;
+
+ // Client type could not be recognized.
+ UNRECOGNIZED_CLIENT_TYPE = 32;
+
// Code indicates that the server encountered an unexpected condition
// that prevented it from fulfilling the request.
// This error response is a generic "catch-all" response.
diff --git a/apache/rocketmq/v2/service.proto b/apache/rocketmq/v2/service.proto
index 2139695..81d5d4f 100644
--- a/apache/rocketmq/v2/service.proto
+++ b/apache/rocketmq/v2/service.proto
@@ -48,8 +48,6 @@ option java_outer_classname = "MQService";
// results based on these particular requirements.
message QueryRouteRequest {
Resource topic = 1;
-
- Endpoints endpoints = 2;
}
message QueryRouteResponse {
@@ -82,11 +80,9 @@ message ReceiveMessageRequest {
Resource group = 1;
MessageQueue message_queue = 2;
FilterExpression filter_expression = 3;
- google.protobuf.Timestamp initialization_timestamp = 4;
- int32 batch_size = 5;
- google.protobuf.Duration invisible_duration = 6;
- google.protobuf.Duration await_duration = 7;
- bool fifo = 8;
+ int32 batch_size = 4;
+ // Required if client type is simple consumer.
+ optional google.protobuf.Duration invisible_duration = 5;
}
message ReceiveMessageResponse {