diff --git a/manifests/cache.pp b/manifests/cache.pp index 6a9030c..7d3ac96 100644 --- a/manifests/cache.pp +++ b/manifests/cache.pp @@ -135,6 +135,11 @@ # client connection. (integer value) # Defaults to $facts['os_service_default'] # +# [*memcache_pool_flush_on_reconnect*] +# (Optional) Global toggle if memcache will be flushed on reconnect. +# (oslo_cache.memcache_pool backend only) +# Defaults to $facts['os_service_default'] +# # [*tls_enabled*] # (Optional) Global toggle for TLS usage when communicating with # the caching servers. @@ -225,6 +230,7 @@ define oslo::cache( $memcache_pool_maxsize = $facts['os_service_default'], $memcache_pool_unused_timeout = $facts['os_service_default'], $memcache_pool_connection_get_timeout = $facts['os_service_default'], + $memcache_pool_flush_on_reconnect = $facts['os_service_default'], $tls_enabled = $facts['os_service_default'], $tls_cafile = $facts['os_service_default'], $tls_certfile = $facts['os_service_default'], @@ -302,6 +308,7 @@ define oslo::cache( 'cache/memcache_pool_maxsize' => { value => $memcache_pool_maxsize }, 'cache/memcache_pool_unused_timeout' => { value => $memcache_pool_unused_timeout }, 'cache/memcache_pool_connection_get_timeout' => { value => $memcache_pool_connection_get_timeout }, + 'cache/memcache_pool_flush_on_reconnect' => { value => $memcache_pool_flush_on_reconnect }, 'cache/tls_enabled' => { value => $tls_enabled }, 'cache/tls_cafile' => { value => $tls_cafile }, 'cache/tls_certfile' => { value => $tls_certfile }, diff --git a/releasenotes/notes/cache-memcache_pool_flush_on_reconnect-ef097a16a54d9fac.yaml b/releasenotes/notes/cache-memcache_pool_flush_on_reconnect-ef097a16a54d9fac.yaml new file mode 100644 index 0000000..ab15505 --- /dev/null +++ b/releasenotes/notes/cache-memcache_pool_flush_on_reconnect-ef097a16a54d9fac.yaml @@ -0,0 +1,5 @@ +--- +features: + - | + The new ``oslo::cache::memcache_pool_flush_on_reconnect`` parameter has + been added. diff --git a/spec/defines/oslo_cache_spec.rb b/spec/defines/oslo_cache_spec.rb index 536538e..3200c59 100644 --- a/spec/defines/oslo_cache_spec.rb +++ b/spec/defines/oslo_cache_spec.rb @@ -25,6 +25,7 @@ describe 'oslo::cache' do is_expected.to contain_keystone_config('cache/memcache_pool_maxsize').with_value('') is_expected.to contain_keystone_config('cache/memcache_pool_unused_timeout').with_value('') is_expected.to contain_keystone_config('cache/memcache_pool_connection_get_timeout').with_value('') + is_expected.to contain_keystone_config('cache/memcache_pool_flush_on_reconnect').with_value('') is_expected.to contain_keystone_config('cache/tls_enabled').with_value('') is_expected.to contain_keystone_config('cache/tls_cafile').with_value('') is_expected.to contain_keystone_config('cache/tls_certfile').with_value('') @@ -59,6 +60,7 @@ describe 'oslo::cache' do :memcache_pool_maxsize => '10', :memcache_pool_unused_timeout => '60', :memcache_pool_connection_get_timeout => '10', + :memcache_pool_flush_on_reconnect => false, :tls_enabled => false, :tls_cafile => '/path/to/ssl/cafile', :tls_certfile => '/path/to/ssl/certfile', @@ -91,6 +93,7 @@ describe 'oslo::cache' do is_expected.to contain_keystone_config('cache/memcache_pool_maxsize').with_value('10') is_expected.to contain_keystone_config('cache/memcache_pool_unused_timeout').with_value('60') is_expected.to contain_keystone_config('cache/memcache_pool_connection_get_timeout').with_value('10') + is_expected.to contain_keystone_config('cache/memcache_pool_flush_on_reconnect').with_value(false) is_expected.to contain_keystone_config('cache/tls_enabled').with_value('false') is_expected.to contain_keystone_config('cache/tls_cafile').with_value('/path/to/ssl/cafile') is_expected.to contain_keystone_config('cache/tls_certfile').with_value('/path/to/ssl/certfile')