Refactor mistral::notifier
Change-Id: I3438cc6d9b473ff774fc8e68a3f9df65c792bfc6
This commit is contained in:
@@ -5,28 +5,30 @@
|
|||||||
# === Parameters
|
# === Parameters
|
||||||
#
|
#
|
||||||
# [*type*]
|
# [*type*]
|
||||||
# Type of notifier. Use local to run the notifier within the
|
# (Optional) Type of notifier. Use local to run the notifier within
|
||||||
# engine server. Use remote if the notifier is launched as
|
# the engine server. Use remote if the notifier is launched as a separate
|
||||||
# a separate server to process events.
|
# server to process events.
|
||||||
# (string value)
|
# (string value)
|
||||||
# Defaults to $::os_service_default.
|
# Defaults to $::os_service_default.
|
||||||
|
#
|
||||||
# [*host*]
|
# [*host*]
|
||||||
# Name of the notifier node. This can be an opaque
|
# (Optional) Name of the notifier node. This can be an opaque identifier.
|
||||||
# identifier. It is not necessarily a hostname,
|
# It is not necessarily a hostname, FQDN, or IP address.
|
||||||
# FQDN, or IP address.
|
|
||||||
# (string value)
|
# (string value)
|
||||||
# Defaults to $::os_service_default.
|
# Defaults to $::os_service_default.
|
||||||
|
#
|
||||||
# [*topic*]
|
# [*topic*]
|
||||||
# The message topic that the notifier server listens on.
|
# (Optional) The message topic that the notifier server listens on.
|
||||||
# (string value)
|
# (string value)
|
||||||
# Defaults to $::os_service_default.
|
# Defaults to $::os_service_default.
|
||||||
|
#
|
||||||
# [*notify_publishers*]
|
# [*notify_publishers*]
|
||||||
# List of publishers to publish notification.
|
# (Optional) List of publishers to publish notification.
|
||||||
# Note: This maps to the mistral config option `notify` but this is reserved
|
# Note: This maps to the mistral config option `notify` but this is reserved
|
||||||
# in Puppet.
|
# in Puppet.
|
||||||
# (list of dicts)
|
# (list of dicts)
|
||||||
# Defaults to $::os_service_default.
|
# Defaults to $::os_service_default.
|
||||||
|
#
|
||||||
class mistral::notifier(
|
class mistral::notifier(
|
||||||
$type = $::os_service_default,
|
$type = $::os_service_default,
|
||||||
$host = $::os_service_default,
|
$host = $::os_service_default,
|
||||||
|
@@ -2,7 +2,7 @@ require 'spec_helper'
|
|||||||
|
|
||||||
describe 'mistral::notifier' do
|
describe 'mistral::notifier' do
|
||||||
|
|
||||||
shared_examples_for 'mistral notifier' do
|
shared_examples_for 'mistral::notifier' do
|
||||||
it 'configure notifier default params' do
|
it 'configure notifier default params' do
|
||||||
is_expected.to contain_mistral_config('notifier/type').with_value('<SERVICE DEFAULT>')
|
is_expected.to contain_mistral_config('notifier/type').with_value('<SERVICE DEFAULT>')
|
||||||
is_expected.to contain_mistral_config('notifier/host').with_value('<SERVICE DEFAULT>')
|
is_expected.to contain_mistral_config('notifier/host').with_value('<SERVICE DEFAULT>')
|
||||||
@@ -36,7 +36,7 @@ describe 'mistral::notifier' do
|
|||||||
facts.merge!(OSDefaults.get_facts())
|
facts.merge!(OSDefaults.get_facts())
|
||||||
end
|
end
|
||||||
|
|
||||||
it_configures 'mistral notifier'
|
it_configures 'mistral::notifier'
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user