From 56a4466d0a85a9498bfd2a78a4ad3a2facb58167 Mon Sep 17 00:00:00 2001 From: Kirill Bulatov Date: Mon, 2 Jan 2023 14:34:06 +0200 Subject: [PATCH] Run Python tests in 8 threads (#3206) I have experimented with the runner threads number, and looks like 8 threads win us a few seconds. Bumping the thread count more did not improve the situation much: * 20 threads were not allowed by pytest * 16 threads were flacking quite notably My guess would be that all pageservers, safekeepers, and other nodes we start occupy quite much of the CPU and other resources to make this approach more scalable. --- .github/actions/run-python-test-set/action.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/actions/run-python-test-set/action.yml b/.github/actions/run-python-test-set/action.yml index 990c7e25a9..95167ecf6c 100644 --- a/.github/actions/run-python-test-set/action.yml +++ b/.github/actions/run-python-test-set/action.yml @@ -123,8 +123,8 @@ runs: exit 1 fi if [[ "${{ inputs.run_in_parallel }}" == "true" ]]; then - # -n4 uses four processes to run tests via pytest-xdist - EXTRA_PARAMS="-n4 $EXTRA_PARAMS" + # -n8 uses eight processes to run tests via pytest-xdist + EXTRA_PARAMS="-n8 $EXTRA_PARAMS" # --dist=loadgroup points tests marked with @pytest.mark.xdist_group # to the same worker to make @pytest.mark.order work with xdist