-
Notifications
You must be signed in to change notification settings - Fork 0
/
raft_api.proto
46 lines (38 loc) · 872 Bytes
/
raft_api.proto
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
syntax = "proto3";
package raft;
option go_package = "./api";
service RaftCall {
rpc HeartBeat(HeartBeatRequest) returns (HeartBeatResponse) {}
rpc RequestPreVote(RequestPreVoteRequest) returns (RequestPreVoteResponse) {}
rpc RequestVote(RequestVoteRequest) returns (RequestVoteResponse) {}
}
message HeartBeatRequest {
string topic = 2;
string partition = 3;
bytes arg = 1;
}
message HeartBeatResponse {
string topic = 2;
string partition = 3;
bytes result = 1;
}
message RequestPreVoteRequest {
string topic = 2;
string partition = 3;
bytes arg = 1;
}
message RequestPreVoteResponse {
string topic = 2;
string partition = 3;
bytes result = 1;
}
message RequestVoteRequest {
string topic = 2;
string partition = 3;
bytes arg = 1;
}
message RequestVoteResponse {
string topic = 2;
string partition = 3;
bytes result = 1;
}