-
Notifications
You must be signed in to change notification settings - Fork 40
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
multi-service sampling rules for nginx ingress controller #253
Comments
I was able to configure different rules, by setting:
And creating a new file in the ingress controller:
|
Could you please share a nginx setup where DD_TRACE_SAMPLING_RULES is used with different services? |
ingress nginx is using a not up to date version of open-tracing-cpp. (v0.19.0). |
Hi, Marc. I don't have an example of using It would be a nice example to have, though. I looked through our code based on what you are trying to do, and noticed a few things:
The first thing to do is get details about the software versions that you're using. If based on that it's "supposed to work," then I can create a reproduction on a test kubernetes cluster. However, I can't promise I would be able to work on that anytime soon. |
Thanks for the fast response. I have run a nginx -s reload, to verify what version is being used, and the configuration for dd tracer:
Thanks for your time, and it would be great if you could do some testing on kubernetes, whenever you have time. |
Is it possible that the DD_TRACING_SAMPLE_RULES is checking the root service name? Settting service.name as opentracing tag is overriding the child span? Looking into the flame graph, when using service.name tag: I also have tested using "opentracing_trace_locations off;" which merges nginx services into the same span. |
Ooo, look at that. Yes, In your second screenshot, there is only the
We have yet to decide how we'll continue supporting the ingress controller: OpenTelemetry-only, Datadog-specific module, etc. For now we continue to maintain this OpenTracing-based plugin. |
Might as well keep this open. It's something I'd like to support. |
I have been testing to define opentracing_tag service.name to the server level instead of location, and it does not help.
Also using opentracing_trace_locations off; does not help. I was trying also another approach, and use name instead of service in sampling rules.
do not change the root resource name (still the one defined in operation_name_override or it's default nginx.handle): Thanks ! |
Is there any update on this topic? |
None, I'm afraid. My time has been spent on getting the new tracing library into Envoy and on other internal designs. Work is planned to add the new tracing library to nginx-datadog, and no later than then I'll revisit this idea of setting sampling configuration in a more fine-grained way. Sorry for the delay. |
Thanks for the update |
I should also point out that getting the new code into the ingress controller is a separate project, also planned, but that will take longer. Ideally we'd figure out a way to configure your existing system to do what you want, but I haven't spent the time yet this year. |
That would be great. Thanks again! |
I have been trying to define different SAMPLING RULES per k8s nginx ingress, but I had no success.
What I have tried:
Define sampling rules according to datadog docs.
My config:
Changing this value (service:nginx) works for all ingress, but we can not leverage of fine grained service rules as described here.
I have added annotations to my ingress to override the servicename.
Is this setup possible?
Thanks
The text was updated successfully, but these errors were encountered: