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/19 08:02:44 UTC
[rocketmq-apis] branch v2 updated: Remove unused RPCs and introduce server side stream to mitigate performance issue
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 89eb607 Remove unused RPCs and introduce server side stream to mitigate performance issue
89eb607 is described below
commit 89eb607ee0a07b3a5de6eca3b15e17bb5b5d2059
Author: Li Zhanhui <li...@gmail.com>
AuthorDate: Tue Apr 19 08:02:15 2022 +0000
Remove unused RPCs and introduce server side stream to mitigate performance issue
---
apache/rocketmq/v2/definition.proto | 13 ----------
apache/rocketmq/v2/service.proto | 49 ++-----------------------------------
2 files changed, 2 insertions(+), 60 deletions(-)
diff --git a/apache/rocketmq/v2/definition.proto b/apache/rocketmq/v2/definition.proto
index 3856838..f76601c 100644
--- a/apache/rocketmq/v2/definition.proto
+++ b/apache/rocketmq/v2/definition.proto
@@ -277,19 +277,6 @@ message Message {
message Assignment { MessageQueue message_queue = 1; }
-enum QueryOffsetPolicy {
- QUERY_OFFSET_POLICY_UNSPECIFIED = 0;
-
- // Use this option if client wishes to playback all existing messages.
- BEGINNING = 1;
-
- // Use this option if client wishes to skip all existing messages.
- END = 2;
-
- // Use this option if time-based seek is targeted.
- TIME_POINT = 3;
-}
-
message SendReceipt {
string message_id = 1;
string transaction_id = 2;
diff --git a/apache/rocketmq/v2/service.proto b/apache/rocketmq/v2/service.proto
index 0ff6fb2..5c5c8d1 100644
--- a/apache/rocketmq/v2/service.proto
+++ b/apache/rocketmq/v2/service.proto
@@ -145,34 +145,6 @@ message EndTransactionRequest {
message EndTransactionResponse { Status status = 1; }
-message QueryOffsetRequest {
- MessageQueue message_queue = 1;
- QueryOffsetPolicy policy = 2;
- google.protobuf.Timestamp time_point = 3;
-}
-
-message QueryOffsetResponse {
- Status status = 1;
- int64 offset = 2;
-}
-
-message PullMessageRequest {
- Resource group = 1;
- MessageQueue message_queue = 2;
- int64 offset = 3;
- int32 batch_size = 4;
- google.protobuf.Duration await_time = 5;
- FilterExpression filter_expression = 6;
-}
-
-message PullMessageResponse {
- Status status = 1;
- int64 min_offset = 2;
- int64 next_offset = 3;
- int64 max_offset = 4;
- repeated Message messages = 5;
-}
-
message PrintThreadStackTraceCommand { string nonce = 1; }
message ThreadStackTrace {
@@ -384,7 +356,8 @@ service MessagingService {
// or consumer group doesn't exist, returns `NOT_FOUND`. If there is no new
// message in the specific topic, returns `OK` with an empty message set.
// Please note that client may suffer from false empty responses.
- rpc ReceiveMessage(ReceiveMessageRequest) returns (ReceiveMessageResponse) {}
+ rpc ReceiveMessage(ReceiveMessageRequest)
+ returns (stream ReceiveMessageResponse) {}
// Acknowledges the message associated with the `receipt_handle` or `offset`
// in the `AckMessageRequest`, it means the message has been successfully
@@ -411,24 +384,6 @@ service MessagingService {
// Commits or rollback one transactional message.
rpc EndTransaction(EndTransactionRequest) returns (EndTransactionResponse) {}
- // Queries the offset of the specific message queue, returns the offset with
- // `OK` if success. The message server should maintain a numerical offset for
- // each message in a message-queue.
- rpc QueryOffset(QueryOffsetRequest) returns (QueryOffsetResponse) {}
-
- // Pulls messages from the specific message-queue, returns a set of messages
- // with next pull offset. The pulled messages can't be acked or nacked, while
- // the client is responsible for manage offsets for consumer, typically update
- // consume offset to local memory or a third-party storage service.
- //
- // If the pending concurrent receive requests exceed the quota of the given
- // consumer group, returns `UNAVAILABLE`. If the upstream store server hangs,
- // return `DEADLINE_EXCEEDED` in a timely manner. If the corresponding topic
- // or consumer group doesn't exist, returns `NOT_FOUND`. If there is no new
- // message in the specific topic, returns `OK` with an empty message set.
- // Please note that client may suffer from false empty responses.
- rpc PullMessage(PullMessageRequest) returns (PullMessageResponse) {}
-
// Once a client starts, it would immediately establishes bi-lateral stream
// RPCs with brokers, reporting its settings as the initiative command.
//