Support filtering on zone import/export list
List operations should add the task_type criterion to the user
provided criterion.
This patch also fixes the neutron-tempest-plugin-designate-scenario
job to use the ussuri version neutron-tempest-plugin-designate-scenario-ussuri.
This is required for this patch to merge.
Change-Id: I983d930f975c109cce24a9587bba6db563b3f19f
Launchpad: 1926058
(cherry picked from commit fb9f0b33d3
)
This commit is contained in:
parent
b967e9f706
commit
92c0d3f201
|
@ -125,7 +125,7 @@
|
|||
- release-notes-jobs-python3
|
||||
check:
|
||||
jobs:
|
||||
- neutron-tempest-plugin-designate-scenario
|
||||
- neutron-tempest-plugin-designate-scenario-ussuri
|
||||
gate:
|
||||
queue: designate
|
||||
experimental:
|
||||
|
|
|
@ -2816,9 +2816,13 @@ class Service(service.RPCService):
|
|||
target = {'tenant_id': context.project_id}
|
||||
policy.check('find_zone_imports', context, target)
|
||||
|
||||
if not criterion:
|
||||
criterion = {
|
||||
'task_type': 'IMPORT'
|
||||
}
|
||||
else:
|
||||
criterion['task_type'] = 'IMPORT'
|
||||
|
||||
return self.storage.find_zone_imports(context, criterion, marker,
|
||||
limit, sort_key, sort_dir)
|
||||
|
||||
|
@ -2885,9 +2889,13 @@ class Service(service.RPCService):
|
|||
target = {'tenant_id': context.project_id}
|
||||
policy.check('find_zone_exports', context, target)
|
||||
|
||||
if not criterion:
|
||||
criterion = {
|
||||
'task_type': 'EXPORT'
|
||||
}
|
||||
else:
|
||||
criterion['task_type'] = 'EXPORT'
|
||||
|
||||
return self.storage.find_zone_exports(context, criterion, marker,
|
||||
limit, sort_key, sort_dir)
|
||||
|
||||
|
|
Loading…
Reference in New Issue