nova/nova/tests/functional/db
Matt Riedemann b00b2fe9be Raise MarkerNotFound if BuildRequestList.get_by_filters doesn't find marker
For some reason, probably because build requests are meant to be short lived
and we don't get a lot of bugs about paging misbehavior, when paging instances
with a marker, we didn't raise MarkerNotFound if we didn't find the marker in
the list of build requests. Doing so would match what we do when paging over
cells and listing instances using a marker. Once we find the marker, be that
in build_requests, or one of the cells, we need to set the marker to None to
stop looking for it elsewhere if we have more space to fill our limit.

For example, see change I8a957bebfcecd6ac712103c346e028d80f1ecd7c.

This patch fixes the issue by raising MarkerNotFound from BuildRequestList
get_by_filters if there is a marker and we didn't find a build request for
it. The compute API get_all() method handles that as normal and continues
looking for the marker in one of the cells.

Conflicts:
      nova/tests/unit/compute/test_compute_api.py

NOTE(mriedem): The conflicts are due to not having
bb7c6ebb56 in Ocata.

Change-Id: I1aa3ca6cc70cef65d24dec1e7db9491c9b73f7ab
Closes-Bug: #1737856
(cherry picked from commit 1706e39891)
(cherry picked from commit 344029b94a)
2018-01-03 12:48:04 -05:00
..
api Make request_spec.spec MediumText 2017-12-18 19:43:54 +00:00
__init__.py Add second migrate_repo for cells v2 database migrations 2015-03-03 15:41:40 -05:00
test_aggregate.py Handle unicode when dealing with duplicate aggregate errors during migration 2016-12-30 12:56:20 -05:00
test_aggregate_model.py Add aggregates tables to the API db. 2016-06-01 12:00:56 -05:00
test_archive.py Archive instance-related rows when the parent instance is deleted 2016-09-27 12:08:21 -07:00
test_build_request.py Raise MarkerNotFound if BuildRequestList.get_by_filters doesn't find marker 2018-01-03 12:48:04 -05:00
test_cell_mapping.py Fix database poison warnings, part 25 2016-11-10 13:57:13 +00:00
test_compute_node.py Add ComputeNodeList.get_all_by_uuids method 2017-01-20 09:47:43 +01:00
test_connection_switch.py Setup CellsV2 environment in base test 2016-12-09 10:30:43 -08:00
test_flavor.py Handle unicode when dealing with duplicate flavors during online migrations 2016-12-30 12:27:48 -05:00
test_flavor_model.py Creates flavor* tables in API database 2016-02-24 16:12:07 -06:00
test_host_mapping.py Create HostMappingList object 2017-01-16 12:04:21 -05:00
test_instance_group.py Add online migration to move instance groups to API database 2016-08-22 03:50:24 -07:00
test_instance_group_model.py Add instance groups tables to the API database 2016-06-23 00:28:50 +00:00
test_instance_mapping.py Add InstanceMappingList.get_by_cell_id 2017-01-16 12:04:30 -05:00
test_keypair.py Cleanup some redundant USES_DB_SELF usage 2016-09-26 15:47:16 -04:00
test_quota_model.py Add quota related tables to the api database. 2016-10-12 07:40:00 +00:00
test_request_spec.py Use instance.project_id when creating request specs for old instances 2017-12-20 13:02:41 -05:00
test_resource_class_cache.py placement: Perform build list of standard classes once 2016-12-05 16:13:49 +00:00
test_resource_provider.py placement: remove existing allocs when set allocs 2017-08-02 18:10:07 -04:00