-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathschema.proto
30 lines (26 loc) · 958 Bytes
/
schema.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
message Release {
required string version = 1;
optional string description = 2;
optional uint64 diffLength = 3;
optional uint64 byteLength = 4;
repeated uint64 chunks = 5 [packed=true];
}
message Header {
required string protocol = 1;
required bytes chunkFeed = 2;
}
message StatusResponse {
required string version = 1;
required Release latestRelease = 2;
required bool updateAvailable = 3;
required bool updateDownloading = 4;
required bool updateDownloaded = 5;
}
service Updater {
option (hrpc.service) = 1;
rpc Status (hrpc.Void) returns (StatusResponse) { option (hrpc.method) = 1; }
rpc OnUpdateStatus (StatusResponse) returns (hrpc.Void) { option (hrpc.method) = 2; }
rpc UpdateAndRelaunch (hrpc.Void) returns (hrpc.Void) { option (hrpc.method) = 3; }
rpc DownloadUpdate (hrpc.Void) returns (hrpc.Void) { option (hrpc.method) = 4; }
rpc NextUpdate (hrpc.Void) returns (Release) { option (hrpc.method) = 5; }
}