mirror of https://github.com/grafana/loki
Tracing: elide small traces for Stats call (#10308)
**What this PR does / why we need it**:
At work I see a lot of traces getting data dropped due to being tens of
megabytes in size.
Looking at what was captured, I see many many repeats of these four
spans:
<img width="1070" alt="image"
src="https://github.com/grafana/loki/assets/8125524/4268e664-6910-49bb-8f68-69b139a5a66b">
Events on the parent trace are cheaper and, for small operations like
this, just as useful.
Where there was an event line I added a `function` field matching the
previous span name.
For `storeEntry.Stats()` I didn't add an event line as it doesn't seem
to do very much.
But please correct me; I'm not hugely familiar with the Loki codebase.
**Special notes for your reviewer**:
**Checklist**
- [x] Reviewed the
[`CONTRIBUTING.md`](https://github.com/grafana/loki/blob/main/CONTRIBUTING.md)
guide (**required**)
- NA Documentation added
- NA Tests updated
- [x] `CHANGELOG.md` updated
- NA If the change is worth mentioning in the release notes, add
`add-to-release-notes` label
- NA Changes that require user attention or interaction to upgrade are
documented in `docs/sources/setup/upgrade/_index.md`
- NA For Helm chart changes bump the Helm chart version in
`production/helm/loki/Chart.yaml` and update
`production/helm/loki/CHANGELOG.md` and
`production/helm/loki/README.md`. [Example
PR](d10549e3ec
)
pull/10318/head
parent
b1cd5da607
commit
f89a51fde8
Loading…
Reference in new issue