From 1587e571cec715b1db9eb62a8ed7ae4e15833091 Mon Sep 17 00:00:00 2001 From: zarzuelo Date: Wed, 5 Mar 2014 11:43:03 +0000 Subject: [PATCH] 2014-03-05 Sergio Martin * pandoradb.sql pandoradb.postgreSQL.sql pandoradb.oracle.sql: Add recovery fields in actions table and recovery field1 in template table in creation scripts of 5.1. Ticket #501 git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@9507 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f --- pandora_console/ChangeLog | 9 +++++++++ pandora_console/pandoradb.oracle.sql | 13 ++++++++++++- pandora_console/pandoradb.postgreSQL.sql | 13 ++++++++++++- pandora_console/pandoradb.sql | 11 +++++++++++ 4 files changed, 44 insertions(+), 2 deletions(-) diff --git a/pandora_console/ChangeLog b/pandora_console/ChangeLog index 9b239d6998..5ba5570a89 100644 --- a/pandora_console/ChangeLog +++ b/pandora_console/ChangeLog @@ -1,3 +1,12 @@ +2014-03-05 Sergio Martin + + * pandoradb.sql + pandoradb.postgreSQL.sql + pandoradb.oracle.sql: Add recovery fields in actions + table and recovery field1 in template table in creation + scripts of 5.1. + Ticket #501 + 2014-03-05 Sergio Martin * include/styles/pandora.css diff --git a/pandora_console/pandoradb.oracle.sql b/pandora_console/pandoradb.oracle.sql index ed0ec2fdd9..1dd2fd92e5 100644 --- a/pandora_console/pandoradb.oracle.sql +++ b/pandora_console/pandoradb.oracle.sql @@ -342,7 +342,17 @@ CREATE TABLE talert_actions ( field9 CLOB default '', field10 CLOB default '', id_group NUMBER(19, 0) default 0 NOT NULL, - action_threshold NUMBER(19, 0) default 0 NOT NULL + action_threshold NUMBER(19, 0) default 0 NOT NULL, + field1_recovery CLOB NOT NULL default '', + field2_recovery CLOB NOT NULL default '', + field3_recovery CLOB NOT NULL default '', + field4_recovery CLOB NOT NULL default '', + field5_recovery CLOB NOT NULL default '', + field6_recovery CLOB NOT NULL default '', + field7_recovery CLOB NOT NULL default '', + field8_recovery CLOB NOT NULL default '', + field9_recovery CLOB NOT NULL default '', + field10_recovery CLOB NOT NULL default '' ); CREATE SEQUENCE talert_actions_s INCREMENT BY 1 START WITH 1; @@ -387,6 +397,7 @@ CREATE TABLE talert_templates ( saturday NUMBER(5, 0) default 1, sunday NUMBER(5, 0) default 1, recovery_notify NUMBER(5, 0) default 0, + field1_recovery CLOB NOT NULL default '', field2_recovery CLOB NOT NULL default '', field3_recovery CLOB NOT NULL default '', field4_recovery CLOB NOT NULL default '', diff --git a/pandora_console/pandoradb.postgreSQL.sql b/pandora_console/pandoradb.postgreSQL.sql index d7f25f8f36..aab591ce3c 100644 --- a/pandora_console/pandoradb.postgreSQL.sql +++ b/pandora_console/pandoradb.postgreSQL.sql @@ -317,7 +317,17 @@ CREATE TABLE "talert_actions" ( "field9" text NOT NULL default '', "field10" text NOT NULL default '', "id_group" BIGINT NOT NULL default 0, - "action_threshold" BIGINT NOT NULL default 0 + "action_threshold" BIGINT NOT NULL default 0, + "field1_recovery" text NOT NULL default '', + "field2_recovery" text NOT NULL default '', + "field3_recovery" text NOT NULL default '', + "field4_recovery" text NOT NULL default '', + "field5_recovery" text NOT NULL default '', + "field6_recovery" text NOT NULL default '', + "field7_recovery" text NOT NULL default '', + "field8_recovery" text NOT NULL default '', + "field9_recovery" text NOT NULL default '', + "field10_recovery" text NOT NULL default '' ); CREATE TYPE type_talert_templates_alert_template AS ENUM ('regex', 'max_min', 'max', 'min', 'equal', 'not_equal', 'warning', 'critical', 'onchange', 'unknown', 'always'); @@ -355,6 +365,7 @@ CREATE TABLE "talert_templates" ( "saturday" SMALLINT default 1, "sunday" SMALLINT default 1, "recovery_notify" SMALLINT default 0, + "field1_recovery" text NOT NULL default '', "field2_recovery" text NOT NULL default '', "field3_recovery" text NOT NULL default '', "field4_recovery" text NOT NULL default '', diff --git a/pandora_console/pandoradb.sql b/pandora_console/pandoradb.sql index e1390e74c7..e3846f6033 100644 --- a/pandora_console/pandoradb.sql +++ b/pandora_console/pandoradb.sql @@ -332,6 +332,16 @@ CREATE TABLE IF NOT EXISTS `talert_actions` ( `field10` text NOT NULL, `id_group` mediumint(8) unsigned NULL default 0, `action_threshold` int(10) NOT NULL default '0', + `field1_recovery` text NOT NULL, + `field2_recovery` text NOT NULL, + `field3_recovery` text NOT NULL, + `field4_recovery` text NOT NULL, + `field5_recovery` text NOT NULL, + `field6_recovery` text NOT NULL, + `field7_recovery` text NOT NULL, + `field8_recovery` text NOT NULL, + `field9_recovery` text NOT NULL, + `field10_recovery` text NOT NULL, PRIMARY KEY (`id`), FOREIGN KEY (`id_alert_command`) REFERENCES talert_commands(`id`) ON DELETE CASCADE ON UPDATE CASCADE @@ -373,6 +383,7 @@ CREATE TABLE IF NOT EXISTS `talert_templates` ( `saturday` tinyint(1) default 1, `sunday` tinyint(1) default 1, `recovery_notify` tinyint(1) default '0', + `field1_recovery` text NOT NULL, `field2_recovery` text NOT NULL, `field3_recovery` text NOT NULL, `field4_recovery` text NOT NULL,