Skip to content

Adressing potential memory leak introduced with the purgeable space reporting feature#3277

Merged
SuperQ merged 1 commit intoprometheus:masterfrom
tickez:v1.9.0-patch-purgeable
Mar 26, 2025
Merged

Adressing potential memory leak introduced with the purgeable space reporting feature#3277
SuperQ merged 1 commit intoprometheus:masterfrom
tickez:v1.9.0-patch-purgeable

Conversation

@tickez
Copy link
Contributor

@tickez tickez commented Mar 22, 2025

This should fix issues reported with #3269 by using values rather than references while keeping the semantics of the original implementation.

@SuperQ , @discordianfish

Signed-off-by: Rolf Klemenz <tickez@madnet.ch>
@tickez tickez force-pushed the v1.9.0-patch-purgeable branch from a417ffa to b0bf112 Compare March 22, 2025 20:39
Copy link
Member

@SuperQ SuperQ left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not a huge fan of -1 magic values. But this makes sense in context. We don't want to use malloc() in a way that can't be explicitly freed by Go.

@SuperQ SuperQ merged commit 47e2bb3 into prometheus:master Mar 26, 2025
13 checks passed
SuperQ pushed a commit that referenced this pull request Mar 27, 2025
Signed-off-by: Rolf Klemenz <tickez@madnet.ch>
SuperQ added a commit that referenced this pull request Mar 27, 2025
* [BUGFIX] Fix Darwin memory leak #3277

Signed-off-by: Ben Kochie <superq@gmail.com>
@SuperQ SuperQ mentioned this pull request Mar 27, 2025
SuperQ added a commit that referenced this pull request Apr 1, 2025
* [BUGFIX] pressure: Fix missing IRQ on older kernels #3263
* [BUGFIX] Fix Darwin memory leak #3277

Signed-off-by: Ben Kochie <superq@gmail.com>
SuperQ added a commit that referenced this pull request Apr 1, 2025
* [BUGFIX] pressure: Fix missing IRQ on older kernels #3263
* [BUGFIX] Fix Darwin memory leak #3277

Signed-off-by: Ben Kochie <superq@gmail.com>
SuperQ added a commit that referenced this pull request Apr 1, 2025
* Avoid memory leak by using value rather than reference. (#3277)

Signed-off-by: Rolf Klemenz <tickez@madnet.ch>

* pressure: Fix missing IRQ on older kernels (#3263)

Fix "no data" error on kernels that support some PSI status, but don't
yet have IRQ presure metrics. Only report "no data" error if `pressure`
is enabled and no PSI metrics were found.

Fixes: #3259

Signed-off-by: Ben Kochie <superq@gmail.com>

* Release v1.9.1

* [BUGFIX] pressure: Fix missing IRQ on older kernels #3263
* [BUGFIX] Fix Darwin memory leak #3277

Signed-off-by: Ben Kochie <superq@gmail.com>

---------

Signed-off-by: Rolf Klemenz <tickez@madnet.ch>
Signed-off-by: Ben Kochie <superq@gmail.com>
Co-authored-by: Rolf Klemenz <tickez@madnet.ch>
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

Successfully merging this pull request may close these issues.

2 participants