Skip to content

nix(loadtest): fix cpu/mem monitoring for tests using libfaketime#5044

Merged
wolfgangwalther merged 1 commit into
PostgREST:mainfrom
wolfgangwalther:fix-loadtest-mem-cpu-faketime
Jun 26, 2026
Merged

nix(loadtest): fix cpu/mem monitoring for tests using libfaketime#5044
wolfgangwalther merged 1 commit into
PostgREST:mainfrom
wolfgangwalther:fix-loadtest-mem-cpu-faketime

Conversation

@wolfgangwalther

Copy link
Copy Markdown
Member

Instead of starting a separate process, which would make the pid we store the one from faketime instead of postgrest, we can also just start libfaketime directly via LD_PRELOAD.

Fixes the following mentioned in #5030:

Fix CPU / MEM reports. This is a pre-existing problem, which was introduced with the libfaketime change. Now, the metrics are for the faketime binary, not postgrest, which is not really helpful.

Instead of starting a separate process, which would make the pid we
store the one from `faketime` instead of `postgrest`, we can also just
start libfaketime directly via LD_PRELOAD.
@wolfgangwalther

Copy link
Copy Markdown
Member Author

Memory/CPU usage show up again for the -worst variants, works.

@wolfgangwalther wolfgangwalther marked this pull request as ready for review June 26, 2026 16:14

@steve-chavez steve-chavez left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Confirmed that the -worst variants now show regular CPU/MEM usage.

@wolfgangwalther wolfgangwalther merged commit a0bb87d into PostgREST:main Jun 26, 2026
49 of 50 checks passed
@wolfgangwalther wolfgangwalther deleted the fix-loadtest-mem-cpu-faketime branch June 26, 2026 18:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants