-
Notifications
You must be signed in to change notification settings - Fork 375
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
Symbol not found: grpc.reflection.v1alpha.ServerReflection #40
Comments
I think the issue is that grpcui, unlike grpcurl, tries to pro-actively download descriptors for all services and methods. So grpcurl would likely encounter the same problem if you ever tried to actually use grpcurl to invoke a reflection RPC. What language is your server written in? Also, can you paste the output of |
The server I'm using is written in C++ (with the official gRPC implementation from here). grpcurl seems to successfully use the reflection:
I can also successfully list/describe the methods of my own endpoints. |
@Kernald, thanks for the extra info. Hopefully I can dig into it this weekend. |
Any updates regarding this issue? I just run into the same problem. |
@manuelnp, sorry, I haven't gotten a chance to actually debug it. |
@jhump I found a solution for my case. I'm linking with grcpui statically so I need to link with grpc++_reflection using -whole-archive. Because nowhere in my code is calling to grpc.reflection.v1alpha.ServerReflection, the symbol is discarded at linking time.
|
I'll see if I can test this later this week - no promises though, I haven't worked on this in quite a while. |
|
I have the same problem, server written in c++ |
@xguo-prestolabs, can you try the compile/link options mentioned above when building your server? |
I have the same problem. It looks fine for If someone wants to reproduce it, the following script may help. curl -sL https://raw.githubusercontent.com/doraeric/p4lang-bootstrap/main/install.sh | sudo sh
cd ~
git clone https://github.com/p4lang/tutorials.git
cd ~/tutorials/exercises/basic
make The grpc server is listening on 0.0.0.0:50051 now, you can confirm with grpcurl -plaintext $VM_IP:50051 list But grpcui will fail $ grpcui -plaintext $VM_IP:50051
Failed to compute set of methods to expose: Symbol not found: gnmi.gNMI
|
I think this will be fixed in the next release. If you want to try it out before then, build I think it's possible that some of the issues were in the server's reflection implementation providing unexpected extra files in the response, and the reflection conflict making incorrect assumptions about the order of those files. Also see jhump/protoreflect#466. |
I have a similar problem (sort of) with production-ready service written in Go which uses gogo lib:
|
@inliquid, the latest release included an improvement to the server reflection client to fix cases like this. If you have already tried using that latest version and are still seeing an issue, it is likely a server-side issue. I spy "gogo" in there, and it is a known source of issues regarding inter-op with other aspects of the protobuf Go ecosystem. Is it possible that you are compiling your stuff with the standard Anyhow, admittedly that is some speculation. I've largely stayed away from gogo because I've seen weird issues like this pop up before. So it could be something totally different (possibly not even related to gogo). |
Please try grpcui -plaintext 0.0.0.0:4567 directly Failed to compute set of methods to expose: Symbol not found: *** |
On a server with reflection enabled (works fine with both grpcurl and grpcox), I get this error when running grpcui:
The text was updated successfully, but these errors were encountered: