Skip to content

Shut down idle workers early to free memory#1315

Open
HosseyNJF wants to merge 1 commit intopytest-dev:masterfrom
HosseyNJF:early-worker-shutdown
Open

Shut down idle workers early to free memory#1315
HosseyNJF wants to merge 1 commit intopytest-dev:masterfrom
HosseyNJF:early-worker-shutdown

Conversation

@HosseyNJF
Copy link
Copy Markdown

When a worker finishes all its tests, tear down its gateway subprocess immediately instead of keeping it alive until the session ends. This frees memory that would otherwise be wasted by idle worker processes, which matters in CI environments with many workers.

Fixes #1314

When a worker finishes all its tests, tear down its gateway subprocess
immediately instead of keeping it alive until the session ends. This
frees memory that would otherwise be wasted by idle worker processes,
which matters in CI environments with many workers.

Fixes pytest-dev#1314
@HosseyNJF
Copy link
Copy Markdown
Author

This is the result of my tests on a large test suite.

Before this PR:

Image

After this PR:

image

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.

Shut down idle workers early to free memory when no tests are left

1 participant