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

Ignore tracing health checks #1007

Open
mrewak opened this issue Jan 21, 2025 · 2 comments
Open

Ignore tracing health checks #1007

mrewak opened this issue Jan 21, 2025 · 2 comments

Comments

@mrewak
Copy link

mrewak commented Jan 21, 2025

I'd like to ignore sending traces for health check paths or even all actuator paths. My spring boot app with java instrumentation and deployed as ECS service generates many X-Ray traces unnecessary (at least for me).
We are using aws-observability/aws-otel-collector deployed as a central gateway as a ECS service.

Provide config option for the agent to ignore some of the paths or other solution to the issue:

  • ignore health paths in aws-otel-collector (?)
  • ignore health paths on the X-Ray side (?)

I've found open-telemetry/opentelemetry-java-instrumentation#1060 and probably it can be the solution but it is fixed/implemented in the latest opentelemetry java agent but not in aws-otel-java-instrumentation

@mxiamxia
Copy link
Member

You can setup X-Ray remote sampling by following the instruction below, and then create a rule to filter out the traces you don't want to send to X-Ray

  1. Steps to setup remote sampling
  2. Steps to setup X-Ray sampling rules to filter traces. In general, create a rule with URL path: <health_check_path> and set both Reservoir and Rate to 0

@mrewak
Copy link
Author

mrewak commented Jan 31, 2025

Thanks, yes, I was considering this but as a last resort as this won't stop sending unnecessary traces from the instrumented service.

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

No branches or pull requests

2 participants