From eaca8a360fa6e6960549865184b8aae38fab6610 Mon Sep 17 00:00:00 2001 From: yatinkarel Date: Tue, 28 May 2024 15:35:41 +0530 Subject: [PATCH] Add some swap to tox-cover job As mentioned in the related bug we are seeing hign memory usage in the job since sqlalchemy bump to 2.0 and this leads to gate instability. Adding some swap to handle this until the issue is fixed. Also reverts the concurrency reduction change[1] that was done for this issue as that shouldn't be needed now. [1] https://review.opendev.org/c/openstack/neutron/+/920766 Related-Bug: #2065821 Change-Id: I33c4869c1d5230c0c8cc2f0dd4f6d071600bf220 --- playbooks/configure_swap.yaml | 3 +++ tox.ini | 2 +- zuul.d/job-templates.yaml | 3 +++ 3 files changed, 7 insertions(+), 1 deletion(-) create mode 100644 playbooks/configure_swap.yaml diff --git a/playbooks/configure_swap.yaml b/playbooks/configure_swap.yaml new file mode 100644 index 00000000000..aff454961de --- /dev/null +++ b/playbooks/configure_swap.yaml @@ -0,0 +1,3 @@ +- hosts: all + roles: + - configure-swap diff --git a/tox.ini b/tox.ini index 7d55f5c4e03..1a295658a38 100644 --- a/tox.ini +++ b/tox.ini @@ -157,7 +157,7 @@ setenv = {[testenv]setenv} PYTHON=coverage run --source neutron --parallel-mode commands = - stestr run --no-subunit-trace --concurrency 4 {posargs} + stestr run --no-subunit-trace {posargs} coverage combine coverage report --fail-under=82 --skip-covered coverage html -d cover diff --git a/zuul.d/job-templates.yaml b/zuul.d/job-templates.yaml index b42f4c0c5de..9d81bc44199 100644 --- a/zuul.d/job-templates.yaml +++ b/zuul.d/job-templates.yaml @@ -32,6 +32,9 @@ irrelevant-files: *irrelevant-files - openstack-tox-cover: # from openstack-cover-jobs template timeout: 4800 + pre-run: playbooks/configure_swap.yaml + vars: + configure_swap_size: 4096 irrelevant-files: *irrelevant-files - openstack-tox-py311-with-sqlalchemy-master: timeout: 3600