Add message and operation ACK messages to protos

This commit is contained in:
Mikayla 2023-10-02 17:10:03 -07:00
parent 0db4b29452
commit 32b4b4d24d
No known key found for this signature in database
2 changed files with 18 additions and 2 deletions

View file

@ -155,6 +155,7 @@ message Envelope {
UpdateChannelBufferCollaborators update_channel_buffer_collaborators = 128;
RejoinChannelBuffers rejoin_channel_buffers = 129;
RejoinChannelBuffersResponse rejoin_channel_buffers_response = 130;
AckBufferOperation ack_buffer_operation = 143;
JoinChannelChat join_channel_chat = 131;
JoinChannelChatResponse join_channel_chat_response = 132;
@ -165,10 +166,11 @@ message Envelope {
GetChannelMessages get_channel_messages = 137;
GetChannelMessagesResponse get_channel_messages_response = 138;
RemoveChannelMessage remove_channel_message = 139;
AckChannelMessage ack_channel_message = 144;
LinkChannel link_channel = 140;
UnlinkChannel unlink_channel = 141;
MoveChannel move_channel = 142;
MoveChannel move_channel = 142; // current max: 144
}
}
@ -1062,6 +1064,11 @@ message RemoveChannelMessage {
uint64 message_id = 2;
}
message AckChannelMessage {
uint64 channel_id = 1;
uint64 message_id = 2;
}
message SendChannelMessageResponse {
ChannelMessage message = 1;
}
@ -1117,6 +1124,13 @@ message RejoinChannelBuffersResponse {
repeated RejoinedChannelBuffer buffers = 1;
}
message AckBufferOperation {
uint64 buffer_id = 1;
uint64 epoch = 2;
uint64 lamport_timestamp = 3;
uint64 replica_id = 4;
}
message JoinChannelBufferResponse {
uint64 buffer_id = 1;
uint32 replica_id = 2;

View file

@ -271,6 +271,8 @@ messages!(
(LeaveChannelBuffer, Background),
(UpdateChannelBuffer, Foreground),
(UpdateChannelBufferCollaborators, Foreground),
(AckBufferOperation, Background),
(AckChannelMessage, Background),
);
request_messages!(
@ -406,7 +408,7 @@ entity_messages!(
ChannelMessageSent,
UpdateChannelBuffer,
RemoveChannelMessage,
UpdateChannelBufferCollaborators
UpdateChannelBufferCollaborators,
);
const KIB: usize = 1024;