rel-eng/packages schema/spacewalk
by Jan Pazdziora
rel-eng/packages/spacewalk-schema | 2 +-
schema/spacewalk/spacewalk-schema.spec | 5 ++++-
2 files changed, 5 insertions(+), 2 deletions(-)
New commits:
commit 61bf6fb3c1eab597f074d46a199eb3f537db75ca
Author: Jan Pazdziora <jpazdziora(a)redhat.com>
Date: Wed Feb 1 16:07:20 2012 +0100
Automatic commit of package [spacewalk-schema] release [1.7.22-1].
diff --git a/rel-eng/packages/spacewalk-schema b/rel-eng/packages/spacewalk-schema
index 4f8c541..06fef4f 100644
--- a/rel-eng/packages/spacewalk-schema
+++ b/rel-eng/packages/spacewalk-schema
@@ -1 +1 @@
-1.7.21-1 schema/spacewalk/
+1.7.22-1 schema/spacewalk/
diff --git a/schema/spacewalk/spacewalk-schema.spec b/schema/spacewalk/spacewalk-schema.spec
index 3116fb0..2bd7598 100644
--- a/schema/spacewalk/spacewalk-schema.spec
+++ b/schema/spacewalk/spacewalk-schema.spec
@@ -2,7 +2,7 @@ Name: spacewalk-schema
Group: Applications/Internet
Summary: Oracle SQL schema for Spacewalk server
-Version: 1.7.21
+Version: 1.7.22
Release: 1%{?dist}
Source0: %{name}-%{version}.tar.gz
@@ -66,6 +66,9 @@ rm -rf $RPM_BUILD_ROOT
%{_mandir}/man1/spacewalk-sql*
%changelog
+* Wed Feb 01 2012 Jan Pazdziora 1.7.22-1
+- Fixing oracle equivalent source sha1.
+
* Wed Feb 01 2012 Miroslav Suchý 1.7.21-1
- rip off SNMP notification method
12 years, 3 months
schema/spacewalk
by Jan Pazdziora
schema/spacewalk/upgrade/spacewalk-schema-1.6-to-spacewalk-schema-1.7/011-rhn_contact_methods.sql.postgresql | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
New commits:
commit bd1fdedd60c10266d95227a2df6fbabc53ee679d
Author: Jan Pazdziora <jpazdziora(a)redhat.com>
Date: Wed Feb 1 16:06:53 2012 +0100
Fixing oracle equivalent source sha1.
diff --git a/schema/spacewalk/upgrade/spacewalk-schema-1.6-to-spacewalk-schema-1.7/011-rhn_contact_methods.sql.postgresql b/schema/spacewalk/upgrade/spacewalk-schema-1.6-to-spacewalk-schema-1.7/011-rhn_contact_methods.sql.postgresql
index e7d9712..17e7caf 100644
--- a/schema/spacewalk/upgrade/spacewalk-schema-1.6-to-spacewalk-schema-1.7/011-rhn_contact_methods.sql.postgresql
+++ b/schema/spacewalk/upgrade/spacewalk-schema-1.6-to-spacewalk-schema-1.7/011-rhn_contact_methods.sql.postgresql
@@ -1,4 +1,4 @@
--- oracle equivalent source sha1 e58bd36819c4101d8efbe3b8aa6b77979c277b91
+-- oracle equivalent source sha1 4603bcc1420577081bec09a80663a1aebe9a72bf
create or replace function rhn_cmeth_val_trig_fun() returns trigger as
$$
begin
12 years, 3 months
Changes to 'refs/tags/spacewalk-repo-1.7-4'
by Jan Pazdziora
Tag 'spacewalk-repo-1.7-4' created by Jan Pazdziora <jpazdziora(a)redhat.com> at 2012-02-01 14:48 +0000
Tagging package [spacewalk-repo] version [1.7-4] in directory [spec-tree/spacewalk-repo/].
Changes since NPalert-1.127.2-1:
Jan Pazdziora (2):
Revert "add Source0"
Automatic commit of package [spacewalk-repo] minor release [1.7-4].
---
rel-eng/packages/spacewalk-repo | 2 +-
spec-tree/spacewalk-repo/spacewalk-repo.spec | 11 +++++++++--
2 files changed, 10 insertions(+), 3 deletions(-)
---
12 years, 3 months
rel-eng/packages spec-tree/spacewalk-repo
by Jan Pazdziora
rel-eng/packages/spacewalk-repo | 2 +-
spec-tree/spacewalk-repo/spacewalk-repo.spec | 5 ++++-
2 files changed, 5 insertions(+), 2 deletions(-)
New commits:
commit a565b5105760d31c34a51c36a822a6651100fe0b
Author: Jan Pazdziora <jpazdziora(a)redhat.com>
Date: Wed Feb 1 15:48:49 2012 +0100
Automatic commit of package [spacewalk-repo] minor release [1.7-4].
diff --git a/rel-eng/packages/spacewalk-repo b/rel-eng/packages/spacewalk-repo
index 1a9cb46..49078c9 100644
--- a/rel-eng/packages/spacewalk-repo
+++ b/rel-eng/packages/spacewalk-repo
@@ -1 +1 @@
-1.7-3 spec-tree/spacewalk-repo/
+1.7-4 spec-tree/spacewalk-repo/
diff --git a/spec-tree/spacewalk-repo/spacewalk-repo.spec b/spec-tree/spacewalk-repo/spacewalk-repo.spec
index f1374f9..41e5adb 100644
--- a/spec-tree/spacewalk-repo/spacewalk-repo.spec
+++ b/spec-tree/spacewalk-repo/spacewalk-repo.spec
@@ -1,7 +1,7 @@
Summary: Spacewalk packages yum repository configuration
Name: spacewalk-repo
Version: 1.7
-Release: 3%{?dist}
+Release: 4%{?dist}
License: GPLv2
Group: System Environment/Base
# This src.rpm is cannonical upstream
@@ -79,6 +79,9 @@ rm -rf $RPM_BUILD_ROOT
%config %{_sysconfdir}/yum.repos.d/spacewalk-client.repo
%changelog
+* Wed Feb 01 2012 Jan Pazdziora 1.7-4
+- Revert "add Source0"
+
* Wed Feb 01 2012 Miroslav Suchý 1.7-3
- do not check gpg at nightly - it is not signed
12 years, 3 months
spec-tree/spacewalk-repo
by Jan Pazdziora
spec-tree/spacewalk-repo/spacewalk-repo.spec | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
New commits:
commit 8c5aadc5faf5cc8a940fd2f905a3b91d03311975
Author: Jan Pazdziora <jpazdziora(a)redhat.com>
Date: Wed Feb 1 15:46:44 2012 +0100
Revert "add Source0"
This reverts commit 39ba961cfaf962b2dc492e459233efebf23e948e.
diff --git a/spec-tree/spacewalk-repo/spacewalk-repo.spec b/spec-tree/spacewalk-repo/spacewalk-repo.spec
index 4dafc3a..f1374f9 100644
--- a/spec-tree/spacewalk-repo/spacewalk-repo.spec
+++ b/spec-tree/spacewalk-repo/spacewalk-repo.spec
@@ -4,7 +4,11 @@ Version: 1.7
Release: 3%{?dist}
License: GPLv2
Group: System Environment/Base
-Source0: https://fedorahosted.org/releases/s/p/spacewalk/%{name}-%{version}.tar.gz
+# This src.rpm is cannonical upstream
+# You can obtain it using this set of commands
+# git clone git://git.fedorahosted.org/git/spacewalk.git/
+# cd spec-tree/spacewalk-repo
+# make test-srpm
URL: https://fedorahosted.org/spacewalk
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-buildroot
BuildArch: noarch
12 years, 3 months
Changes to 'refs/tags/NPalert-1.127.2-1'
by Miroslav Suchý
Tag 'NPalert-1.127.2-1' created by Miroslav Suchý <msuchy(a)redhat.com> at 2012-02-01 14:37 +0000
Tagging package [NPalert] version [1.127.2-1] in directory [monitoring/NPalert/].
Changes since spacewalk-schema-1.7.21-1:
Miroslav Suchý (2):
bump up version
Automatic commit of package [NPalert] release [1.127.2-1].
---
monitoring/NPalert/NPalert.spec | 7 ++++++-
rel-eng/packages/NPalert | 2 +-
2 files changed, 7 insertions(+), 2 deletions(-)
---
12 years, 3 months
2 commits - monitoring/NPalert rel-eng/packages
by Miroslav Suchý
monitoring/NPalert/NPalert.spec | 7 ++++++-
rel-eng/packages/NPalert | 2 +-
2 files changed, 7 insertions(+), 2 deletions(-)
New commits:
commit 0f0f47c0a67a81dd01398b6ab19c73560f9ae674
Author: Miroslav Suchý <msuchy(a)redhat.com>
Date: Wed Feb 1 15:37:05 2012 +0100
Automatic commit of package [NPalert] release [1.127.2-1].
diff --git a/monitoring/NPalert/NPalert.spec b/monitoring/NPalert/NPalert.spec
index bf23a04..36bf30e 100644
--- a/monitoring/NPalert/NPalert.spec
+++ b/monitoring/NPalert/NPalert.spec
@@ -9,7 +9,7 @@ Name: NPalert
Summary: NOCpulse notification system
URL: https://fedorahosted.org/spacewalk
Source0: https://fedorahosted.org/releases/s/p/spacewalk/%{name}-%{version}.tar.gz
-Version: 1.127.1
+Version: 1.127.2
Release: 1%{?dist}
BuildArch: noarch
Requires: perl(:MODULE_COMPAT_%(eval "`%{__perl} -V:version`"; echo $version))
@@ -137,6 +137,11 @@ fi
rm -rf $RPM_BUILD_ROOT
%changelog
+* Wed Feb 01 2012 Miroslav Suchý 1.127.2-1
+- bump up version (msuchy(a)redhat.com)
+- get rid of PhoneContactMethod - is is not even in DB
+- rip off SNMP notification method
+
* Tue Jan 31 2012 Jan Pazdziora 1.126.31-1
- In monitoring, use RHN::DBI instead of RHN::DB because we do not want to
reuse the connection.
diff --git a/rel-eng/packages/NPalert b/rel-eng/packages/NPalert
index 02c92ba..8c96f8d 100644
--- a/rel-eng/packages/NPalert
+++ b/rel-eng/packages/NPalert
@@ -1 +1 @@
-1.126.31-1 monitoring/NPalert/
+1.127.2-1 monitoring/NPalert/
commit d488bafcbf27967f49616963b165882d7a796998
Author: Miroslav Suchý <msuchy(a)redhat.com>
Date: Wed Feb 1 15:36:51 2012 +0100
bump up version
diff --git a/monitoring/NPalert/NPalert.spec b/monitoring/NPalert/NPalert.spec
index eb63ca7..bf23a04 100644
--- a/monitoring/NPalert/NPalert.spec
+++ b/monitoring/NPalert/NPalert.spec
@@ -9,7 +9,7 @@ Name: NPalert
Summary: NOCpulse notification system
URL: https://fedorahosted.org/spacewalk
Source0: https://fedorahosted.org/releases/s/p/spacewalk/%{name}-%{version}.tar.gz
-Version: 1.126.31
+Version: 1.127.1
Release: 1%{?dist}
BuildArch: noarch
Requires: perl(:MODULE_COMPAT_%(eval "`%{__perl} -V:version`"; echo $version))
12 years, 3 months
Changes to 'refs/tags/spacewalk-schema-1.7.21-1'
by Miroslav Suchý
Tag 'spacewalk-schema-1.7.21-1' created by Miroslav Suchý <msuchy(a)redhat.com> at 2012-02-01 14:34 +0000
Tagging package [spacewalk-schema] version [1.7.21-1] in directory [schema/spacewalk/].
Changes since status_log_acceptor-0.12.9-1:
Miroslav Suchý (3):
rip off SNMP notification method
get rid of PhoneContactMethod - is is not even in DB
Automatic commit of package [spacewalk-schema] release [1.7.21-1].
---
monitoring/NPalert/AlertDB.pm | 19
monitoring/NPalert/ContactMethod.pm | 1
monitoring/NPalert/NotifIniInterface.pm | 12
monitoring/NPalert/NotificationDB.pm | 6
monitoring/NPalert/PhoneContactMethod.pm | 68 ---
monitoring/NPalert/SNMPContactMethod.pm | 220 ----------
monitoring/NPalert/Send.pm | 1
monitoring/NPalert/test/TODO2 | 3
monitoring/NPalert/test/TestAlertDB.pm | 14
monitoring/NPalert/test/TestNotificationDB.pm | 38 -
monitoring/NPalert/test/TestPhoneContactMethod.pm | 32 -
rel-eng/packages/spacewalk-schema | 2
schema/spacewalk/oracle/triggers/rhn_contact_methods.sql | 11
schema/spacewalk/postgres/triggers/rhn_contact_methods.sql | 11
schema/spacewalk/spacewalk-schema.spec | 5
schema/spacewalk/upgrade/spacewalk-schema-1.6-to-spacewalk-schema-1.7/011-rhn_contact_methods.sql.oracle | 57 ++
schema/spacewalk/upgrade/spacewalk-schema-1.6-to-spacewalk-schema-1.7/011-rhn_contact_methods.sql.postgresql | 32 +
17 files changed, 95 insertions(+), 437 deletions(-)
---
12 years, 3 months
Changes to 'refs/tags/NPalert-1.126.32-1'
by Miroslav Suchý
Tag 'NPalert-1.126.32-1' created by Miroslav Suchý <msuchy(a)redhat.com> at 2012-02-01 14:30 +0000
Tagging package [NPalert] version [1.126.32-1] in directory [monitoring/NPalert/].
Changes since SatConfig-general-1.216.26-1:
Jan Pazdziora (2):
Use RHN::DBI instead of plain DBI with sc_db login parameters.
Fixing inserts and updates for RHN_PROBE_STATE and RHN_SATELLITE_STATE.
Miroslav Suchý (3):
rip off SNMP notification method
get rid of PhoneContactMethod - is is not even in DB
Automatic commit of package [NPalert] release [1.126.32-1].
Tomas Lestach (1):
do not store DB information into the rhn_config_macro
---
java/code/src/com/redhat/rhn/manager/satellite/ConfigureSatelliteCommand.java | 12
monitoring/NPalert/AlertDB.pm | 19
monitoring/NPalert/ContactMethod.pm | 1
monitoring/NPalert/NPalert.spec | 6
monitoring/NPalert/NotifIniInterface.pm | 12
monitoring/NPalert/NotificationDB.pm | 6
monitoring/NPalert/PhoneContactMethod.pm | 68 ---
monitoring/NPalert/SNMPContactMethod.pm | 220 ----------
monitoring/NPalert/Send.pm | 1
monitoring/NPalert/test/TODO2 | 3
monitoring/NPalert/test/TestAlertDB.pm | 14
monitoring/NPalert/test/TestNotificationDB.pm | 38 -
monitoring/NPalert/test/TestPhoneContactMethod.pm | 32 -
monitoring/status_log_acceptor/AcceptStatusLog.pm | 17
rel-eng/packages/NPalert | 2
schema/spacewalk/oracle/triggers/rhn_contact_methods.sql | 11
schema/spacewalk/postgres/triggers/rhn_contact_methods.sql | 11
schema/spacewalk/upgrade/spacewalk-schema-1.6-to-spacewalk-schema-1.7/011-rhn_contact_methods.sql.oracle | 57 ++
schema/spacewalk/upgrade/spacewalk-schema-1.6-to-spacewalk-schema-1.7/011-rhn_contact_methods.sql.postgresql | 32 +
19 files changed, 103 insertions(+), 459 deletions(-)
---
12 years, 3 months
3 commits - monitoring/NPalert rel-eng/packages schema/spacewalk
by Miroslav Suchý
monitoring/NPalert/AlertDB.pm | 19
monitoring/NPalert/ContactMethod.pm | 1
monitoring/NPalert/NotifIniInterface.pm | 12
monitoring/NPalert/NotificationDB.pm | 6
monitoring/NPalert/PhoneContactMethod.pm | 68 ---
monitoring/NPalert/SNMPContactMethod.pm | 220 ----------
monitoring/NPalert/Send.pm | 1
monitoring/NPalert/test/TODO2 | 3
monitoring/NPalert/test/TestAlertDB.pm | 14
monitoring/NPalert/test/TestNotificationDB.pm | 38 -
monitoring/NPalert/test/TestPhoneContactMethod.pm | 32 -
rel-eng/packages/spacewalk-schema | 2
schema/spacewalk/oracle/triggers/rhn_contact_methods.sql | 11
schema/spacewalk/postgres/triggers/rhn_contact_methods.sql | 11
schema/spacewalk/spacewalk-schema.spec | 5
schema/spacewalk/upgrade/spacewalk-schema-1.6-to-spacewalk-schema-1.7/011-rhn_contact_methods.sql.oracle | 57 ++
schema/spacewalk/upgrade/spacewalk-schema-1.6-to-spacewalk-schema-1.7/011-rhn_contact_methods.sql.postgresql | 32 +
17 files changed, 95 insertions(+), 437 deletions(-)
New commits:
commit 6324b86ab7760620ad5d0015932a23ec987c4828
Author: Miroslav Suchý <msuchy(a)redhat.com>
Date: Wed Feb 1 15:34:40 2012 +0100
Automatic commit of package [spacewalk-schema] release [1.7.21-1].
diff --git a/rel-eng/packages/spacewalk-schema b/rel-eng/packages/spacewalk-schema
index a8223ac..4f8c541 100644
--- a/rel-eng/packages/spacewalk-schema
+++ b/rel-eng/packages/spacewalk-schema
@@ -1 +1 @@
-1.7.20-1 schema/spacewalk/
+1.7.21-1 schema/spacewalk/
diff --git a/schema/spacewalk/spacewalk-schema.spec b/schema/spacewalk/spacewalk-schema.spec
index 75110ee..3116fb0 100644
--- a/schema/spacewalk/spacewalk-schema.spec
+++ b/schema/spacewalk/spacewalk-schema.spec
@@ -2,7 +2,7 @@ Name: spacewalk-schema
Group: Applications/Internet
Summary: Oracle SQL schema for Spacewalk server
-Version: 1.7.20
+Version: 1.7.21
Release: 1%{?dist}
Source0: %{name}-%{version}.tar.gz
@@ -66,6 +66,9 @@ rm -rf $RPM_BUILD_ROOT
%{_mandir}/man1/spacewalk-sql*
%changelog
+* Wed Feb 01 2012 Miroslav Suchý 1.7.21-1
+- rip off SNMP notification method
+
* Wed Jan 25 2012 Michael Mraka <michael.mraka(a)redhat.com> 1.7.20-1
- 756918 - fix data for package_group
commit af12fcc73912e6642daa3335784c2f28d203de86
Author: Miroslav Suchý <msuchy(a)redhat.com>
Date: Wed Feb 1 15:22:50 2012 +0100
get rid of PhoneContactMethod - is is not even in DB
diff --git a/monitoring/NPalert/NotifIniInterface.pm b/monitoring/NPalert/NotifIniInterface.pm
index 7bac23d..19845b2 100644
--- a/monitoring/NPalert/NotifIniInterface.pm
+++ b/monitoring/NPalert/NotifIniInterface.pm
@@ -12,7 +12,6 @@ use NOCpulse::Log::Logger;
use NOCpulse::Notif::PagerContactMethod;
use NOCpulse::Notif::EmailContactMethod;
use NOCpulse::Notif::SimpleEmailContactMethod;
-use NOCpulse::Notif::PhoneContactMethod;
use NOCpulse::Notif::ContactGroup;
use NOCpulse::Notif::BroadcastStrategy;
use NOCpulse::Notif::EscalateStrategy;
@@ -95,10 +94,6 @@ sub buildContactMethods {
# email
$method = new NOCpulse::Notif::EmailContactMethod;
$method->email($hashptr->{'email_address'});
- } elsif ($type == 3) {
- $method = new NOCpulse::Notif::PhoneContactMethod;
-
- # phone
}
if ($method) {
diff --git a/monitoring/NPalert/PhoneContactMethod.pm b/monitoring/NPalert/PhoneContactMethod.pm
deleted file mode 100644
index 982a28e..0000000
--- a/monitoring/NPalert/PhoneContactMethod.pm
+++ /dev/null
@@ -1,68 +0,0 @@
-package NOCpulse::Notif::PhoneContactMethod;
-
-@ISA = qw(NOCpulse::Notif::ContactMethod);
-
-use strict;
-use NOCpulse::Notif::ContactMethod;
-
-#############
-sub deliver {
-#############
- return undef
-}
-
-1;
-
-
-__END__
-
-
-=head1 NAME
-
-NOCpulse::Notif::Phone - OBSOLETE. A ContactMethod that delivers its alert notification via voice phone.
-
-=head1 DESCRIPTION
-
-THIS CLASS IS OBSOLETE. It serves as a placeholder for future additions to the system.
-
-=head1 CLASS METHODS
-
-=over 4
-
-=item new ( [%args] )
-
-OBSOLETE. Create a new object with the supplied arguments, if any.
-
-=back
-
-=head1 METHODS
-
-=over 4
-
-=item deliver ( )
-
-OBSOLETE. Return a command line string which when executed will delivery the notification to this destination.
-
-=back
-
-=head1 BUGS
-
-No known bugs; however, this class is deemed OBSOLETE and is void of behavior.
-
-=head1 AUTHOR
-
-Karen Jacqmin-Adams <kja(a)redhat.com>
-
-Last update: $Date: 2004-11-18 17:13:13 $
-
-=head1 SEE ALSO
-
-B<NOCpulse::Notif::ContactMethod>
-B<NOCpulse::Notif::EmailContactMethod>
-B<NOCpulse::Notif::PagerContactMethod>
-B<NOCpulse::Notif::Alert>
-B<NOCpulse::Notif::Schedule>
-B<NOCpulse::Notif::MessageFormat>
-B<notifier>
-
-=cut
diff --git a/monitoring/NPalert/test/TODO2 b/monitoring/NPalert/test/TODO2
index cb4618b..6b17f97 100644
--- a/monitoring/NPalert/test/TODO2
+++ b/monitoring/NPalert/test/TODO2
@@ -143,9 +143,6 @@ sub buildSchedules {
PagerContactMethod.pm
sub deliver {
--PhoneContactMethod.pm
--sub deliver {
-
#Redirect.pm
#sub redirect {
#sub matches {
diff --git a/monitoring/NPalert/test/TestPhoneContactMethod.pm b/monitoring/NPalert/test/TestPhoneContactMethod.pm
deleted file mode 100644
index 21a5ab8..0000000
--- a/monitoring/NPalert/test/TestPhoneContactMethod.pm
+++ /dev/null
@@ -1,32 +0,0 @@
-package test::TestPhoneContactMethod;
-
-use strict;
-
-use base qw(Test::Unit::TestCase);
-
-use NOCpulse::Notif::EmailContactMethod;
-use NOCpulse::Notif::Alert;
-
-my $MODULE = 'NOCpulse::Notif::EmailContactMethod';
-
-my $CONFIG=NOCpulse::Config->new;
-my $server = $CONFIG->get('mail', 'mx');
-
-
-$| = 1;
-
-######################
-sub test_constructor {
-######################
- my $self = shift;
- my $obj = $MODULE->new();
-
- # Make sure creation succeeded
- $self->assert(defined($obj), "Couldn't create $MODULE object: $@");
-
- # Make sure we got the right type of object
- $self->assert(qr/$MODULE/, "$obj");
-
-}
-
-1;
commit f8e36feb1850efcd8dd6058306436ae5f26a5b20
Author: Miroslav Suchý <msuchy(a)redhat.com>
Date: Wed Feb 1 14:58:27 2012 +0100
rip off SNMP notification method
diff --git a/monitoring/NPalert/AlertDB.pm b/monitoring/NPalert/AlertDB.pm
index fadf552..4394887 100644
--- a/monitoring/NPalert/AlertDB.pm
+++ b/monitoring/NPalert/AlertDB.pm
@@ -208,23 +208,6 @@ sub init_statements {
);
$self->dbprepare(
- 'create_snmp_alert',
- "INSERT INTO SNMP_ALERT (
- RECID, SENDER_CLUSTER_ID, DEST_IP,
- DEST_PORT, DATE_GENERATED, DATE_SUBMITTED,
- COMMAND_NAME, NOTIF_TYPE, OP_CENTER,
- NOTIF_URL, OS_NAME, MESSAGE,
- PROBE_ID, HOST_IP, SEVERITY,
- COMMAND_ID, PROBE_CLASS, HOST_NAME)
- SELECT SNMP_ALERT_RECID_SEQ.nextval, ?, ?,
- ?, TO_DATE(?, 'MM-DD-YYYY HH24:MI:SS'), TO_DATE(?, 'MM-DD-YYYY HH24:MI:SS'),
- ?, ?, ?,
- ?, ?, ?,
- ?, ?, ?,
- ?, ?, ?
- FROM dual"
- );
- $self->dbprepare(
'select_next_redirect_recid',
"select REDIRECTS_RECID_SEQ.nextval
from DUAL"
@@ -411,8 +394,6 @@ Create a new redirect criterion record with the specified bindvars.
Create a new email address destination for a redirect.
-- create_snmp_alert (SENDER_CLUSTER_ID, DEST_IP, DEST_PORT, DATE_GENERATED, DATE_SUBMITTED, COMMAND_NAME, NOTIF_TYPE, OP_CENTER, NOTIF_URL, OS_NAME, MESSAGE, PROBE_ID, HOST_IP, SEVERITY, COMMAND_ID, PROBE_CLASS, HOST_NAME )
-
Create an snmp type alert with the specified bindvars.
- delete_redirect (RECID)
diff --git a/monitoring/NPalert/ContactMethod.pm b/monitoring/NPalert/ContactMethod.pm
index 6b62092..ffe4cea 100644
--- a/monitoring/NPalert/ContactMethod.pm
+++ b/monitoring/NPalert/ContactMethod.pm
@@ -162,7 +162,6 @@ Last update: $Date: 2005-02-10 22:45:14 $
B<NOCpulse::Notif::Destination>
B<NOCpulse::Notif::EmailContactMethod>
B<NOCpulse::Notif::PagerContactMethod>
-B<NOCpulse::Notif::SNMPContactMethod>
B<NOCpulse::Notif::ContactGroup>
B<NOCpulse::Notif::Alert>
B<NOCpulse::Notif::Escalator>
diff --git a/monitoring/NPalert/NotifIniInterface.pm b/monitoring/NPalert/NotifIniInterface.pm
index 85fd7e3..7bac23d 100644
--- a/monitoring/NPalert/NotifIniInterface.pm
+++ b/monitoring/NPalert/NotifIniInterface.pm
@@ -13,7 +13,6 @@ use NOCpulse::Notif::PagerContactMethod;
use NOCpulse::Notif::EmailContactMethod;
use NOCpulse::Notif::SimpleEmailContactMethod;
use NOCpulse::Notif::PhoneContactMethod;
-use NOCpulse::Notif::SNMPContactMethod;
use NOCpulse::Notif::ContactGroup;
use NOCpulse::Notif::BroadcastStrategy;
use NOCpulse::Notif::EscalateStrategy;
@@ -100,12 +99,6 @@ sub buildContactMethods {
$method = new NOCpulse::Notif::PhoneContactMethod;
# phone
- } elsif ($type == 5) {
- $method = new NOCpulse::Notif::SNMPContactMethod;
- $method->ip($hashptr->{'snmp_host'});
- $method->port($hashptr->{'snmp_port'});
-
- # snmp
}
if ($method) {
diff --git a/monitoring/NPalert/NotificationDB.pm b/monitoring/NPalert/NotificationDB.pm
index 633ddb1..aaa2be7 100644
--- a/monitoring/NPalert/NotificationDB.pm
+++ b/monitoring/NPalert/NotificationDB.pm
@@ -104,12 +104,6 @@ sub create_redirect_method_target {
shift->_create('RHN_REDIRECT_METHOD_TARGETS', @_);
}
-# Records requiring sequence
-sub create_snmp_alert {
- shift->_create_with_seq('RECID', 'RHN_SNMP_ALERT_RECID_SEQ', 'SNMP_ALERT',
- @_);
-}
-
sub create_current_alert {
shift->_create_with_seq('RECID', 'RHN_CURRENT_ALERTS_RECID_SEQ',
'RHN_RHN_CURRENT_ALERTS', @_);
diff --git a/monitoring/NPalert/SNMPContactMethod.pm b/monitoring/NPalert/SNMPContactMethod.pm
deleted file mode 100644
index 2315c5f..0000000
--- a/monitoring/NPalert/SNMPContactMethod.pm
+++ /dev/null
@@ -1,220 +0,0 @@
-package NOCpulse::Notif::SNMPContactMethod;
-
-@ISA = qw(NOCpulse::Notif::ContactMethod);
-
-use strict;
-use Class::MethodMaker
- new_hash_init => 'new',
- get_set => [ qw ( ip port) ];
-
-use NOCpulse::Notif::ContactMethod;
-use Date::Format;
-use NOCpulse::Notif::AlertDB;
-
-use NOCpulse::Log::Logger;
-my $Log = NOCpulse::Log::Logger->new(__PACKAGE__);
-
-use NOCpulse::Config;
-
-my $np_cfg = new NOCpulse::Config;
-my $snmp_url = $np_cfg->get('notification','snmp_notif_url');
-
-use constant DEF_UNIX_DATE_FMT => '%m-%d-%Y %H:%M:%S';
-
-
-#############
-sub deliver {
-#############
- my ($self,$alert,$db,$smtp)=@_;
-
- my($string,$sat_cluster_id)=split(/\//,$alert->snmpPort);
- my($dest_ip,$dest_port)=split(/:/,$string);
-
- my $record = {
-# RECID (COMPLETED BY CREATE CALL)
- SENDER_CLUSTER_ID => $alert->clusterId,
- DEST_IP => $self->ip,
- DEST_PORT => $self->port,
- DATE_GENERATED => $alert->time,
- DATE_SUBMITTED => $alert->current_time,
- COMMAND_NAME => $alert->commandLongName,
-# NOTIF_TYPE (DERIVED LATER)
- OP_CENTER => $alert->physicalLocationName,
-# NOTIF_URL => (DERIVED LATER)
- OS_NAME => $alert->osName,
- MESSAGE => $alert->message,
- PROBE_ID => $alert->probeId,
- HOST_IP => $alert->hostAddress,
-# SEVERITY (DERIVED LATER)
- COMMAND_ID => $alert->checkCommand,
-# PROBE_CLASS (DERIVED LATER)
- HOST_NAME => $alert->hostName,
-# SUPPORT_CENTER (LEFT NULL)
- SEND_ID => $alert->send_id
- };
-
- #The following code has been swiped from MessageQueue/dequeue and modified
- #to suit the needs of notification
- # BEGIN 'THEFT'
-
- # This should be constructed somehow -- waiting for UI guys.
- $record->{'notif_url'}=sprintf("%s?function=host&id=%s",
- $snmp_url,$alert->hostProbeId);
-
- # For OK messages, set notifType = 2 (clear alert).
- # For others, set notifType = 1 (alert), and set notifSeverity
- # to 1 for UNKNOWN, 3 for WARN and 5 for CRITICAL.
-
- if ( ( $alert->state eq 'WARN') or
- ( $alert->state eq 'WARNING' ) ) {
-
- $record->{'NOTIF_TYPE'} = 1;
- $record->{'SEVERITY'} = 3;
-
- } elsif ($alert->servicestate eq 'CRITICAL') {
-
- $record->{'NOTIF_TYPE'} = 1;
- $record->{'SEVERITY'} = 5;
-
- } elsif ($alert->servicestate eq 'OK') {
-
- $record->{'NOTIF_TYPE'} = 2;
- $record->{'SEVERITY'} = 0;
-
- } else {
-
- # UNKNOWN state (or unknown state :)
- $record->{'NOTIF_TYPE'} = 1;
- $record->{'SEVERITY'} = 1;
-
- }
-
- # Set notifProbeClass from probeGroupName.
-
- # For probe classification
- my %class_map = (
- # 'host' class -- host monitoring
- 1 => [qw(logagent satellite storage tools unix windows)],
-
- # 'net' class -- network monitoring
- 2 => [qw(netservice networking)],
-
- # Everything else is application monitoring (default, so no list)
- 3 => [],
- );
-
- my $class;
- my $probegroup = $alert->probeGroupName;
-
- $record->{'PROBE_CLASS'} = 3; # Default to app monitoring
- foreach $class (keys %class_map) {
- if (grep(/$probegroup/, @{$class_map{$class}})) {
- $record->{'PROBE_CLASS'} = $class;
- last;
- }
- }
- # END 'THEFT'
-
-
- $Log->log(3,"storing SNMP record in the database\n");
-
- my ($errcode,$errstring)=$db->dbexecute('create_snmp_alert',
- $record->{SENDER_CLUSTER_ID},
- $record->{DEST_IP},
- $record->{DEST_PORT},
- time2str(DEF_UNIX_DATE_FMT,$record->{DATE_GENERATED}),
- time2str(DEF_UNIX_DATE_FMT,$record->{DATE_SUBMITTED}),
- $record->{COMMAND_NAME},
- $record->{NOTIF_TYPE},
- $record->{OP_CENTER},
- $record->{NOTIF_URL},
- $record->{OS_NAME},
- $record->{MESSAGE},
- $record->{PROBE_ID},
- $record->{HOST_IP},
- $record->{SEVERITY},
- $record->{COMMAND_ID},
- $record->{PROBE_CLASS},
- $record->{HOST_NAME});
-
- if ($errcode) {
- $Log->log(1,"SMTP message commit error $errcode: $errstring\n");
- } else {
- ($errcode)=$db->commit;
- $Log->log(1,"Unable to commit SMTP message") if $errcode;
- }
- return $errcode;
-}
-
-1;
-
-
-=head1 NAME
-
-NOCpulse::Notif::SNMPContactMethod - A ContactMethod that delivers its alert notification via SNMP trap.
-
-=head1 SYNOPSIS
-
-# Create a new snmp contact method
-$method=NOCpulse::Notif::SNMPContactMethod->new(
- 'ip' => 'nowhere.nocpulse.com',
- 'port' => 5050,
- 'schedule' => $schedule,
- 'message_format' => $message_format );
-
-# Create a new strategy for this alert
-$strategy=$method->new_strategy_for_alert->($alert);
-
-# Create the command that will send a specified alert to this destination
-$cmd=$method->send($alert);
-
-=head1 DESCRIPTION
-
-The C<SNMPContactMethod> object is a type of ContactMethod that sends notifications by sending an SNMP trap. A record is queued in the database for later delivery.
-
-=head1 CLASS METHODS
-
-=over 4
-
-=item new ( [%args] )
-
-Create a new object with the supplied arguments, if any.
-
-=back
-
-=head1 METHODS
-
-=over 4
-
-=item deliver ( $alert, $db, $smtp )
-
-Launch a send to this contact method.
-
-=item ip ( [$ip] )
-
-Get or set the ip to use for the snmp trap.
-
-=item port ( [$port] )
-
-Get or set the port to use for the snmp trap.
-
-=back
-
-=head1 BUGS
-
-No known bugs.
-
-=head1 AUTHOR
-
-Karen Jacqmin-Adams <kja(a)redhat.com>
-
-Last update: $Date: 2004-11-18 17:13:13 $
-
-=head1 SEE ALSO
-
-B<NOCpulse::Notif::ContactMethod>
-B<NOCpulse::Notif::Alert>
-B<NOCpulse::Notif::Schedule>
-B<notifier>
-
-=cut
diff --git a/monitoring/NPalert/Send.pm b/monitoring/NPalert/Send.pm
index d72209a..a2a80c5 100644
--- a/monitoring/NPalert/Send.pm
+++ b/monitoring/NPalert/Send.pm
@@ -10,7 +10,6 @@ use Class::MethodMaker
use Date::Format;
use NOCpulse::Notif::ContactMethod;
use NOCpulse::Notif::PagerContactMethod;
-use NOCpulse::Notif::SNMPContactMethod;
use NOCpulse::Notif::SendInfo;
use NOCpulse::Log::Logger;
my $Log = NOCpulse::Log::Logger->new(__PACKAGE__);
diff --git a/monitoring/NPalert/test/TestAlertDB.pm b/monitoring/NPalert/test/TestAlertDB.pm
index 6d3e3f4..e74adbf 100644
--- a/monitoring/NPalert/test/TestAlertDB.pm
+++ b/monitoring/NPalert/test/TestAlertDB.pm
@@ -81,20 +81,6 @@ sub test_alert {
$self->assert($err==0,$err);
}
-############################
-sub test_create_snmp_alert {
-############################
- my $self=shift;
- my ($err)=$self->{'blah'}->dbexecute('create_snmp_alert',10068, 'dave.pc.nocpulse.net',
- 5050, '10-09-2002 20:46:23', '10-09-2002 20:46:23',
- 'Disk Space', 1, 'NOCpulse Lab', 'https://command.nocpulse.com/ocenter/?function=host&id=19231',
- 'Spacewalk','message: Filesystem /dev/hda2: Filesystem pct used 35% (above critical threshold of 20%); Space available 1,115 MB; Space used 591 MB
- Notification #1413 for Filesystem pct used',
- 20080, '192.168.0.234',1,
- 17, 1, 'VMWare4');
- $self->assert($err==0,$err);
-}
-
#######################
sub test_redirect_seq {
#######################
diff --git a/monitoring/NPalert/test/TestNotificationDB.pm b/monitoring/NPalert/test/TestNotificationDB.pm
index bb8ee53..a4d8f8e 100644
--- a/monitoring/NPalert/test/TestNotificationDB.pm
+++ b/monitoring/NPalert/test/TestNotificationDB.pm
@@ -87,44 +87,6 @@ sub test__init_details {
$self->assert($value eq 'EXPIRATION', 'dates details (redirects)');
} ## end sub test__init_details
-##################
-sub x_test__create {
-##################
- my $self = shift;
- my $records =
- $self->{'blah'}
- ->execute('select snmp_alert_recid_seq.nextval as recid from dual',
- 'dual', FETCH_ARRAYREF);
- my $recid = $records->[0]->{'RECID'};
- $Log->log(9, "\n\nrecid is $recid\n\n");
- my $record = {
- RECID => $recid,
- SENDER_CLUSTER_ID => 10068,
- DEST_IP => 'davepc.nocpulse.net',
- DEST_PORT => 5050,
- DATE_GENERATED => time(),
- DATE_SUBMITTED => 'sysdate',
- COMMAND_NAME => 'Disk Space',
- NOTIF_TYPE => '',
- OP_CENTER => 'NOCpulse Lab',
- NOTIF_URL => '',
- OS_NAME => 'Spacewalk',
- MESSAGE => 'blah diddy gorp',
- PROBE_ID => 20080,
- HOST_IP => '192.168.0.234',
- SEVERITY => 5,
- COMMAND_ID => 17,
- PROBE_CLASS => 1,
- HOST_NAME => 'VMWare4'
- };
- $self->{'blah'}->create_snmp_alert(%$record);
-
- # Can't query an active table
- # my $result=$self->{'blah'}->select_snmp_alert(RECID => $recid);
- # $self->assert(defined($result),'got something back');
- # $self->assert($result->{'DEST_PORT'} == 5050,'is the correct value');
-} ## end sub x_test__create
-
########################
sub test__selectphrase {
########################
diff --git a/schema/spacewalk/oracle/triggers/rhn_contact_methods.sql b/schema/spacewalk/oracle/triggers/rhn_contact_methods.sql
index 7dc3869..5bf5bb8 100644
--- a/schema/spacewalk/oracle/triggers/rhn_contact_methods.sql
+++ b/schema/spacewalk/oracle/triggers/rhn_contact_methods.sql
@@ -47,17 +47,6 @@ begin
end if;
end if;
- if :new.method_type_id = 5
- then
-
- --- the all sntp fields be not null
- if (:new.snmp_host is null or
- :new.snmp_port is null)
- then
- raise missing_data;
- end if;
- end if;
-
exception
when missing_data then
raise_application_error (-20012,msg);
diff --git a/schema/spacewalk/postgres/triggers/rhn_contact_methods.sql b/schema/spacewalk/postgres/triggers/rhn_contact_methods.sql
index 4c52424..9e6ed46 100644
--- a/schema/spacewalk/postgres/triggers/rhn_contact_methods.sql
+++ b/schema/spacewalk/postgres/triggers/rhn_contact_methods.sql
@@ -1,5 +1,4 @@
--- oracle equivalent source sha1 0f23a9637e54cf0141b6629baa286d23ed79f849
--- retrieved from ./1241132947/9984c41fb98d15becf3c29432c19cd7a266dece4/schema/spacewalk/oracle/triggers/rhn_contact_methods.sql
+-- oracle equivalent source sha1 e58bd36819c4101d8efbe3b8aa6b77979c277b91
create or replace function rhn_cmeth_val_trig_fun() returns trigger as
$$
begin
@@ -19,14 +18,6 @@ begin
end if;
end if;
- if new.method_type_id = 5 then
-
- --- the all sntp fields be not null
- if (new.snmp_host is null or new.snmp_port is null) then
- raise exception 'missing or invalid data for contact_methods table'; --missing_data;
- end if;
- end if;
-
return new;
end;
$$ language plpgsql;
diff --git a/schema/spacewalk/upgrade/spacewalk-schema-1.6-to-spacewalk-schema-1.7/011-rhn_contact_methods.sql.oracle b/schema/spacewalk/upgrade/spacewalk-schema-1.6-to-spacewalk-schema-1.7/011-rhn_contact_methods.sql.oracle
new file mode 100644
index 0000000..59eb704
--- /dev/null
+++ b/schema/spacewalk/upgrade/spacewalk-schema-1.6-to-spacewalk-schema-1.7/011-rhn_contact_methods.sql.oracle
@@ -0,0 +1,57 @@
+
+--
+-- Copyright (c) 2008 Red Hat, Inc.
+--
+-- This software is licensed to you under the GNU General Public License,
+-- version 2 (GPLv2). There is NO WARRANTY for this software, express or
+-- implied, including the implied warranties of MERCHANTABILITY or FITNESS
+-- FOR A PARTICULAR PURPOSE. You should have received a copy of GPLv2
+-- along with this software; if not, see
+-- http://www.gnu.org/licenses/old-licenses/gpl-2.0.txt.
+--
+-- Red Hat trademarks are not licensed under GPLv2. No permission is
+-- granted to use or replicate Red Hat trademarks that are incorporated
+-- in this software or its documentation.
+--
+
+create or replace trigger
+rhn_cmeth_val_trig
+before insert or update on rhn_contact_methods
+referencing new as new old as old
+for each row
+declare
+ msg varchar2(200);
+ missing_data exception;
+begin
+ msg :='missing or invalid data for contact_methods table';
+
+ if :new.method_type_id = 1
+ then
+
+ --- pager fields pager_email,pager_split_long_messages should be not null
+ if (
+ :new.pager_email is null or
+ :new.pager_split_long_messages is null )
+ then
+ raise missing_data;
+ end if;
+ end if;
+
+ if :new.method_type_id = 2
+ then
+
+ --- the all email fields but email_reply_to should be not null
+ if :new.email_address is null
+ then
+ raise missing_data;
+ end if;
+ end if;
+
+ exception
+ when missing_data then
+ raise_application_error (-20012,msg);
+ when others then
+ raise;
+end;
+/
+show errors
diff --git a/schema/spacewalk/upgrade/spacewalk-schema-1.6-to-spacewalk-schema-1.7/011-rhn_contact_methods.sql.postgresql b/schema/spacewalk/upgrade/spacewalk-schema-1.6-to-spacewalk-schema-1.7/011-rhn_contact_methods.sql.postgresql
new file mode 100644
index 0000000..e7d9712
--- /dev/null
+++ b/schema/spacewalk/upgrade/spacewalk-schema-1.6-to-spacewalk-schema-1.7/011-rhn_contact_methods.sql.postgresql
@@ -0,0 +1,32 @@
+-- oracle equivalent source sha1 e58bd36819c4101d8efbe3b8aa6b77979c277b91
+create or replace function rhn_cmeth_val_trig_fun() returns trigger as
+$$
+begin
+ if new.method_type_id = 1 then
+
+ --- pager fields pager_email,pager_split_long_messages should be not null
+ if (new.pager_email is null or new.pager_split_long_messages is null ) then
+ raise exception 'missing or invalid data for contact_methods table'; --missing_data;
+ end if;
+ end if;
+
+ if new.method_type_id = 2 then
+
+ --- the all email fields but email_reply_to should be not null
+ if new.email_address is null then
+ raise exception 'missing or invalid data for contact_methods table'; --missing_data;
+ end if;
+ end if;
+
+ return new;
+end;
+$$ language plpgsql;
+
+
+drop trigger if exists rhn_cmeth_val_trig on rhn_contact_methods;
+
+create trigger
+rhn_cmeth_val_trig
+before insert or update on rhn_contact_methods
+for each row
+execute procedure rhn_cmeth_val_trig_fun();
12 years, 3 months