syntax = "proto3"; package rmemstore; // An action to be taken message Rpc { uint64 id = 1; uint32 code = 2; oneof command { // Response kind: ok Put put = 3; // Response kind: Value Get get = 4; } } message Response { uint64 id = 1; uint32 code = 2; oneof kind { bool ok = 3; Value value = 4; } } message Value { oneof kind { bytes blob = 1; string string = 2; Map map = 3; } } message Map { map map = 1; } // Returns response.kind.ok message Put { bytes key = 1; Value value = 2; } // Returns response.kind.value, or no value upon a miss. message Get { bytes key = 1; }