How trace gRPC service (server side) using collector #1514
victorpacheco3107
started this conversation in
General
Replies: 1 comment
-
My error is in this lines:
I removed this line and it worked! |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hi.
I'm using a collector to trace my spans in my java services, this serivces are http and grpc. The collector endpoint is localhost:55680. This java services trace succesfully.
Now, I want to use this collector to trace my go service based on gRPC.
In my go service, I copy this files: interceptor.go and grpctrace.go from repo opentelemetry-go-contrib, here https://github.com/open-telemetry/opentelemetry-go-contrib/tree/main/instrumentation/google.golang.org/grpc/otelgrpc
Now, I create a file called config.go:
Now, when I start my gRPC server, I do this:
This is the server interceptor, this is called every petition:
The first petition, I get this message:
rpc error: code = Canceled desc = context canceled
For the nexts petitions, I get this message:
exporter disconnected
I check the collector log, and It seems that no request comes.
Any idea why it doesn't work? What am I doing wrong?
Thanks!!!
Beta Was this translation helpful? Give feedback.
All reactions