Merge "Add osapi_max_limit parameter"
This commit is contained in:
commit
7007ed22b7
|
@ -136,6 +136,11 @@
|
|||
# (Optional) Base URL that will be presented to users in links to the OpenStack Volume API.
|
||||
# Defaults to $::os_service_default
|
||||
#
|
||||
# [*osapi_max_limit*]
|
||||
# (Optional) The maximum number of items that a collection resource
|
||||
# returns in a single response (integer value)
|
||||
# Defaults to $::os_service_default
|
||||
#
|
||||
class cinder::api (
|
||||
$keystone_password,
|
||||
$keystone_enabled = true,
|
||||
|
@ -165,6 +170,7 @@ class cinder::api (
|
|||
$sync_db = true,
|
||||
$public_endpoint = $::os_service_default,
|
||||
$osapi_volume_base_url = $::os_service_default,
|
||||
$osapi_max_limit = $::os_service_default,
|
||||
# DEPRECATED PARAMETERS
|
||||
$validation_options = {},
|
||||
) {
|
||||
|
@ -217,6 +223,7 @@ class cinder::api (
|
|||
'DEFAULT/default_volume_type': value => $default_volume_type;
|
||||
'DEFAULT/public_endpoint': value => $public_endpoint;
|
||||
'DEFAULT/osapi_volume_base_URL': value => $osapi_volume_base_url;
|
||||
'DEFAULT/osapi_max_limit': value => $osapi_max_limit;
|
||||
}
|
||||
|
||||
cinder_config {
|
||||
|
|
|
@ -43,6 +43,9 @@ describe 'cinder::api' do
|
|||
is_expected.to contain_cinder_config('DEFAULT/osapi_volume_base_URL').with(
|
||||
:value => '<SERVICE DEFAULT>'
|
||||
)
|
||||
is_expected.to contain_cinder_config('DEFAULT/osapi_max_limit').with(
|
||||
:value => '<SERVICE DEFAULT>'
|
||||
)
|
||||
is_expected.to contain_cinder_config('DEFAULT/os_region_name').with(
|
||||
:value => '<SERVICE DEFAULT>'
|
||||
)
|
||||
|
@ -289,6 +292,17 @@ describe 'cinder::api' do
|
|||
is_expected.to contain_cinder_config('keystone_authtoken/auth_uri').with_value("https://localhost:5000/")
|
||||
end
|
||||
end
|
||||
|
||||
describe 'with a custom osapi_max_limit' do
|
||||
let :params do
|
||||
req_params.merge({'osapi_max_limit' => '10000'})
|
||||
end
|
||||
it 'should configure the osapi_max_limit to 10000' do
|
||||
is_expected.to contain_cinder_config('DEFAULT/osapi_max_limit').with(
|
||||
:value => '10000'
|
||||
)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
on_supported_os({
|
||||
|
|
Loading…
Reference in New Issue