From e3b416de50d826b83d51ec19ca16d5cd0461ba81 Mon Sep 17 00:00:00 2001 From: Takashi Kajinami Date: Mon, 13 Jul 2020 13:57:29 +0900 Subject: [PATCH] Cleanup deprecated domain_id parameters Change-Id: I24a43d5dbfc98c3b663b6014658680ccf1b24e13 --- manifests/designate.pp | 29 ----------- manifests/server/notifications.pp | 50 ------------------- ...ecated-id-parameters-8ae1adebf972b291.yaml | 11 ++++ spec/classes/neutron_designate_spec.rb | 4 -- .../neutron_server_notifications_spec.rb | 14 ++---- 5 files changed, 15 insertions(+), 93 deletions(-) create mode 100644 releasenotes/notes/cleanup-deperecated-id-parameters-8ae1adebf972b291.yaml diff --git a/manifests/designate.pp b/manifests/designate.pp index 5fed1ec93..8e62b29c6 100644 --- a/manifests/designate.pp +++ b/manifests/designate.pp @@ -53,16 +53,6 @@ # [*ptr_zone_email*] # (optional) The email address to be used when creating PTR zones. # -# DEPRECATED PARAMETERS -# -# [*project_domain_id*] -# (optional) Nova project's domain ID -# Defaults to undef -# -# [*user_domain_id*] -# (optional) User's domain ID for connection to designate in admin context -# Defaults to undef -# class neutron::designate ( $password, $url, @@ -77,9 +67,6 @@ class neutron::designate ( $ipv4_ptr_zone_prefix_size = $::os_service_default, $ipv6_ptr_zone_prefix_size = $::os_service_default, $ptr_zone_email = $::os_service_default, - # DEPRECATED PARAMETERS - $project_domain_id = undef, - $user_domain_id = undef, ) { include neutron::deps include neutron::params @@ -100,20 +87,4 @@ class neutron::designate ( 'designate/ipv6_ptr_zone_prefix_size': value => $ipv6_ptr_zone_prefix_size; 'designate/ptr_zone_email': value => $ptr_zone_email; } - - if $project_domain_id != undef { - warning('project_domain_id is deprecated and will be removed in a future release. \ -Use project_domain_name instead') - neutron_config { - 'designate/project_domain_id': value => $project_domain_id; - } - } - - if $user_domain_id != undef { - warning('user_domain_id is deprecated and will be removed in a future release. \ -Use user_domain_name instead') - neutron_config { - 'designate/user_domain_id': value => $user_domain_id; - } - } } diff --git a/manifests/server/notifications.pp b/manifests/server/notifications.pp index c953605b4..18a1c863d 100644 --- a/manifests/server/notifications.pp +++ b/manifests/server/notifications.pp @@ -74,25 +74,6 @@ # (optional) Number of novaclient/ironicclient retries on failed http calls. # Defaults to $::os_service_default # -# DEPRECATED PARAMETERS -# -# [*tenant_id*] -# (optional) The UUID of the admin nova tenant. If provided this takes -# precedence over tenant_name. -# Defaults to undef -# -# [*tenant_name*] -# (optional) The name of the admin nova tenant -# Defaults to undef -# -# [*project_domain_id*] -# (optional) Nova project's domain ID -# Defaults to undef -# -# [*user_domain_id*] -# (optional) User's domain ID for connection to nova in admin context -# Defaults to undef -# class neutron::server::notifications ( $password, $notify_nova_on_port_status_changes = true, @@ -107,25 +88,10 @@ class neutron::server::notifications ( $region_name = $::os_service_default, $endpoint_type = $::os_service_default, $http_retries = $::os_service_default, - # DEPRECATED PARAMETERS - $tenant_id = undef, - $tenant_name = undef, - $project_domain_id = undef, - $user_domain_id = undef, ) { include neutron::deps - if $tenant_id != undef { - warning('neutron::server::notifications::tenant_id is deprecated and \ -has no effect. Use neutron::server::notifications::project_name instead') - } - - if $tenant_name != undef { - warning('neutron::server::notifications::tenant_name is deprecated and \ -has no effect. Use neutron::server::notifications::project_name instead') - } - neutron_config { 'nova/auth_url': value => $auth_url; 'nova/username': value => $username; @@ -138,22 +104,6 @@ has no effect. Use neutron::server::notifications::project_name instead') 'nova/auth_type': value => $auth_type; } - if $project_domain_id != undef { - warning('project_domain_id is deprecated and will be removed in a future release. \ -Use project_domain_name instead') - neutron_config { - 'nova/project_domain_id': value => $project_domain_id; - } - } - - if $user_domain_id != undef { - warning('user_domain_id is deprecated and will be removed in a future release. \ -Use user_domain_name instead') - neutron_config { - 'nova/user_domain_id': value => $user_domain_id; - } - } - neutron_config { 'DEFAULT/notify_nova_on_port_status_changes': value => $notify_nova_on_port_status_changes; 'DEFAULT/notify_nova_on_port_data_changes': value => $notify_nova_on_port_data_changes; diff --git a/releasenotes/notes/cleanup-deperecated-id-parameters-8ae1adebf972b291.yaml b/releasenotes/notes/cleanup-deperecated-id-parameters-8ae1adebf972b291.yaml new file mode 100644 index 000000000..3f3925f15 --- /dev/null +++ b/releasenotes/notes/cleanup-deperecated-id-parameters-8ae1adebf972b291.yaml @@ -0,0 +1,11 @@ +--- +upgrade: + - | + The following deprecated parameters has been removed + + - ``neutron::server::notifications::project_domain_id`` + - ``neutron::server::notifications::user_domain_id`` + - ``neutron::server::notifications::tenant_id`` + - ``neutron::server::notifications::tenant_name`` + - ``neutron::designate::project_domain_id`` + - ``neutron::designate::user_domain_id`` diff --git a/spec/classes/neutron_designate_spec.rb b/spec/classes/neutron_designate_spec.rb index f5cb3c67e..9e726720a 100644 --- a/spec/classes/neutron_designate_spec.rb +++ b/spec/classes/neutron_designate_spec.rb @@ -29,9 +29,7 @@ describe 'neutron::designate' do :username => 'user', :project_id => 'id1', :project_name => 'proj', - :project_domain_id => 'domain1', :project_domain_name => 'Domain1', - :user_domain_id => 'domain2', :user_domain_name => 'Domain2', :auth_url => 'http://auth/', :allow_reverse_dns_lookup => false, @@ -49,9 +47,7 @@ describe 'neutron::designate' do should contain_neutron_config('designate/auth_type').with_value('token') should contain_neutron_config('designate/project_id').with_value('id1') should contain_neutron_config('designate/project_name').with_value('proj') - should contain_neutron_config('designate/project_domain_id').with_value('domain1') should contain_neutron_config('designate/project_domain_name').with_value('Domain1') - should contain_neutron_config('designate/user_domain_id').with_value('domain2') should contain_neutron_config('designate/user_domain_name').with_value('Domain2') should contain_neutron_config('designate/auth_url').with_value('http://auth/') should contain_neutron_config('designate/allow_reverse_dns_lookup').with_value(false) diff --git a/spec/classes/neutron_server_notifications_spec.rb b/spec/classes/neutron_server_notifications_spec.rb index 50dced62e..6e0095b10 100644 --- a/spec/classes/neutron_server_notifications_spec.rb +++ b/spec/classes/neutron_server_notifications_spec.rb @@ -41,9 +41,7 @@ describe 'neutron::server::notifications' do should contain_neutron_config('nova/password').with_value('secrete') should contain_neutron_config('nova/password').with_secret( true ) should contain_neutron_config('nova/region_name').with_value('') - should_not contain_neutron_config('nova/project_domain_id') should contain_neutron_config('nova/project_domain_name').with_value('Default') - should_not contain_neutron_config('nova/user_domain_id') should contain_neutron_config('nova/user_domain_name').with_value('Default') should contain_neutron_config('nova/endpoint_type').with_value('') should contain_neutron_config('DEFAULT/http_retries').with_value('') @@ -59,10 +57,8 @@ describe 'neutron::server::notifications' do :auth_type => 'password', :username => 'joe', :region_name => 'MyRegion', - :project_domain_id => 'default_1', - :project_domain_name => 'Default_2', - :user_domain_id => 'default_3', - :user_domain_name => 'Default_4', + :project_domain_name => 'Default_1', + :user_domain_name => 'Default_2', :endpoint_type => 'internal', :http_retries => 3, ) @@ -78,10 +74,8 @@ describe 'neutron::server::notifications' do should contain_neutron_config('nova/password').with_value('secrete') should contain_neutron_config('nova/password').with_secret( true ) should contain_neutron_config('nova/region_name').with_value('MyRegion') - should contain_neutron_config('nova/project_domain_id').with_value('default_1') - should contain_neutron_config('nova/project_domain_name').with_value('Default_2') - should contain_neutron_config('nova/user_domain_id').with_value('default_3') - should contain_neutron_config('nova/user_domain_name').with_value('Default_4') + should contain_neutron_config('nova/project_domain_name').with_value('Default_1') + should contain_neutron_config('nova/user_domain_name').with_value('Default_2') should contain_neutron_config('nova/endpoint_type').with_value('internal') should contain_neutron_config('DEFAULT/http_retries').with_value(3) end