redis rpc服务, 提供redis操作方法
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 

24 lines
452 B

syntax = "proto3";
package redisrpc;
// 使用key查询
message GetKey {
string key = 1;
}
// 使用hash key查询
message GetHashKey {
string key = 1;
string field = 2;
}
// 使用key查询响应结构
message GetResponse {
string string = 1;
}
// rpc方法
service RedisService {
rpc getByKey (GetKey) returns (GetResponse); // 使用key查询
rpc getByHashKey (GetHashKey) returns (GetResponse); // 使用hash key查询
}