Allow to set Notification Driver to 'noop'

This patch does 2 things:
* Configure messagingv2 as default driver for Oslo Notifications sent on
  RPC.
* Allow users to choose between messagingv2 (default) and noop when we
  want to disable notifications (for example, when Telemetry is disabled).
* Deprecate KeystoneNotificationDriver in favor of NotificationDriver.

Change-Id: Ia547d7f4bfb51e7c45246b097b48fd86da231bd3
Related-Bug: #1701357
This commit is contained in:
Emilien Macchi 2017-07-07 11:35:28 -07:00
parent 322f2dbd4c
commit d5145167cb
18 changed files with 119 additions and 4 deletions

View File

@ -18,3 +18,6 @@ resource_registry:
OS::TripleO::Services::AodhNotifier: OS::Heat::None OS::TripleO::Services::AodhNotifier: OS::Heat::None
OS::TripleO::Services::AodhListener: OS::Heat::None OS::TripleO::Services::AodhListener: OS::Heat::None
OS::TripleO::Services::PankoApi: OS::Heat::None OS::TripleO::Services::PankoApi: OS::Heat::None
parameter_defaults:
NotificationDriver: 'noop'

View File

@ -13,7 +13,6 @@ parameter_defaults:
NeutronBigswitchRestproxyServerAuth: NeutronBigswitchRestproxyServerAuth:
NeutronMechanismDrivers: openvswitch,bsn_ml2 NeutronMechanismDrivers: openvswitch,bsn_ml2
NeutronServicePlugins: bsn_l3,bsn_service_plugin NeutronServicePlugins: bsn_l3,bsn_service_plugin
KeystoneNotificationDriver: messaging
# Optional: # Optional:
# NeutronBigswitchRestproxyAutoSyncOnFailure: # NeutronBigswitchRestproxyAutoSyncOnFailure:

View File

@ -64,6 +64,12 @@ parameters:
type: string type: string
default: 'regionOne' default: 'regionOne'
description: Keystone region for endpoint description: Keystone region for endpoint
NotificationDriver:
type: string
default: 'messagingv2'
description: Driver or drivers to handle sending notifications.
constraints:
- allowed_values: [ 'messagingv2', 'noop' ]
conditions: conditions:
service_debug_unset: {equals : [{get_param: AodhDebug}, '']} service_debug_unset: {equals : [{get_param: AodhDebug}, '']}
@ -91,6 +97,7 @@ outputs:
- {get_param: Debug } - {get_param: Debug }
- {get_param: AodhDebug } - {get_param: AodhDebug }
aodh::auth::auth_url: {get_param: [EndpointMap, KeystoneInternal, uri_no_suffix] } aodh::auth::auth_url: {get_param: [EndpointMap, KeystoneInternal, uri_no_suffix] }
aodh::notification_driver: {get_param: NotificationDriver}
aodh::rabbit_userid: {get_param: RabbitUserName} aodh::rabbit_userid: {get_param: RabbitUserName}
aodh::rabbit_password: {get_param: RabbitPassword} aodh::rabbit_password: {get_param: RabbitPassword}
aodh::rabbit_use_ssl: {get_param: RabbitClientUseSSL} aodh::rabbit_use_ssl: {get_param: RabbitClientUseSSL}

View File

@ -73,6 +73,12 @@ parameters:
e.g. { barbican-context_is_admin: { key: context_is_admin, value: 'role:admin' } } e.g. { barbican-context_is_admin: { key: context_is_admin, value: 'role:admin' } }
default: {} default: {}
type: json type: json
NotificationDriver:
type: string
default: 'messagingv2'
description: Driver or drivers to handle sending notifications.
constraints:
- allowed_values: [ 'messagingv2', 'noop' ]
resources: resources:
@ -109,6 +115,7 @@ outputs:
- service_debug_unset - service_debug_unset
- {get_param: Debug } - {get_param: Debug }
- {get_param: BarbicanDebug } - {get_param: BarbicanDebug }
barbican::api::notification_driver: {get_param: NotificationDriver}
barbican::api::rabbit_use_ssl: {get_param: RabbitClientUseSSL} barbican::api::rabbit_use_ssl: {get_param: RabbitClientUseSSL}
barbican::api::rabbit_userid: {get_param: RabbitUserName} barbican::api::rabbit_userid: {get_param: RabbitUserName}
barbican::api::rabbit_password: {get_param: RabbitPassword} barbican::api::rabbit_password: {get_param: RabbitPassword}

View File

@ -103,6 +103,12 @@ parameters:
description: The user password for SNMPd with readonly rights running on all Overcloud nodes description: The user password for SNMPd with readonly rights running on all Overcloud nodes
type: string type: string
hidden: true hidden: true
NotificationDriver:
type: string
default: 'messagingv2'
description: Driver or drivers to handle sending notifications.
constraints:
- allowed_values: [ 'messagingv2', 'noop' ]
conditions: conditions:
service_debug_unset: {equals : [{get_param: CeilometerDebug}, '']} service_debug_unset: {equals : [{get_param: CeilometerDebug}, '']}
@ -139,6 +145,7 @@ outputs:
ceilometer::dispatcher::gnocchi::filter_project: 'service' ceilometer::dispatcher::gnocchi::filter_project: 'service'
ceilometer::dispatcher::gnocchi::archive_policy: 'low' ceilometer::dispatcher::gnocchi::archive_policy: 'low'
ceilometer::dispatcher::gnocchi::resources_definition_file: 'gnocchi_resources.yaml' ceilometer::dispatcher::gnocchi::resources_definition_file: 'gnocchi_resources.yaml'
ceilometer::notification_driver: {get_param: NotificationDriver}
ceilometer::rabbit_userid: {get_param: RabbitUserName} ceilometer::rabbit_userid: {get_param: RabbitUserName}
ceilometer::rabbit_password: {get_param: RabbitPassword} ceilometer::rabbit_password: {get_param: RabbitPassword}
ceilometer::rabbit_use_ssl: {get_param: RabbitClientUseSSL} ceilometer::rabbit_use_ssl: {get_param: RabbitClientUseSSL}

View File

@ -60,6 +60,12 @@ parameters:
e.g. { cinder-context_is_admin: { key: context_is_admin, value: 'role:admin' } } e.g. { cinder-context_is_admin: { key: context_is_admin, value: 'role:admin' } }
default: {} default: {}
type: json type: json
NotificationDriver:
type: string
default: 'messagingv2'
description: Driver or drivers to handle sending notifications.
constraints:
- allowed_values: [ 'messagingv2', 'noop' ]
conditions: conditions:
cinder_workers_zero: {equals : [{get_param: CinderWorkers}, 0]} cinder_workers_zero: {equals : [{get_param: CinderWorkers}, 0]}
@ -105,6 +111,7 @@ outputs:
cinder::keystone::authtoken::user_domain_name: 'Default' cinder::keystone::authtoken::user_domain_name: 'Default'
cinder::keystone::authtoken::project_domain_name: 'Default' cinder::keystone::authtoken::project_domain_name: 'Default'
cinder::policy::policies: {get_param: CinderApiPolicies} cinder::policy::policies: {get_param: CinderApiPolicies}
cinder::ceilometer::notification_driver: {get_param: NotificationDriver}
cinder::api::enable_proxy_headers_parsing: true cinder::api::enable_proxy_headers_parsing: true
cinder::api::nova_catalog_info: 'compute:nova:internalURL' cinder::api::nova_catalog_info: 'compute:nova:internalURL'

View File

@ -65,6 +65,12 @@ parameters:
e.g. { congress-context_is_admin: { key: context_is_admin, value: 'role:admin' } } e.g. { congress-context_is_admin: { key: context_is_admin, value: 'role:admin' } }
default: {} default: {}
type: json type: json
NotificationDriver:
type: string
default: 'messagingv2'
description: Driver or drivers to handle sending notifications.
constraints:
- allowed_values: [ 'messagingv2', 'noop' ]
conditions: conditions:
service_debug_unset: {equals : [{get_param: CongressDebug}, '']} service_debug_unset: {equals : [{get_param: CongressDebug}, '']}
@ -92,6 +98,7 @@ outputs:
- {get_param: Debug } - {get_param: Debug }
- {get_param: CongressDebug } - {get_param: CongressDebug }
congress::rpc_backend: rabbit congress::rpc_backend: rabbit
congress::notification_driver: {get_param: NotificationDriver}
congress::rabbit_userid: {get_param: RabbitUserName} congress::rabbit_userid: {get_param: RabbitUserName}
congress::rabbit_password: {get_param: RabbitPassword} congress::rabbit_password: {get_param: RabbitPassword}
congress::rabbit_use_ssl: {get_param: RabbitClientUseSSL} congress::rabbit_use_ssl: {get_param: RabbitClientUseSSL}

View File

@ -128,6 +128,12 @@ parameters:
e.g. { glance-context_is_admin: { key: context_is_admin, value: 'role:admin' } } e.g. { glance-context_is_admin: { key: context_is_admin, value: 'role:admin' } }
default: {} default: {}
type: json type: json
NotificationDriver:
type: string
default: 'messagingv2'
description: Driver or drivers to handle sending notifications.
constraints:
- allowed_values: [ 'messagingv2', 'noop' ]
conditions: conditions:
use_tls_proxy: {equals : [{get_param: EnableInternalTLS}, true]} use_tls_proxy: {equals : [{get_param: EnableInternalTLS}, true]}
@ -237,7 +243,7 @@ outputs:
glance::notify::rabbitmq::rabbit_port: {get_param: RabbitClientPort} glance::notify::rabbitmq::rabbit_port: {get_param: RabbitClientPort}
glance::notify::rabbitmq::rabbit_password: {get_param: RabbitPassword} glance::notify::rabbitmq::rabbit_password: {get_param: RabbitPassword}
glance::notify::rabbitmq::rabbit_use_ssl: {get_param: RabbitClientUseSSL} glance::notify::rabbitmq::rabbit_use_ssl: {get_param: RabbitClientUseSSL}
glance::notify::rabbitmq::notification_driver: messagingv2 glance::notify::rabbitmq::notification_driver: {get_param: NotificationDriver}
tripleo::profile::base::glance::api::glance_nfs_enabled: {get_param: GlanceNfsEnabled} tripleo::profile::base::glance::api::glance_nfs_enabled: {get_param: GlanceNfsEnabled}
tripleo::glance::nfs_mount::share: {get_param: GlanceNfsShare} tripleo::glance::nfs_mount::share: {get_param: GlanceNfsShare}
tripleo::glance::nfs_mount::options: {get_param: GlanceNfsOptions} tripleo::glance::nfs_mount::options: {get_param: GlanceNfsOptions}

View File

@ -115,6 +115,12 @@ parameters:
default: 1048576 default: 1048576
description: Maximum raw byte size of the Heat API JSON request body. description: Maximum raw byte size of the Heat API JSON request body.
type: number type: number
NotificationDriver:
type: string
default: 'messagingv2'
description: Driver or drivers to handle sending notifications.
constraints:
- allowed_values: [ 'messagingv2', 'noop' ]
conditions: conditions:
service_debug_unset: {equals : [{get_param: HeatDebug}, '']} service_debug_unset: {equals : [{get_param: HeatDebug}, '']}
@ -125,6 +131,7 @@ outputs:
value: value:
service_name: heat_base service_name: heat_base
config_settings: config_settings:
heat::notification_driver: {get_param: NotificationDriver}
heat::rabbit_userid: {get_param: RabbitUserName} heat::rabbit_userid: {get_param: RabbitUserName}
heat::rabbit_password: {get_param: RabbitPassword} heat::rabbit_password: {get_param: RabbitPassword}
heat::rabbit_use_ssl: {get_param: RabbitClientUseSSL} heat::rabbit_use_ssl: {get_param: RabbitClientUseSSL}

View File

@ -203,6 +203,12 @@ parameters:
type: json type: json
default: {} default: {}
hidden: true hidden: true
NotificationDriver:
type: string
default: 'messagingv2'
description: Driver or drivers to handle sending notifications.
constraints:
- allowed_values: [ 'messagingv2', 'noop' ]
parameter_groups: parameter_groups:
- label: deprecated - label: deprecated
@ -214,6 +220,7 @@ parameter_groups:
parameters: parameters:
- KeystoneFernetKey0 - KeystoneFernetKey0
- KeystoneFernetKey1 - KeystoneFernetKey1
- KeystoneNotificationDriver
resources: resources:
@ -281,7 +288,7 @@ outputs:
keystone::rabbit_password: {get_param: RabbitPassword} keystone::rabbit_password: {get_param: RabbitPassword}
keystone::rabbit_use_ssl: {get_param: RabbitClientUseSSL} keystone::rabbit_use_ssl: {get_param: RabbitClientUseSSL}
keystone::rabbit_port: {get_param: RabbitClientPort} keystone::rabbit_port: {get_param: RabbitClientPort}
keystone::notification_driver: {get_param: KeystoneNotificationDriver} keystone::notification_driver: {get_param: NotificationDriver}
keystone::notification_format: {get_param: KeystoneNotificationFormat} keystone::notification_format: {get_param: KeystoneNotificationFormat}
keystone::roles::admin::email: {get_param: AdminEmail} keystone::roles::admin::email: {get_param: AdminEmail}
keystone::roles::admin::password: {get_param: AdminPassword} keystone::roles::admin::password: {get_param: AdminPassword}

View File

@ -56,6 +56,12 @@ parameters:
description: The password for the manila service account. description: The password for the manila service account.
type: string type: string
hidden: true hidden: true
NotificationDriver:
type: string
default: 'messagingv2'
description: Driver or drivers to handle sending notifications.
constraints:
- allowed_values: [ 'messagingv2', 'noop' ]
conditions: conditions:
service_debug_unset: {equals : [{get_param: ManilaDebug}, '']} service_debug_unset: {equals : [{get_param: ManilaDebug}, '']}
@ -66,6 +72,7 @@ outputs:
value: value:
service_name: manila_base service_name: manila_base
config_settings: config_settings:
manila::notification_driver: {get_param: NotificationDriver}
manila::rabbit_userid: {get_param: RabbitUserName} manila::rabbit_userid: {get_param: RabbitUserName}
manila::rabbit_password: {get_param: RabbitPassword} manila::rabbit_password: {get_param: RabbitPassword}
manila::rabbit_use_ssl: {get_param: RabbitClientUseSSL} manila::rabbit_use_ssl: {get_param: RabbitClientUseSSL}

View File

@ -61,6 +61,12 @@ parameters:
type: string type: string
default: 'regionOne' default: 'regionOne'
description: Keystone region for endpoint description: Keystone region for endpoint
NotificationDriver:
type: string
default: 'messagingv2'
description: Driver or drivers to handle sending notifications.
constraints:
- allowed_values: [ 'messagingv2', 'noop' ]
conditions: conditions:
service_debug_unset: {equals : [{get_param: MistralDebug}, '']} service_debug_unset: {equals : [{get_param: MistralDebug}, '']}
@ -81,6 +87,7 @@ outputs:
query: query:
read_default_file: /etc/my.cnf.d/tripleo.cnf read_default_file: /etc/my.cnf.d/tripleo.cnf
read_default_group: tripleo read_default_group: tripleo
mistral::notification_driver: {get_param: NotificationDriver}
mistral::rabbit_userid: {get_param: RabbitUserName} mistral::rabbit_userid: {get_param: RabbitUserName}
mistral::rabbit_password: {get_param: RabbitPassword} mistral::rabbit_password: {get_param: RabbitPassword}
mistral::rabbit_use_ssl: {get_param: RabbitClientUseSSL} mistral::rabbit_use_ssl: {get_param: RabbitClientUseSSL}

View File

@ -91,6 +91,12 @@ parameters:
description: Mapping of service endpoint -> protocol. Typically set description: Mapping of service endpoint -> protocol. Typically set
via parameter_defaults in the resource registry. via parameter_defaults in the resource registry.
type: json type: json
NotificationDriver:
type: string
default: 'messagingv2'
description: Driver or drivers to handle sending notifications.
constraints:
- allowed_values: [ 'messagingv2', 'noop' ]
conditions: conditions:
dhcp_agents_zero: {equals : [{get_param: NeutronDhcpAgentsPerNetwork}, 0]} dhcp_agents_zero: {equals : [{get_param: NeutronDhcpAgentsPerNetwork}, 0]}
@ -107,6 +113,7 @@ outputs:
neutron::rabbit_user: {get_param: RabbitUserName} neutron::rabbit_user: {get_param: RabbitUserName}
neutron::rabbit_use_ssl: {get_param: RabbitClientUseSSL} neutron::rabbit_use_ssl: {get_param: RabbitClientUseSSL}
neutron::rabbit_port: {get_param: RabbitClientPort} neutron::rabbit_port: {get_param: RabbitClientPort}
neutron::notification_driver: {get_param: NotificationDriver}
neutron::core_plugin: {get_param: NeutronCorePlugin} neutron::core_plugin: {get_param: NeutronCorePlugin}
neutron::service_plugins: {get_param: NeutronServicePlugins} neutron::service_plugins: {get_param: NeutronServicePlugins}
neutron::debug: neutron::debug:

View File

@ -30,6 +30,12 @@ parameters:
type: string type: string
default: 'regionOne' default: 'regionOne'
description: Keystone region for endpoint description: Keystone region for endpoint
NotificationDriver:
type: string
default: 'messagingv2'
description: Driver or drivers to handle sending notifications.
constraints:
- allowed_values: [ 'messagingv2', 'noop' ]
NovaPassword: NovaPassword:
description: The password for the nova service and db account, used by nova-api. description: The password for the nova service and db account, used by nova-api.
type: string type: string
@ -215,7 +221,7 @@ outputs:
nova::cinder_catalog_info: 'volumev2:cinderv2:internalURL' nova::cinder_catalog_info: 'volumev2:cinderv2:internalURL'
nova::host: '%{::fqdn}' nova::host: '%{::fqdn}'
nova::notify_on_state_change: 'vm_and_task_state' nova::notify_on_state_change: 'vm_and_task_state'
nova::notification_driver: messagingv2 nova::notification_driver: {get_param: NotificationDriver}
nova::network::neutron::neutron_auth_type: 'v3password' nova::network::neutron::neutron_auth_type: 'v3password'
nova::db::database_db_max_retries: -1 nova::db::database_db_max_retries: -1
nova::db::database_max_retries: -1 nova::db::database_max_retries: -1

View File

@ -58,6 +58,12 @@ parameters:
default: 5672 default: 5672
description: Set rabbit subscriber port, change this if using SSL description: Set rabbit subscriber port, change this if using SSL
type: number type: number
NotificationDriver:
type: string
default: 'messagingv2'
description: Driver or drivers to handle sending notifications.
constraints:
- allowed_values: [ 'messagingv2', 'noop' ]
conditions: conditions:
service_debug_unset: {equals : [{get_param: OctaviaDebug}, '']} service_debug_unset: {equals : [{get_param: OctaviaDebug}, '']}
@ -74,6 +80,7 @@ outputs:
- {get_param: Debug } - {get_param: Debug }
- {get_param: OctaviaDebug } - {get_param: OctaviaDebug }
octavia::purge_config: {get_param: EnableConfigPurge} octavia::purge_config: {get_param: EnableConfigPurge}
octavia::notification_driver: {get_param: NotificationDriver}
octavia::rabbit_use_ssl: {get_param: RabbitClientUseSSL} octavia::rabbit_use_ssl: {get_param: RabbitClientUseSSL}
octavia::rabbit_userid: {get_param: RabbitUserName} octavia::rabbit_userid: {get_param: RabbitUserName}
octavia::rabbit_password: {get_param: RabbitPassword} octavia::rabbit_password: {get_param: RabbitPassword}

View File

@ -60,6 +60,12 @@ parameters:
default: ["ambari","cdh","mapr","vanilla","spark","storm"] default: ["ambari","cdh","mapr","vanilla","spark","storm"]
description: Sahara enabled plugin list description: Sahara enabled plugin list
type: comma_delimited_list type: comma_delimited_list
NotificationDriver:
type: string
default: 'messagingv2'
description: Driver or drivers to handle sending notifications.
constraints:
- allowed_values: [ 'messagingv2', 'noop' ]
conditions: conditions:
service_debug_unset: {equals : [{get_param: SaharaDebug}, '']} service_debug_unset: {equals : [{get_param: SaharaDebug}, '']}
@ -80,6 +86,7 @@ outputs:
query: query:
read_default_file: /etc/my.cnf.d/tripleo.cnf read_default_file: /etc/my.cnf.d/tripleo.cnf
read_default_group: tripleo read_default_group: tripleo
sahara::notify::notification_driver: {get_param: NotificationDriver}
sahara::rabbit_password: {get_param: RabbitPassword} sahara::rabbit_password: {get_param: RabbitPassword}
sahara::rabbit_user: {get_param: RabbitUserName} sahara::rabbit_user: {get_param: RabbitUserName}
sahara::rabbit_use_ssl: {get_param: RabbitClientUseSSL} sahara::rabbit_use_ssl: {get_param: RabbitClientUseSSL}

View File

@ -65,6 +65,12 @@ parameters:
e.g. { tacker-context_is_admin: { key: context_is_admin, value: 'role:admin' } } e.g. { tacker-context_is_admin: { key: context_is_admin, value: 'role:admin' } }
default: {} default: {}
type: json type: json
NotificationDriver:
type: string
default: 'messagingv2'
description: Driver or drivers to handle sending notifications.
constraints:
- allowed_values: [ 'messagingv2', 'noop' ]
conditions: conditions:
service_debug_unset: {equals : [{get_param: TackerDebug}, '']} service_debug_unset: {equals : [{get_param: TackerDebug}, '']}
@ -93,6 +99,7 @@ outputs:
- {get_param: Debug } - {get_param: Debug }
- {get_param: TackerDebug } - {get_param: TackerDebug }
tacker::rpc_backend: rabbit tacker::rpc_backend: rabbit
tacker::notification_driver: {get_param: NotificationDriver}
tacker::rabbit_userid: {get_param: RabbitUserName} tacker::rabbit_userid: {get_param: RabbitUserName}
tacker::rabbit_password: {get_param: RabbitPassword} tacker::rabbit_password: {get_param: RabbitPassword}
tacker::rabbit_use_ssl: {get_param: RabbitClientUseSSL} tacker::rabbit_use_ssl: {get_param: RabbitClientUseSSL}

View File

@ -0,0 +1,10 @@
---
features:
- |
Allow to configure the Message Queue notification driver.
By default, we'll configure 'messagingv2' but we can now
override NotificationDriver parameter and set 'noop' when
we don't want notifications, which is the case when
we disable Telemetry services.
deprecations:
- KeystoneNotificationDriver is deprecated in favor of NotificationDriver.