grpc
简介
依赖protobuf的简易grpc实现
etcdv3 快速启动
- 克隆此项目
- 命令行 cd 至 grpc 文件夹下,运行gip compile 安装依赖的pkg
- 运行 etcdv3/etcd.exe
- vs code 打开/grpc/etcdv3/test_sample.gs
- F5运行test_sample.gs
使用方法
- 调用codegen.gs 中 import_files("proto_path", "proto_nam");生成 xxx_server.gs以及client_stub.gs
- 在xxx_server.gs中实现proto中定义的函数后,运行xxx_server.gs
- 客户端 import client_stub.gs 调用client_stub.func_name()即可
Todo
cicd用较新的driver版本时, 没有设置 --require all命令, 导致编译时找不到json等