mirror of
https://github.com/gmsec/gmsec.git
synced 2025-09-26 20:01:21 +08:00
1
This commit is contained in:
23
apidoc/proto/aaa/hello.proto
Normal file
23
apidoc/proto/aaa/hello.proto
Normal file
@@ -0,0 +1,23 @@
|
||||
syntax = "proto3"; // 指定proto版本
|
||||
|
||||
package aaa; // 指定包名
|
||||
import "common/common_public.proto";
|
||||
|
||||
option go_package = "rpc/aaa"; // 指定路径
|
||||
|
||||
// 定义aaa服务
|
||||
service aaa {
|
||||
// 定义SayHello方法
|
||||
rpc SayHello(HelloRequest) returns (HelloReply) {}
|
||||
}
|
||||
|
||||
// HelloRequest 请求结构
|
||||
message HelloRequest {
|
||||
string name = 1; // 名字
|
||||
}
|
||||
|
||||
// HelloReply 响应结构
|
||||
message HelloReply {
|
||||
string message = 1; // 消息
|
||||
common.ResultResp result = 2;// 多proto 文件样例
|
||||
}
|
Reference in New Issue
Block a user