From bd722d366e1787f101dd26e8770e24f22970a4f7 Mon Sep 17 00:00:00 2001 From: lpiwowar Date: Tue, 21 Dec 2021 09:42:28 +0100 Subject: [PATCH] Set default value of --concurrency to 2 There is a non-negligible number of tests in tempest that need accounts generated by account-generator with a concurrency of at least 2. Running these tests with accounts generated with the current default value for concurrency makes them therefore fail. This change sets the default value for concurrency to 2 and updates the documentation for --concurrency parameter. Closes-Bug: #1948935 Change-Id: Iada980beff9db3c8cd02c84d0d7602264b66ddf8 --- ...t-value-of-concurrency-to-2-d916d5c31e3725d5.yaml | 6 ++++++ tempest/cmd/account_generator.py | 12 ++++++------ 2 files changed, 12 insertions(+), 6 deletions(-) create mode 100644 releasenotes/notes/set-default-value-of-concurrency-to-2-d916d5c31e3725d5.yaml diff --git a/releasenotes/notes/set-default-value-of-concurrency-to-2-d916d5c31e3725d5.yaml b/releasenotes/notes/set-default-value-of-concurrency-to-2-d916d5c31e3725d5.yaml new file mode 100644 index 0000000000..0d964a92e4 --- /dev/null +++ b/releasenotes/notes/set-default-value-of-concurrency-to-2-d916d5c31e3725d5.yaml @@ -0,0 +1,6 @@ +--- +fixes: + - | + [`bug 1948935 `_] + The default value of account-generator --concurrency parameter is now + set to 2 instead of 1. diff --git a/tempest/cmd/account_generator.py b/tempest/cmd/account_generator.py index 917262ed28..ad0b547689 100755 --- a/tempest/cmd/account_generator.py +++ b/tempest/cmd/account_generator.py @@ -81,11 +81,11 @@ Optional Arguments will have the prefix with the given TAG in its name. Using tag is recommended for the further using, cleaning resources. -* ``-r, --concurrency CONCURRENCY`` (Optional) Concurrency count - (default: 1). The number of accounts required can be estimated as - CONCURRENCY x 2. Each user provided in *accounts.yaml* file will be in - a different tenant. This is required to provide isolation between test for - running in parallel. +* ``-r, --concurrency CONCURRENCY`` (Optional) Concurrency count (default: 2). + The number of accounts generated will be same as CONCURRENCY. The higher the + number, the more tests will run in parallel. If you want to run tests + sequentially then use 1 as value for concurrency (beware that tests that need + more credentials will fail). * ``--with-admin`` (Optional) Creates admin for each concurrent group (default: False). @@ -236,7 +236,7 @@ def _parser_add_args(parser): dest='tag', help='Resources tag') parser.add_argument('-r', '--concurrency', - default=1, + default=2, type=positive_int, required=False, dest='concurrency',