Add metric_processing_delay param
Expose this param to tweak the delay between processing
metrics in gnocchi.
Change-Id: I5de5283d1b14e0bba63d6d9a440611914ba86ca4
(cherry picked from commit 315733a00c
)
This commit is contained in:
parent
e45b5d3b2c
commit
57f338f8db
|
@ -24,10 +24,15 @@
|
|||
# (optional) The url to use for distributed group membership coordination.
|
||||
# Defaults to $::os_service_default.
|
||||
#
|
||||
# [*metric_processing_delay*]
|
||||
# (optional) Delay between processng metrics
|
||||
# Defaults to $::os_service_default.
|
||||
#
|
||||
|
||||
class gnocchi::storage(
|
||||
$package_ensure = 'present',
|
||||
$coordination_url = $::os_service_default,
|
||||
$package_ensure = 'present',
|
||||
$coordination_url = $::os_service_default,
|
||||
$metric_processing_delay = $::os_service_default,
|
||||
) inherits gnocchi::params {
|
||||
|
||||
package { 'gnocchi-carbonara':
|
||||
|
@ -37,7 +42,8 @@ class gnocchi::storage(
|
|||
}
|
||||
|
||||
gnocchi_config {
|
||||
'storage/coordination_url' : value => $coordination_url;
|
||||
'storage/coordination_url' : value => $coordination_url;
|
||||
'storage/metric_processing_delay' : value => $metric_processing_delay;
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -0,0 +1,3 @@
|
|||
---
|
||||
fixes:
|
||||
- Expose metric processing delay param.
|
|
@ -20,11 +20,15 @@ describe 'gnocchi::storage' do
|
|||
|
||||
context 'with coordination' do
|
||||
before do
|
||||
params.merge!({ :coordination_url => 'redis://localhost:6379' })
|
||||
params.merge!({
|
||||
:coordination_url => 'redis://localhost:6379',
|
||||
:metric_processing_delay => 30,
|
||||
})
|
||||
end
|
||||
|
||||
it 'configures backend_url' do
|
||||
is_expected.to contain_gnocchi_config('storage/coordination_url').with_value('redis://localhost:6379')
|
||||
is_expected.to contain_gnocchi_config('storage/metric_processing_delay').with_value(30)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue