Bump default pagesize
Bumping default pagesize to 200. With the previous default value of 20 glanceclient was doing lots of extra requests and schema validations. Based on my tests no performance improvement was seen over the pagesize of 200. Change-Id: I6d740ca3a9b32bf5d064d3ea74273bb619b32ad4 Closes-Bug: #1987834
This commit is contained in:
parent
75218d289e
commit
219568c2a4
|
@ -711,7 +711,7 @@ class ShellTestWithNoOSImageURLPublic(ShellTestWithKeystoneV3Auth):
|
|||
glance_shell = openstack_shell.OpenStackImagesShell()
|
||||
glance_shell.main(args.split())
|
||||
self.assertEqual(self.requests.request_history[2].url,
|
||||
self.image_url + "v2/images?limit=20&"
|
||||
self.image_url + "v2/images?limit=200&"
|
||||
"sort_key=name&sort_dir=asc")
|
||||
|
||||
|
||||
|
|
|
@ -35,7 +35,7 @@ class ClientTestRequests(testutils.TestCase):
|
|||
self.requests = self.useFixture(rm_fixture.Fixture())
|
||||
self.requests.get('http://example.com/v2/schemas/image',
|
||||
json=schema_fixture)
|
||||
self.requests.get('http://example.com/v2/images?limit=20',
|
||||
self.requests.get('http://example.com/v2/images?limit=200',
|
||||
json=image_list_fixture)
|
||||
gc = client.Client(2.2, "http://example.com/v2.1")
|
||||
images = gc.images.list()
|
||||
|
|
|
@ -24,7 +24,7 @@ from glanceclient.common import utils
|
|||
from glanceclient import exc
|
||||
from glanceclient.v2 import schemas
|
||||
|
||||
DEFAULT_PAGE_SIZE = 20
|
||||
DEFAULT_PAGE_SIZE = 200
|
||||
|
||||
SORT_DIR_VALUES = ('asc', 'desc')
|
||||
SORT_KEY_VALUES = ('name', 'status', 'container_format', 'disk_format',
|
||||
|
|
Loading…
Reference in New Issue