Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Reflections Service not implemented #3

Open
chrispsommers opened this issue May 20, 2019 · 3 comments
Open

Reflections Service not implemented #3

chrispsommers opened this issue May 20, 2019 · 3 comments
Assignees
Labels
enhancement New feature or request

Comments

@chrispsommers
Copy link

I tried grpc_cli ls per your instructions (I'm familiar with it). Seems like Reflections was not installed in the server? BTW grpc_call... worked fine. This is a cool project,thanks.

~/angular-nest-grpc$ grpc_cli ls  localhost:50051
D0519 18:36:43.332412210    5696 ev_posix.cc:169]            Using polling engine: epollex
D0519 18:36:43.332473558    5696 dns_resolver.cc:338]        Using native dns resolver
D0519 18:36:43.332562163    5696 dns_resolver.cc:279]        Start resolving.
I0519 18:36:43.333143564    5696 subchannel.cc:841]          New connected subchannel at 0xca4970 for subchannel 0x7f6608002e80
Received an error when querying services endpoint.
I0519 18:36:43.333755422    5696 proto_reflection_descriptor_database.cc:47] Reflection request not implemented; is the ServerReflection service enabled?
I0519 18:36:43.333767009    5696 proto_reflection_descriptor_database.cc:51] ServerReflectionInfo rpc failed. Error code: 12, details: RPC method not implemented /grpc.reflection.v1alpha.ServerReflection/ServerReflectionInfo
```

@kmturley
Copy link
Owner

Thanks Chris, glad the project is useful!

I wasn't aware of Reflection functionality but found the documentation:
"The primary usecase for server reflection is to write (typically) command line debugging tools for talking to a grpc server."
https://github.com/grpc/grpc/blob/master/doc/server-reflection.md

I'm not familiar with the approach, buts seems by reading that article that it is not implemented in NodeJS yet. The issue open for it:
grpc/grpc-node#79

So it doesn't looks like I can add support for it. Unless using a library like Protobuf.js which seems to support:
https://github.com/protobufjs/protobuf.js#using-reflection-only

But I'm using NestJS which is it's own framework!

@kmturley kmturley self-assigned this May 20, 2019
@kmturley kmturley added the enhancement New feature or request label May 20, 2019
@chrispsommers
Copy link
Author

chrispsommers commented May 20, 2019

Hi @kmturley ,
Yeah, you have to enable Reflections as a service into the gRPC server itself. It's shame this doesn't come baked into nodejs or NestJs. It's a piece of cake in Python, a couple lines of code. I love it. I actually don't intend to use a JS-based server so this isn't a problem for me. I do want to try Angular, grpc-web and envoy, but with a different gRPC server, not necessarily even under my control. So your project is a great starting point. I especially like how you illustrated using docker-compose to make it a snap to get going.

Thanks, Chris.

@kmturley
Copy link
Owner

No problem! If I have time I will definitely investigate this though, seems like it could be a useful feature.

The docker compose file makes it really quick and portable! Should be easy to swap out for a python server!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants