File tree Expand file tree Collapse file tree 1 file changed +12
-1
lines changed Expand file tree Collapse file tree 1 file changed +12
-1
lines changed Original file line number Diff line number Diff line change 88### 步骤1:安装 Go
99需要 Go 1.22.7 或更高版本。
1010
11+ 还需要为生成protobuf和grpc的go文件安装一些插件:
12+ ``` bash
13+ # install protoc-gen-go to generate the go source code for protobuf messages
14+ go install google.golang.org/protobuf/cmd/protoc-gen-go@latest
15+ # install protoc-gen-go-grpc to generate the go source code for grpc services
16+ go install google.golang.org/grpc/cmd/protoc-gen-go-grpc@latest
17+ # install protoc-gen-grpc-gateway to transport HTTP to grpc
18+ go install github.com/grpc-ecosystem/grpc-gateway/v2/protoc-gen-grpc-gateway@latest
19+ # install protoc-gen-swagger to parse the swagger annotations in the proto files and generate OpenAPI docs
20+ go install github.com/grpc-ecosystem/grpc-gateway/protoc-gen-swagger@latest
21+
1122# ## 步骤2:启动 MySQL
1223例如,使用 Docker 启动 MySQL,然后创建 ` spike` 数据库:
1324
@@ -123,4 +134,4 @@ curl --location 'http://127.0.0.1:8080/v1/call_function' \
123134 "cpu": 8192,
124135 "memory": 0
125136}'
126- ```
137+ ` ` `
You can’t perform that action at this time.
0 commit comments