Drop time_to_live parameter
time_to_live was deprecated in liberty, let's drop it so we don't have the warning anymore. Change-Id: If36dc4ec2435aa8229b4efa6123fff9bdf668b37
This commit is contained in:
parent
ee93d53421
commit
782eeda90b
@ -82,10 +82,8 @@ node default {
|
||||
class { '::ceilometer::alarm::evaluator':
|
||||
}
|
||||
|
||||
# Purge 1 month old meters
|
||||
class { '::ceilometer::expirer':
|
||||
time_to_live => '2592000'
|
||||
}
|
||||
# Purge old meters
|
||||
class { '::ceilometer::expirer': }
|
||||
|
||||
# Install notification agent
|
||||
class { '::ceilometer::agent::notification':
|
||||
|
@ -40,10 +40,6 @@
|
||||
# [*weekday*]
|
||||
# (optional) Defaults to '*'.
|
||||
#
|
||||
# [*time_to_live*]
|
||||
# (optional) DEPRECATED. Number of seconds that samples are kept in the database.
|
||||
# Should be a valid integer
|
||||
# Defaults to '-1' to disable TTL and keep forever the datas.
|
||||
|
||||
class ceilometer::expirer (
|
||||
$enable_cron = True,
|
||||
@ -52,20 +48,12 @@ class ceilometer::expirer (
|
||||
$monthday = '*',
|
||||
$month = '*',
|
||||
$weekday = '*',
|
||||
# Deprecated parameters
|
||||
$time_to_live = '-1',
|
||||
) {
|
||||
|
||||
include ::ceilometer::params
|
||||
|
||||
Package<| title == 'ceilometer-common' |> -> Class['ceilometer::expirer']
|
||||
|
||||
warning('Parameter "time_to_live" is deprecated and will be removed in next release. Use metering_time_to_live in "ceilometer" class instead.')
|
||||
|
||||
ceilometer_config {
|
||||
'database/time_to_live': value => $time_to_live;
|
||||
}
|
||||
|
||||
if $enable_cron {
|
||||
cron { 'ceilometer-expirer':
|
||||
command => $ceilometer::params::expirer_command,
|
||||
|
@ -27,7 +27,7 @@ describe 'ceilometer::expirer' do
|
||||
end
|
||||
|
||||
let :params do
|
||||
{ :time_to_live => '-1' }
|
||||
{}
|
||||
end
|
||||
|
||||
shared_examples_for 'ceilometer-expirer' do
|
||||
@ -62,10 +62,6 @@ describe 'ceilometer::expirer' do
|
||||
it { is_expected.to_not contain_cron('ceilometer-expirer') }
|
||||
end
|
||||
|
||||
it 'configures database section in ceilometer.conf' do
|
||||
is_expected.to contain_ceilometer_config('database/time_to_live').with_value( params[:time_to_live] )
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
context 'on Debian platforms' do
|
||||
|
Loading…
Reference in New Issue
Block a user