From 97682cfa99b013d149f232e9075acd9f3f45140a Mon Sep 17 00:00:00 2001 From: Takashi Kajinami Date: Fri, 5 Aug 2022 01:11:13 +0900 Subject: [PATCH] Remove deprecated aodh::evaluator::coordination_url ... because it was deprecated during Xena cycle[1] in favor of the new aodh::coordination class. [1] 16091c8dd6f97f55fb7875e7843f3de7017a99ce Change-Id: I0e11987c7d121b2fb639274ed60181c56ce4f6d1 --- manifests/coordination.pp | 8 +------- manifests/evaluator.pp | 13 ------------- .../cleanup-coordination-ca6319f55bf4fdb2.yaml | 4 ++++ spec/classes/aodh_evaluator_spec.rb | 10 ---------- 4 files changed, 5 insertions(+), 30 deletions(-) create mode 100644 releasenotes/notes/cleanup-coordination-ca6319f55bf4fdb2.yaml diff --git a/manifests/coordination.pp b/manifests/coordination.pp index ca8bc442..629249be 100644 --- a/manifests/coordination.pp +++ b/manifests/coordination.pp @@ -32,14 +32,8 @@ class aodh::coordination ( include aodh::deps - if defined('$::aodh::evaluator::coordination_url') { - $backend_url_real = pick($::aodh::evaluator::coordination_url, $backend_url) - } else { - $backend_url_real = $backend_url - } - oslo::coordination{ 'aodh_config': - backend_url => $backend_url_real + backend_url => $backend_url } aodh_config { diff --git a/manifests/evaluator.pp b/manifests/evaluator.pp index 905021ff..42ad0807 100644 --- a/manifests/evaluator.pp +++ b/manifests/evaluator.pp @@ -30,12 +30,6 @@ # compensate the reporting/ingestion lag. # Defaults to $::os_service_default. # -# DEPRECATED PARAMETERS -# -# [*coordination_url*] -# (optional) The url to use for distributed group membership coordination. -# Defaults to undef. -# class aodh::evaluator ( $manage_service = true, $enabled = true, @@ -44,18 +38,11 @@ class aodh::evaluator ( $evaluation_interval = $::os_service_default, $event_alarm_cache_ttl = $::os_service_default, $additional_ingestion_lag = $::os_service_default, - # DEPRECATED PARAMETERS - $coordination_url = undef, ) { include aodh::deps include aodh::params - if $coordination_url != undef { - warning('The coordination_url parameter is deprecated. Use the aodh::coordination class instead') - include aodh::coordination - } - aodh_config { 'evaluator/evaluation_interval': value => $evaluation_interval; 'DEFAULT/event_alarm_cache_ttl': value => $event_alarm_cache_ttl; diff --git a/releasenotes/notes/cleanup-coordination-ca6319f55bf4fdb2.yaml b/releasenotes/notes/cleanup-coordination-ca6319f55bf4fdb2.yaml new file mode 100644 index 00000000..3e5c8e8a --- /dev/null +++ b/releasenotes/notes/cleanup-coordination-ca6319f55bf4fdb2.yaml @@ -0,0 +1,4 @@ +--- +upgrade: + - | + The ``aodh::evaluator::coordination_url`` parameter has been removed. diff --git a/spec/classes/aodh_evaluator_spec.rb b/spec/classes/aodh_evaluator_spec.rb index 5b8f8b4c..dccaf63e 100644 --- a/spec/classes/aodh_evaluator_spec.rb +++ b/spec/classes/aodh_evaluator_spec.rb @@ -42,16 +42,6 @@ describe 'aodh::evaluator' do end end - context 'with deprecated coordination_url' do - before do - params.merge!({ :coordination_url => 'redis://localhost:6379' }) - end - it 'configures coordination and workers' do - is_expected.to contain_aodh_config('coordination/backend_url').with_value('redis://localhost:6379') - is_expected.to contain_aodh_config('evaluator/workers').with_value(4) - end - end - context 'when enabled' do it { is_expected.to contain_class('aodh::params') }