生成 rpc
命令
luwei@luweideMacBook-Pro-2 transform % goctl rpc template -o transform.proto
luwei@luweideMacBook-Pro-2 transform % pwd
/Users/myself/Golang/common_project/src/shorturl/rpc/transform
luwei@luweideMacBook-Pro-2 transform %
生成的模板如下
syntax = "proto3";
package transform;
message Request {
string ping = 1;
}
message Response {
string pong = 1;
}
service Transform {
rpc Ping(Request) returns(Response);
}
本作品采用《CC 协议》,转载必须注明作者和本文链接
推荐文章: