summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: a95e255)
raw | patch | inline | side by side (parent: a95e255)
author | Sebastian Harl <sh@tokkee.org> | |
Sat, 23 Jan 2010 22:54:07 +0000 (23:54 +0100) | ||
committer | Sebastian Harl <sh@tokkee.org> | |
Sat, 23 Jan 2010 22:54:07 +0000 (23:54 +0100) |
This patch adds the ability to hide specified types in collection.cgi.
Thanks to Pavel Piatruk for the patch!
Closes: #566199
Thanks to Pavel Piatruk for the patch!
Closes: #566199
debian/changelog | patch | blob | history | |
debian/patches/00list | patch | blob | history | |
debian/patches/bts559801_plugin_find_fix.dpatch | [changed mode: 0644->0755] | patch | blob | history |
debian/patches/bts566199_collection_hide_types.dpatch | [new file with mode: 0755] | patch | blob |
diff --git a/debian/changelog b/debian/changelog
index 02e4e3dd3dbdc9e279440d3aa83bbdbd331972f8..201cdc843e14cab493dd9f36a9b2623385a3113b 100644 (file)
--- a/debian/changelog
+++ b/debian/changelog
vmem, vserver, wireless.
- Simplified Java archdir mapping: removed entries "pointing" to
themselves and let those default to DEB_BUILD_ARCH.
+ * debian/patches:
+ - Added bts566199_collection_hide_types.dpatch -- added ability to hide
+ specified types in collection.cgi; thanks to Pavel Piatruk for the patch
+ (Closes: #566199).
- -- Sebastian Harl <tokkee@debian.org> Sat, 23 Jan 2010 23:42:50 +0100
+ -- Sebastian Harl <tokkee@debian.org> Sat, 23 Jan 2010 23:52:06 +0100
collectd (4.8.2-1) unstable; urgency=medium
diff --git a/debian/patches/00list b/debian/patches/00list
index c3fbc669cff660a94d434366b72ac79e8afdbc49..9f9026b1466fbc97e1debae71c6aeb44c7e1a9a1 100644 (file)
--- a/debian/patches/00list
+++ b/debian/patches/00list
bts561577_collectd2html_recursive_fix.dpatch
bts557599_powerdns_fix.dpatch
bts559801_plugin_find_fix.dpatch
+bts566199_collection_hide_types.dpatch
diff --git a/debian/patches/bts559801_plugin_find_fix.dpatch b/debian/patches/bts559801_plugin_find_fix.dpatch
old mode 100644 (file)
new mode 100755 (executable)
new mode 100755 (executable)
diff --git a/debian/patches/bts566199_collection_hide_types.dpatch b/debian/patches/bts566199_collection_hide_types.dpatch
--- /dev/null
@@ -0,0 +1,36 @@
+#! /bin/sh /usr/share/dpatch/dpatch-run
+## bts566199_collection_hide_types.dpatch by Pavel Piatruk
+## <piatruk.p@gmail.com>
+##
+## DP: contrib/collection.cgi: Added ability to hide specified types.
+
+diff a/contrib/collection.cgi b/contrib/collection.cgi
+--- a/contrib/collection.cgi
++++ b/contrib/collection.cgi
+@@ -13,6 +13,7 @@ use Data::Dumper ();
+
+ our $Config = "/etc/collection.conf";
+ our @DataDirs = ();
++our @DontShowTypes = ();
+ our $LibDir;
+
+ our $ValidTimespan =
+@@ -78,6 +79,10 @@ sub read_config
+ $value =~ s#/*$##;
+ $LibDir = $value;
+ }
++ elsif ($key eq 'dontshowtype')
++ {
++ push (@DontShowTypes, $value);
++ }
+ else
+ {
+ print STDERR "Unknown key: $key\n";
+@@ -239,6 +244,7 @@ sub _find_types
+ my $name = "$_";
+ $name =~ s/\.rrd$//i;
+ my ($type, $instance) = split (m/-/, $name, 2);
++ if (grep { $_ eq $type } @DontShowTypes) { next; }
+ $types{$type} = [] if (!$types{$type});
+ push (@{$types{$type}}, $instance) if (defined ($instance));
+ }