-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
gRPC storage plugins - how to debug? #1529
Comments
After changing my plugin to use hclog, and only logging at level Warn and above, I still see zero useful logs. The following log was produced with the grpc/config/config.go hack described earlier. Without the hack, the non-JSON lines are omitted:
Logger instantiated like this:
|
@gianarb & @jacobmarble are you in a friendly competition about InfluxDB plugin? :-) |
this sounds like a potential enhancement to the CLI flags so that the log level can be passed to the plugin binary from jaeger-component |
Hello Yuri! Nop same project but far as timezones. As I told you via email I was able to run tt successfully locally. But probably when I left and Jacob tried by himself I was not able to get the same behavior and he starts his troubleshooting. I think it will be nice to have the Anyway. We have @goller with his team as verifying that code and data structure all good, and probably next week you are gonna have a look as well! There is a general feeling of excitement about being able to distribute influxdb as a backend for influxdb. We have a fork that runs in our system since a couple of weeks now! |
I want to help with this one. As I see it there are two ways to do this
I think the first option is better only if it will be |
I think option 2 allows for better control. If you are debugging plugin issues you may not need all debug logs from Jaeger. I'm not clear if this will address the startup logs issue. |
This is just an other option in addition to logging solution, attach debugger to a running gRPC plugin:
or |
Requirement - what kind of business use case are you trying to solve?
I'm writing a gRPC storage plugin for InfluxDB #272
Problem - what in Jaeger blocks you from solving the requirement?
Originally, the InfluxDB storage plugin was developed in a fork of the Jaeger repo. I copied that code into a new repo, which uses the gRPC framework instead.
https://github.com/influxdata/jaeger-influxdb
The plugin has a bug, which manifests as an effectively empty message:
In order to figure out what's going on, I changed this the plugin client log level from
Warn
toDebug
. Without this change, I have zero ability to debug/diagnose plugin problems:jaeger/plugin/storage/grpc/config/config.go
Lines 39 to 49 in 7ae02d4
Proposal - what do you suggest to solve the problem or improve the existing situation?
The plugin client log level should match (if possible) the Jaeger service log level, and that the plugin log should be piped to the service's logger. It's a little awkward because hashicorp's plugin library uses
hclog
while Jaeger services usezap
.Add plugin client log level as a service option. For me, this allows stack traces through, which is very helpful.
Looks like this is a known issue, from the last section of the README in Create README for developing grpc storage plugins #1518 #1525. I'll certainly modify my plugin accordingly, but maybe (2) above is a suitable workaround for the exception described?
The text was updated successfully, but these errors were encountered: