Add support for periodic notification
Change-Id: I024969c5e9568898db3401292a93535491fd45c6
This commit is contained in:
parent
1a4ae8a903
commit
46c945e2f8
|
@ -58,6 +58,9 @@
|
|||
# [*vertica_db_hint*]
|
||||
# database hint to pass to vertica
|
||||
#
|
||||
# [*valid_notif_periods*]
|
||||
# list of valid notification periods in seconds (defaults to 60)
|
||||
#
|
||||
# [*zookeeper_servers*]
|
||||
# list of zookeeper servers and ports
|
||||
#
|
||||
|
@ -79,6 +82,7 @@ class monasca::api (
|
|||
$role_delegate = 'monitoring-delegate',
|
||||
$roles_default = ['admin','monasca-user','_member_'],
|
||||
$roles_agent = ['monasca-agent'],
|
||||
$valid_notif_periods = [60],
|
||||
$vertica_db_hint = '',
|
||||
$zookeeper_servers = undef,
|
||||
) {
|
||||
|
|
|
@ -8,6 +8,13 @@ eventsTopic: events
|
|||
|
||||
maxQueryLimit: <%= @max_query_limit %>
|
||||
|
||||
<% if @valid_notif_periods and not @valid_notif_periods.empty? -%>
|
||||
validNotificationPeriods:
|
||||
<% @valid_notif_periods.each do |period| -%>
|
||||
- <%= period %>
|
||||
<%- end -%>
|
||||
<% end -%>
|
||||
|
||||
kafka:
|
||||
brokerUris:
|
||||
- <%= @kafka_brokers %>
|
||||
|
|
|
@ -121,6 +121,7 @@ CREATE TABLE IF NOT EXISTS `notification_method` (
|
|||
`name` varchar(250) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
||||
`type` varchar(20) COLLATE utf8mb4_unicode_ci NOT NULL,
|
||||
`address` varchar(512) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
|
||||
`period` int NOT NULL DEFAULT 0,
|
||||
`created_at` datetime NOT NULL,
|
||||
`updated_at` datetime NOT NULL,
|
||||
PRIMARY KEY (`id`),
|
||||
|
|
Loading…
Reference in New Issue