1b5a588dfSShuo Chenpackage muduo; 2420c9859SShuo Chenoption java_package = "muduo.rpc.proto"; 3420c9859SShuo Chenoption java_outer_classname = "RpcProto"; 4420c9859SShuo Chen 5420c9859SShuo Chenenum MessageType 6420c9859SShuo Chen{ 7420c9859SShuo Chen REQUEST = 1; 8420c9859SShuo Chen RESPONSE = 2; 9420c9859SShuo Chen ERROR = 3; 10420c9859SShuo Chen} 11420c9859SShuo Chen 12420c9859SShuo Chenenum ErrorCode 13420c9859SShuo Chen{ 14420c9859SShuo Chen WRONG_PROTO = 1; 15420c9859SShuo Chen NO_SERVICE = 2; 16420c9859SShuo Chen NO_METHOD = 3; 17420c9859SShuo Chen INVALID_REQUEST = 4; 18420c9859SShuo Chen INVALID_RESPONSE = 5; 19420c9859SShuo Chen} 20420c9859SShuo Chen 21420c9859SShuo Chenmessage RpcMessage 22420c9859SShuo Chen{ 23420c9859SShuo Chen required MessageType type = 1; 24420c9859SShuo Chen required fixed64 id = 2; 25420c9859SShuo Chen 26420c9859SShuo Chen optional string service = 3; 27420c9859SShuo Chen optional string method = 4; 28420c9859SShuo Chen optional bytes request = 5; 29420c9859SShuo Chen 30420c9859SShuo Chen optional bytes response = 6; 31420c9859SShuo Chen 32420c9859SShuo Chen optional ErrorCode error = 7; 33420c9859SShuo Chen} 34