Deprecate time_to_live options
These options no longer exists since 3 cycles. This change deprecated them. Change-Id: I2ddf06368e47258ebae0769ce94485c2f1971d87
This commit is contained in:
parent
da9e708518
commit
d54585f517
@ -9,16 +9,6 @@
|
||||
# (Optional) Timeout seconds for HTTP requests.
|
||||
# Defaults to 600.
|
||||
#
|
||||
# [*event_time_to_live*]
|
||||
# (Optional) Number of seconds that events are kept in the database for
|
||||
# (<= 0 means forever)
|
||||
# Defaults to -1.
|
||||
#
|
||||
# [*metering_time_to_live*]
|
||||
# (Optional) Number of seconds that samples are kept in the database for
|
||||
# (<= 0 means forever)
|
||||
# Defaults to -1.
|
||||
#
|
||||
# [*telemetry_secret*]
|
||||
# (Required) Secret key for signing messages.
|
||||
#
|
||||
@ -228,10 +218,20 @@
|
||||
# IP address.
|
||||
# Defaults to $::os_service_default.
|
||||
#
|
||||
# ### DEPRECATED PARAMETERS
|
||||
#
|
||||
# [*event_time_to_live*]
|
||||
# (Optional) Number of seconds that events are kept in the database for
|
||||
# (<= 0 means forever)
|
||||
# Defaults to undef.
|
||||
#
|
||||
# [*metering_time_to_live*]
|
||||
# (Optional) Number of seconds that samples are kept in the database for
|
||||
# (<= 0 means forever)
|
||||
# Defaults to undef.
|
||||
#
|
||||
class ceilometer(
|
||||
$http_timeout = '600',
|
||||
$event_time_to_live = '-1',
|
||||
$metering_time_to_live = '-1',
|
||||
$telemetry_secret = false,
|
||||
$notification_topics = ['notifications'],
|
||||
$notification_driver = $::os_service_default,
|
||||
@ -279,8 +279,20 @@ class ceilometer(
|
||||
$snmpd_readonly_user_password = $::os_service_default,
|
||||
$purge_config = false,
|
||||
$host = $::os_service_default,
|
||||
## DEPRECATED PARAMETERS
|
||||
$event_time_to_live = undef,
|
||||
$metering_time_to_live = undef,
|
||||
) {
|
||||
|
||||
if $metering_time_to_live {
|
||||
warning('The metering_time_to_live parameter is deprecated, ignored and will be
|
||||
removed in the futrure.')
|
||||
}
|
||||
if $event_time_to_live {
|
||||
warning('The event_time_to_live parameter is deprecated, ignored and will be
|
||||
removed in the futrure.')
|
||||
}
|
||||
|
||||
include ::ceilometer::deps
|
||||
include ::ceilometer::logging
|
||||
include ::ceilometer::params
|
||||
@ -349,8 +361,6 @@ class ceilometer(
|
||||
'DEFAULT/http_timeout' : value => $http_timeout;
|
||||
'DEFAULT/host' : value => $host;
|
||||
'publisher/telemetry_secret' : value => $telemetry_secret, secret => true;
|
||||
'database/event_time_to_live' : value => $event_time_to_live;
|
||||
'database/metering_time_to_live' : value => $metering_time_to_live;
|
||||
'hardware/readonly_user_name' : value => $snmpd_readonly_username;
|
||||
'hardware/readonly_user_password' : value => $snmpd_readonly_user_password;
|
||||
}
|
||||
|
@ -0,0 +1,5 @@
|
||||
---
|
||||
deprecations:
|
||||
- |
|
||||
event_time_to_live and metering_time_to_live are deprecated, since they no
|
||||
longuer work since 3 releases.
|
@ -5,8 +5,6 @@ describe 'ceilometer' do
|
||||
let :params do
|
||||
{
|
||||
:http_timeout => '600',
|
||||
:event_time_to_live => '604800',
|
||||
:metering_time_to_live => '604800',
|
||||
:telemetry_secret => 'metering-s3cr3t',
|
||||
:package_ensure => 'present',
|
||||
:debug => 'False',
|
||||
@ -25,11 +23,6 @@ describe 'ceilometer' do
|
||||
|
||||
shared_examples_for 'ceilometer' do
|
||||
|
||||
it 'configures time to live for events and meters' do
|
||||
is_expected.to contain_ceilometer_config('database/event_time_to_live').with_value( params[:event_time_to_live] )
|
||||
is_expected.to contain_ceilometer_config('database/metering_time_to_live').with_value( params[:metering_time_to_live] )
|
||||
end
|
||||
|
||||
it 'configures timeout for HTTP requests' do
|
||||
is_expected.to contain_ceilometer_config('DEFAULT/http_timeout').with_value(params[:http_timeout])
|
||||
end
|
||||
|
Loading…
x
Reference in New Issue
Block a user