Skip to content

Commit bab0523

Browse files
authored
Merge pull request #87 from imzs/main
Add api definition of recalling message
2 parents 37bcee2 + 935edb3 commit bab0523

File tree

2 files changed

+20
-0
lines changed

2 files changed

+20
-0
lines changed

StatusCode.md

+1
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@
3636
| CONSUMER_GROUP_NOT_FOUND |||||||||||||||
3737
| PAYLOAD_TOO_LARGE* | 🔄 | 🔄 | 🔄 | 🔄 | 🔄 | 🔄 | 🔄 | 🔄 | 🔄 | 🔄 | 🔄 | 🔄 | 🔄 | 🔄 |
3838
| MESSAGE_BODY_TOO_LARGE |||||||||||||||
39+
| MESSAGE_BODY_EMPTY |||||||||||||||
3940
| PRECONDITION_FAILED* | 🔄 | 🔄 | 🔄 | 🔄 | 🔄 | 🔄 | 🔄 | 🔄 | 🔄 | 🔄 | 🔄 | 🔄 | 🔄 | 🔄 |
4041
| TOO_MANY_REQUESTS* |||||||||||||||
4142
| REQUEST_HEADER_FIELDS_TOO_LARGE* | 🔄 | 🔄 | 🔄 | 🔄 | 🔄 | 🔄 | 🔄 | 🔄 | 🔄 | 🔄 | 🔄 | 🔄 | 🔄 | 🔄 |

apache/rocketmq/v2/service.proto

+19
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,8 @@ message SendResultEntry {
6666
string message_id = 2;
6767
string transaction_id = 3;
6868
int64 offset = 4;
69+
// Unique handle to identify message to recall, support delay message for now.
70+
string recall_handle = 5;
6971
}
7072

7173
message SendMessageResponse {
@@ -293,6 +295,17 @@ message QueryOffsetResponse {
293295
int64 offset = 2;
294296
}
295297

298+
message RecallMessageRequest {
299+
Resource topic = 1;
300+
// Refer to SendResultEntry.
301+
string recall_handle = 2;
302+
}
303+
304+
message RecallMessageResponse {
305+
Status status = 1;
306+
string message_id = 2;
307+
}
308+
296309
// For all the RPCs in MessagingService, the following error handling policies
297310
// apply:
298311
//
@@ -416,4 +429,10 @@ service MessagingService {
416429
// ChangeInvisibleDuration to lengthen invisible duration.
417430
rpc ChangeInvisibleDuration(ChangeInvisibleDurationRequest) returns (ChangeInvisibleDurationResponse) {
418431
}
432+
433+
// Recall a message,
434+
// for delay message, should recall before delivery time, like the rollback operation of transaction message,
435+
// for normal message, not supported for now.
436+
rpc RecallMessage(RecallMessageRequest) returns (RecallMessageResponse) {
437+
}
419438
}

0 commit comments

Comments
 (0)