You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@shenyu.apache.org by midnight <ll...@163.com> on 2021/05/25 04:57:30 UTC

Access gprc services in the gateway in a better way.

Hello everyone. 

There are still some problems with the way the shneyu-gateway connects to grpc. The shneyu-plugin-grpc and shneyu-client-grpc modules need to dependency on the shneyu-common module. 

Is there any better way to implement grpc service access?




The methods collected are:

1. Obtain the descriptor by reflect, and then call the service, but there is one more rpc call.

2. Simulate the grpc protocol, but it is more difficult, and the generated class is too complicated.

3. Upload the proto file in the background or store it in the form of metadata, and parse the proto generation method descriptor.

4. The client side reports the grpc service metadata to the registry center.

5. Define the same proto file on the plugin and the client side, and the client side exposes the service by the proto file.




Welcome everyone to discuss the above methods, or express your point, in a better way to access gprc service in the gateway.