Zsolt Haraszti | 5cd6470 | 2016-09-27 13:48:35 -0700 | [diff] [blame] | 1 | syntax = "proto3"; |
| 2 | |
| 3 | package schema; |
| 4 | |
Zsolt Haraszti | 2bdb6b3 | 2016-11-03 16:56:17 -0700 | [diff] [blame] | 5 | // Contains the name and content of a *.proto file |
| 6 | message ProtoFile { |
| 7 | string file_name = 1; // name of proto file |
| 8 | string proto = 2; // content of proto file |
| 9 | bytes descriptor = 3; // compiled descriptor for proto (zlib compressed) |
| 10 | } |
Zsolt Haraszti | 5cd6470 | 2016-09-27 13:48:35 -0700 | [diff] [blame] | 11 | |
Zsolt Haraszti | 2bdb6b3 | 2016-11-03 16:56:17 -0700 | [diff] [blame] | 12 | // Proto files and compiled descriptors for this interface |
| 13 | message Schemas { |
Zsolt Haraszti | 5cd6470 | 2016-09-27 13:48:35 -0700 | [diff] [blame] | 14 | |
Zsolt Haraszti | 2bdb6b3 | 2016-11-03 16:56:17 -0700 | [diff] [blame] | 15 | // Proto files |
| 16 | repeated ProtoFile protos = 1; |
Zsolt Haraszti | 5cd6470 | 2016-09-27 13:48:35 -0700 | [diff] [blame] | 17 | |
| 18 | } |
| 19 | |
| 20 | // Empty message |
| 21 | message NullMessage {} |
| 22 | |
| 23 | // Schema services |
| 24 | service SchemaService { |
| 25 | |
Zsolt Haraszti | 2bdb6b3 | 2016-11-03 16:56:17 -0700 | [diff] [blame] | 26 | // Return active grpc schemas |
| 27 | rpc GetSchema(NullMessage) returns (Schemas) {} |
Zsolt Haraszti | 5cd6470 | 2016-09-27 13:48:35 -0700 | [diff] [blame] | 28 | |
| 29 | } |