-
Notifications
You must be signed in to change notification settings - Fork 9.9k
Send target and metadata cache in context (again) #10636
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
Conversation
/prombench main |
|
Yes. I can do this.
I've looked into this before and couldn't find a better idea. The problem is OTel needs to look up metadata for each sample added in |
/prombench cancel |
Benchmark cancel is in progress. |
@roidelapluie Gated it behind a manager option. Could you take a look? |
The previous attempt was rolled back in #10590 due to memory issues. `sl.parentCtx` and `sl.ctx` both had a copy of the cache and target info in the previous attempt and it was hard to pin-point where the context was being retained causing the memory increase. I've experimented a bunch in #10627 to figure out that this approach doesn't cause memory increase. Beyond that, just using this info in _any_ other context is causing a memory increase. The change fixed a bunch of long-standing in the OTel Collector that the community was waiting on and release is blocked on a few downstream distrubutions of OTel Collector waiting on a fix. I propose to merge this change in while I investigate what is happening. Signed-off-by: Goutham Veeramachaneni <[email protected]>
d276fe8
to
d1176d0
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM after lint fixes
Signed-off-by: Goutham Veeramachaneni <[email protected]>
d1176d0
to
5808889
Compare
Fixed. |
wouldn't be nice to have it as a fix for the v2.35.x series ? |
There is no end user impact here, I would not release prometheus for it. as a stop gap, otel can point to the commit |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Prometheus started doing proper go.mod publishing and started off with v0.35, but this means the previous version was "winning" as it was v1.8.2 so I had to update the version everywhere. This brings in prometheus/prometheus#10636 which fixes open-telemetry#9278 Signed-off-by: Goutham Veeramachaneni <[email protected]>
* Update Prometheus to not have memory leak. Prometheus started doing proper go.mod publishing and started off with v0.35, but this means the previous version was "winning" as it was v1.8.2 so I had to update the version everywhere. This brings in prometheus/prometheus#10636 which fixes #9278 Signed-off-by: Goutham Veeramachaneni <[email protected]>
* Update Prometheus to not have memory leak. Prometheus started doing proper go.mod publishing and started off with v0.35, but this means the previous version was "winning" as it was v1.8.2 so I had to update the version everywhere. This brings in prometheus/prometheus#10636 which fixes open-telemetry#9278 Signed-off-by: Goutham Veeramachaneni <[email protected]>
* Send target and metadata cache in context (again) The previous attempt was rolled back in prometheus#10590 due to memory issues. `sl.parentCtx` and `sl.ctx` both had a copy of the cache and target info in the previous attempt and it was hard to pin-point where the context was being retained causing the memory increase. I've experimented a bunch in prometheus#10627 to figure out that this approach doesn't cause memory increase. Beyond that, just using this info in _any_ other context is causing a memory increase. The change fixed a bunch of long-standing in the OTel Collector that the community was waiting on and release is blocked on a few downstream distrubutions of OTel Collector waiting on a fix. I propose to merge this change in while I investigate what is happening. Signed-off-by: Goutham Veeramachaneni <[email protected]> * Gate the change behind a manager option Signed-off-by: Goutham Veeramachaneni <[email protected]>
@khanhntd is not a org member nor a collaborator and cannot execute benchmarks. |
The previous attempt was rolled back in #10590 due to memory issues.
sl.parentCtx
andsl.ctx
both had a copy of the cache and target infoin the previous attempt and it was hard to pin-point where the context
was being retained causing the memory increase.
I've experimented a bunch in #10627 to figure out that this approach doesn't
cause memory increase. Beyond that, just using this info in any other context
is causing a memory increase. I'm hoping just this won't cause issues but doing the following on top:
still causes a slight memory increase. So at this point, I'm not sure how to debug it.
The change fixed a bunch of long-standing in the OTel Collector that the
community was waiting on and release is blocked on a few downstream distrubutions
of OTel Collector waiting on a fix. I propose to merge this change in while
I investigate what is happening.