|
|
@ -28,11 +28,12 @@ Upstreams:
|
|
|
|
- Grpc:
|
|
|
|
- Grpc:
|
|
|
|
Etcd:
|
|
|
|
Etcd:
|
|
|
|
Hosts:
|
|
|
|
Hosts:
|
|
|
|
- localhost:2379
|
|
|
|
- localhost:2379
|
|
|
|
Key: hello.rpc
|
|
|
|
Key: hello.rpc
|
|
|
|
# protoset mode
|
|
|
|
# protoset mode
|
|
|
|
ProtoSet: hello.pb
|
|
|
|
ProtoSets:
|
|
|
|
Mapping:
|
|
|
|
- hello.pb
|
|
|
|
|
|
|
|
Mappings:
|
|
|
|
- Method: get
|
|
|
|
- Method: get
|
|
|
|
Path: /pingHello/:ping
|
|
|
|
Path: /pingHello/:ping
|
|
|
|
RpcPath: hello.Hello/Ping
|
|
|
|
RpcPath: hello.Hello/Ping
|
|
|
@ -40,7 +41,7 @@ Upstreams:
|
|
|
|
Endpoints:
|
|
|
|
Endpoints:
|
|
|
|
- localhost:8081
|
|
|
|
- localhost:8081
|
|
|
|
# reflection mode, no ProtoSet settings
|
|
|
|
# reflection mode, no ProtoSet settings
|
|
|
|
Mapping:
|
|
|
|
Mappings:
|
|
|
|
- Method: post
|
|
|
|
- Method: post
|
|
|
|
Path: /pingWorld
|
|
|
|
Path: /pingWorld
|
|
|
|
RpcPath: world.World/Ping
|
|
|
|
RpcPath: world.World/Ping
|
|
|
@ -48,9 +49,15 @@ Upstreams:
|
|
|
|
|
|
|
|
|
|
|
|
## Generate ProtoSet files
|
|
|
|
## Generate ProtoSet files
|
|
|
|
|
|
|
|
|
|
|
|
- example command
|
|
|
|
- example command without external imports
|
|
|
|
|
|
|
|
|
|
|
|
```shell
|
|
|
|
```shell
|
|
|
|
protoc --descriptor_set_out=hello.pb hello.proto
|
|
|
|
protoc --descriptor_set_out=hello.pb hello.proto
|
|
|
|
```
|
|
|
|
```
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
- example command with external imports
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
```shell
|
|
|
|
|
|
|
|
protoc --include_imports --proto_path=. --descriptor_set_out=hello.pb hello.proto
|
|
|
|
|
|
|
|
```
|
|
|
|
|
|
|
|
|
|
|
|