Skip to content

procfs: Fix process info retention#1262

Merged
blt merged 1 commit intomainfrom
vincent.whitchurch/procfs-retention
Feb 27, 2025
Merged

procfs: Fix process info retention#1262
blt merged 1 commit intomainfrom
vincent.whitchurch/procfs-retention

Conversation

@vitkyrka
Copy link
Copy Markdown
Contributor

What does this PR do?

Currently the process process info (which includes the previous times essential for CPU usage calculation) for the target PID and for some children is erased on every call to poll since the pids hashset does not include the target PID, and the retain call is done inside the inner loop instead of after we gather all the pids.

Motivation

Noticed while evaluating lading.

Related issues

Additional Notes

Currently the process process info (which includes the previous times
essential for CPU usage calculation) for the target PID and for some
children is erased on every call to `poll` since the `pids` hashset does
not include the target PID, and the `retain` call is done inside the
inner loop instead of after we gather all the pids.
@vitkyrka vitkyrka marked this pull request as ready for review February 27, 2025 17:39
@vitkyrka vitkyrka requested a review from a team as a code owner February 27, 2025 17:39
@blt blt merged commit 2edca0c into main Feb 27, 2025
22 checks passed
@blt blt deleted the vincent.whitchurch/procfs-retention branch February 27, 2025 18:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants