Add processing delay param for metricd
Closes-bug: #1722788 Change-Id: I6f2d6835967a21e266243b66e36ed2690350d819
This commit is contained in:
parent
56c9fca516
commit
3ae8cb8c36
@ -19,16 +19,21 @@
|
||||
# cleaning of expired data.
|
||||
# Defaults to $::os_service_default
|
||||
#
|
||||
# [*metric_processing_delay*]
|
||||
# (optional) Delay between processng metrics
|
||||
# Defaults to $::os_service_default.
|
||||
#
|
||||
# [*manage_service*]
|
||||
# (optional) Whether the service should be managed by Puppet.
|
||||
# Defaults to true.
|
||||
#
|
||||
class gnocchi::metricd (
|
||||
$manage_service = true,
|
||||
$enabled = true,
|
||||
$workers = $::os_workers,
|
||||
$cleanup_delay = $::os_service_default,
|
||||
$package_ensure = 'present',
|
||||
$manage_service = true,
|
||||
$enabled = true,
|
||||
$workers = $::os_workers,
|
||||
$metric_processing_delay = $::os_service_default,
|
||||
$cleanup_delay = $::os_service_default,
|
||||
$package_ensure = 'present',
|
||||
) inherits gnocchi::params {
|
||||
|
||||
include ::gnocchi::deps
|
||||
@ -36,6 +41,7 @@ class gnocchi::metricd (
|
||||
gnocchi_config {
|
||||
'metricd/workers': value => $workers;
|
||||
'metricd/metric_cleanup_delay': value => $cleanup_delay;
|
||||
'metricd/metric_processing_delay': value => $metric_processing_delay;
|
||||
}
|
||||
|
||||
package { 'gnocchi-metricd':
|
||||
|
@ -0,0 +1,4 @@
|
||||
---
|
||||
fixes:
|
||||
- |
|
||||
Expose metricd processing delay to be set in gnocchi config metricd section.
|
@ -66,6 +66,16 @@ describe 'gnocchi::metricd' do
|
||||
end
|
||||
end
|
||||
|
||||
context 'with metric delay set' do
|
||||
before do
|
||||
params.merge!({
|
||||
:metric_processing_delay => 15 })
|
||||
end
|
||||
it 'configures gnocchi metricd processing delay value' do
|
||||
is_expected.to contain_gnocchi_config('metricd/metric_processing_delay').with_value('15')
|
||||
end
|
||||
end
|
||||
|
||||
context 'with cleanup_delay set' do
|
||||
before do
|
||||
params.merge!({
|
||||
|
Loading…
Reference in New Issue
Block a user