elastic / elastic/apm-agent-php
Send span only if duration geater than a threshold (ELASTIC_APM_SPAN_MIN_DURATION)
Open
agent-php
enhancement
priority: low
triaged
- Dominant language
- PHP
- Stars
- 268
- Forks
- 86
- PR merge metrics
- No merged PRs in 30d
Description
**Is your feature request related to a problem? Please describe.**
I use agent on a website with a lot of db queries. I don't necessary need all span about that, just slower
**Describe the solution you'd like**
Be able to have an option like ELASTIC_APM_SPAN_MIN_DURATION
Perhaps be able to specify a threshold by span type (eg : ELASTIC_APM_SPAN_MIN_DURATION="mysql:5ms,http:50ms...'
**Additional context**
I tested a solution by implemented that on endSpanEx method by setted isDropped property to true
I didn't update code about options..., but if you think it's a good idea, I can do on a PR
Contributor guide
Assessment
This issue has not been assessed yet.