Commit Graph

24 Commits

Author SHA1 Message Date
Matt Benjamin
0046803534 qa/rgw: use local runner with cmdline radosgw_admin.py
Restore ability to run radosgw_admin.py unit standalone--improved
to use vstart_runner hooks.

Local rgwadmin(...) wrapper suggested as a cleanup in review by Casey.

Fixes: https://tracker.ceph.com/issues/52837

Signed-off-by: Matt Benjamin <mbenjamin@redhat.com>
2021-11-17 11:22:32 -05:00
Kefu Chai
24e7acc261 qa/tasks: drop python2 support from rgw related tests
Signed-off-by: Kefu Chai <kchai@redhat.com>
2020-07-22 11:55:49 +08:00
Kefu Chai
5d0dc8346c qa/tasks/util/rgw: use StringIO for capturing strings
this change should address the failure of
```
2020-04-06T03:07:59.152 ERROR:teuthology.contextutil:Saw exception from nested tasks
Traceback (most recent call last):
  File "/home/teuthworker/src/git.ceph.com_git_teuthology_wip-py3/teuthology/contextutil.py", line 32, in nested
    vars.append(enter())
  File "/usr/lib/python3.5/contextlib.py", line 59, in __enter__
    return next(self.gen)
  File "/home/teuthworker/src/github.com_tchaikov_ceph_wip-qa-py3/qa/tasks/rgw.py", line 266, in configure_compression
    rgwadmin(ctx, client, cmd=['user', 'list'], check_status=True)
  File "/home/teuthworker/src/github.com_tchaikov_ceph_wip-qa-py3/qa/tasks/util/rgw.py", line 43, in rgwadmin
    j = json.loads(out)
  File "/usr/lib/python3.5/json/__init__.py", line 312, in loads
    s.__class__.__name__))
TypeError: the JSON object must be str, not 'bytes'
```

Signed-off-by: Kefu Chai <kchai@redhat.com>
2020-04-07 21:51:23 +08:00
Kefu Chai
947a74349d qa: import with full path
to be py3 compatible

Signed-off-by: Kefu Chai <kchai@redhat.com>
2020-03-24 18:27:55 +08:00
Kyr Shatskyy
683421ea24 qa/tasks/util/rgw: get rid of cString for py3
Signed-off-by: Kyr Shatskyy <kyrylo.shatskyy@suse.com>
2020-03-06 10:19:55 +01:00
Thomas Bechtold
f5e77561e9 qa: Fix problems detected by mypy
This is a first step to enable mypy on the qa/ directory.

Signed-off-by: Thomas Bechtold <tbechtold@suse.com>
2020-03-05 06:53:31 +01:00
Thomas Bechtold
0127cd1e88 qa: Enable flake8 tox and fix failures
There were a couple of problems found by flake8 in the qa/
directory (most of them fixed now). Enabling flake8 during the usual
check runs hopefully avoids adding new issues in the future.

Signed-off-by: Thomas Bechtold <tbechtold@suse.com>
2019-12-12 10:21:01 +01:00
Kyr Shatskyy
50b1823fac qa: get rid of iteritems for python3 compatibility
Fixes: https://tracker.ceph.com/issues/42267
Signed-off-by: Kyr Shatskyy <kyrylo.shatskyy@suse.com>
2019-10-15 11:27:39 +02:00
Kyr Shatskyy
5f95b532aa qa: get rid of iterkeys for py3 compatibility
Fixes: https://tracker.ceph.com/issues/42287

Signed-off-by: Kyr Shatskyy <kyrylo.shatskyy@suse.com>
2019-10-11 18:54:29 +02:00
Ali Maredia
9c6afa3fb5 qa: use curl in wait_for_radosgw() in util/rgw.py
Signed-off-by: Ali Maredia <amaredia@redhat.com>
2019-06-13 12:05:56 -04:00
Jason Dillaman
1e3dc02604 qa/tasks/workunit: use suite branch/SHA1 when cloning workunits
Right now it's using the Ceph branch/SHA1 but it's using the suite
Git URL.

Signed-off-by: Jason Dillaman <dillaman@redhat.com>
2018-10-12 12:41:58 -04:00
Ilya Dryomov
e1c89b51c8 qa/tasks/workunit: factor out overrides and refspec logic
Allow for reuse in the cram task.

Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
2018-09-06 22:31:55 +02:00
Casey Bodley
160240e0c1 qa/rgw: ignore errors from 'pool application enable'
Fixes: http://tracker.ceph.com/issues/21715

Signed-off-by: Casey Bodley <cbodley@redhat.com>
2017-10-09 10:25:26 -04:00
Casey Bodley
0542974504 qa: create_cache_pool no longer runs 'pool application enable'
Fixes: http://tracker.ceph.com/issues/21155

Signed-off-by: Casey Bodley <cbodley@redhat.com>
2017-08-29 10:01:04 -04:00
Casey Bodley
7c865effd8 qa: add optional 'application' to pool creation helpers
Signed-off-by: Casey Bodley <cbodley@redhat.com>
2017-08-22 14:37:02 -04:00
Sage Weil
dc7a2aaf7a erasure-code: ruleset-* -> crush-*
1) ruleset is an obsolete term, and
2) crush-{rule,failure-domain,...} is more descriptive.

Note that we are changing the names of the erasure code profile keys
from ruleset-* to crush-*.  We will update this on upgrade when the
luminous flag is set, but that means that during mon upgrade you cannot
create EC pools that use these fields.

When the upgrade completes (users sets require_osd_release = luminous)
existing ec profiles are updated automatically.

Signed-off-by: Sage Weil <sage@redhat.com>
2017-07-06 15:01:03 -04:00
Casey Bodley
c8d8b9cae1 qa/rgw: remove unused helpers in util/rgw.py
Signed-off-by: Casey Bodley <cbodley@redhat.com>
2017-05-19 15:53:37 -04:00
Casey Bodley
efb3b181fd qa/rgw: add log_level argument to rgwadmin()
changes default level from info to debug

Signed-off-by: Casey Bodley <cbodley@redhat.com>
2017-05-18 13:37:35 -04:00
Casey Bodley
b6d86be2c5 qa/rgw: add rgw_multisite task based on rgw_multi
Signed-off-by: Casey Bodley <cbodley@redhat.com>
2017-05-17 14:48:55 -04:00
Casey Bodley
746c630999 qa/rgw: move startup polling logic to util/rgw.py
Signed-off-by: Casey Bodley <cbodley@redhat.com>
2017-05-17 14:48:55 -04:00
Ali Maredia
b31b84529e rgw multisite: use get_config_master_client for radosgw_admin task
Signed-off-by: Ali Maredia <amaredia@redhat.com>
2017-04-13 12:15:50 -04:00
Ali Maredia
c5956790e6 rgw: multisite enabled over multiple clusters
Added '--cluster' to all necessary commands
ex: radosgw-admin, rados, ceph, made sure
necessary checks were in place so that clients
can be read with our without a cluster_name
preceeding them

Made master_client defined in the config for
radosgw-admin task

Signed-off-by: Ali Maredia <amaredia@redhat.com>
2017-04-13 12:15:50 -04:00
Casey Bodley
e3e3a71d1f qa: rgw task uses period instead of region-map
Signed-off-by: Casey Bodley <cbodley@redhat.com>
2017-03-20 11:50:03 -04:00
Sage Weil
c01f2ee0e2 move ceph-qa-suite dirs into qa/ 2016-12-14 11:29:55 -06:00