-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathrcs.proto
76 lines (60 loc) · 1.26 KB
/
rcs.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
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
syntax = "proto3";
package rcs;
option go_package = "github.com/nmezhenskyi/rcs/internal/genproto";
service CacheService {
rpc Set (SetRequest) returns (SetReply) {}
rpc Get (GetRequest) returns (GetReply) {}
rpc Delete (DeleteRequest) returns (DeleteReply) {}
rpc Purge (PurgeRequest) returns (PurgeReply) {}
rpc Length (LengthRequest) returns (LengthReply) {}
rpc Keys (KeysRequest) returns (KeysReply) {}
rpc Ping (PingRequest) returns (PingReply) {}
}
message SetRequest {
string key = 1;
bytes value = 2;
}
message SetReply {
bool ok = 1;
string message = 2;
string key = 3;
}
message GetRequest {
string key = 1;
}
message GetReply {
bool ok = 1;
string message = 2;
string key = 3;
bytes value = 4;
}
message DeleteRequest {
string key = 1;
}
message DeleteReply {
bool ok = 1;
string message = 2;
string key = 3;
}
message PurgeRequest {}
message PurgeReply {
bool ok = 1;
string message = 2;
}
message LengthRequest {}
message LengthReply {
bool ok = 1;
string message = 2;
int64 length = 3;
}
message KeysRequest {}
message KeysReply {
bool ok = 1;
string message = 2;
repeated string keys = 3;
}
message PingRequest {}
message PingReply {
bool ok = 1;
string message = 2;
}