]> git.sesse.net Git - cubemap/blob - state.proto
Canonicalize paths, so that we do not need to worry about cwd on re-exec.
[cubemap] / state.proto
1 // Corresponds to struct Client.
2 message ClientProto {
3         optional int32 sock = 1;
4         optional string remote_addr = 8;
5         optional int64 connect_time = 9;
6         optional int32 state = 2;
7         optional bytes request = 3;
8         optional string stream_id = 4;
9         optional bytes header_or_error = 5;
10         optional int64 header_or_error_bytes_sent = 6;
11         optional int64 stream_pos = 7;
12         optional int64 bytes_sent = 10;
13         optional int64 bytes_lost = 11;
14         optional int64 num_loss_events = 12;
15 };
16
17 // Corresponds to struct Stream.
18 message StreamProto {
19         optional bytes header = 1;
20         optional bytes data = 2;
21         optional int64 backlog_size = 5 [default=1048576];
22         optional int64 bytes_received = 3;
23         optional string stream_id = 4;
24 };
25
26 // Corresponds to class Input.
27 message InputProto {
28         optional int32 state = 1;
29         optional string stream_id = 2;
30         optional string url = 3;
31         optional bytes request = 4;
32         optional int32 request_bytes_sent = 5;
33         optional bytes response = 6;
34         optional bytes http_header = 10;
35         optional bytes pending_data = 7;
36         optional bool has_metacube_header = 8;
37         optional int32 sock = 9;
38 };
39
40 // Corresponds to class Acceptor.
41 message AcceptorProto {
42         optional int32 server_sock = 1;
43         optional int32 port = 2;
44 };
45
46 message CubemapStateProto {
47         optional int64 serialize_start_sec = 6;
48         optional int64 serialize_start_usec = 7;
49         repeated ClientProto clients = 1;
50         repeated StreamProto streams = 2;
51         repeated InputProto inputs = 5;
52         repeated AcceptorProto acceptors = 8;
53 };