Skip Menu |

This queue is for tickets about the jmx4perl CPAN distribution.

Report information
The Basics
Id: 75062
Status: resolved
Priority: 0/
Queue: jmx4perl

People
Owner: Nobody in particular
Requestors: work [...] paul.dubuc.org
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



Subject: New Feature: make performance data optional for check_jmx4perl
Date: Thu, 16 Feb 2012 11:05:33 -0500
To: Roland Huss via RT <bug-jmx4perl [...] rt.cpan.org>
From: "Paul M. Dubuc" <work [...] paul.dubuc.org>
A great feature of the check_jmx4perl plugin is the use of Multichecks. Multiple checks can be done with one run of the plugin and status and alerting is done for all at once. Performance data is also output for each check. I think there should be some way to specify in the Check configuration that the performance data not be output. This is so that data collection and graphing utilities will not collect and try to store graph unwanted data. Not all performance data is equally valuable like thread deadlock checks or other binary failure conditions but the plugin prints performance data for all. One good way to implement this feature might be to set the "Name" of the performance data to some value like "__NONE__" to specify that no performance data should be output for the check. I am using jmx4perl 0.91 with perl 5.10.0. on SuSE Linux: Linux mrldev36 2.6.32.46-0.3-default #1 SMP 2011-09-29 17:49:31 +0200 x86_64 x86_64 x86_64 GNU/Linux Thank you, Paul Dubuc
You are right, this sounds like a useful addition. There will be probably a 'NoPerformanceData' directive or so for single checks (or as you suggest a specific label value for indicating to skip performance data which would have the advantage that it can be used with placeholders).

I will consider this for 1.0.5

Thanks ....
... roland
On Thu Feb 16 11:05:50 2012, PMDubuc wrote:
Show quoted text
> A great feature of the check_jmx4perl plugin is the use of
> Multichecks.
> Multiple checks can be done with one run of the plugin and status and
> alerting
> is done for all at once. Performance data is also output for each
> check. I
> think there should be some way to specify in the Check configuration
> that the
> performance data not be output. This is so that data collection and
> graphing
> utilities will not collect and try to store graph unwanted data. Not
> all
> performance data is equally valuable like thread deadlock checks or
> other
> binary failure conditions but the plugin prints performance data for
> all.
>
> One good way to implement this feature might be to set the "Name" of
> the
> performance data to some value like "__NONE__" to specify that no
> performance
> data should be output for the check.
>
> I am using jmx4perl 0.91 with perl 5.10.0. on SuSE Linux:
> Linux mrldev36 2.6.32.46-0.3-default #1 SMP 2011-09-29 17:49:31 +0200
> x86_64
> x86_64 x86_64 GNU/Linux
>
> Thank you,
> Paul Dubuc


Subject: Re: [rt.cpan.org #75062] New Feature: make performance data optional for check_jmx4perl
Date: Fri, 17 Feb 2012 08:33:09 -0500
To: bug-jmx4perl [...] rt.cpan.org
From: "Paul M. Dubuc" <work [...] paul.dubuc.org>
Roland, thank you very much! Paul Roland Huss via RT wrote: Show quoted text
> <URL: https://rt.cpan.org/Ticket/Display.html?id=75062> > > You are right, this sounds like a useful addition. There will be probably a > 'NoPerformanceData' directive or so for single checks (or as you suggest a > specific label value for indicating to skip performance data which would have > the advantage that it can be used with placeholders). > > I will consider this for 1.0.5 > > Thanks .... > ... roland > On Thu Feb 16 11:05:50 2012, PMDubuc wrote:
>> A great feature of the check_jmx4perl plugin is the use of >> Multichecks. >> Multiple checks can be done with one run of the plugin and status and >> alerting >> is done for all at once. Performance data is also output for each >> check. I >> think there should be some way to specify in the Check configuration >> that the >> performance data not be output. This is so that data collection and >> graphing >> utilities will not collect and try to store graph unwanted data. Not >> all >> performance data is equally valuable like thread deadlock checks or >> other >> binary failure conditions but the plugin prints performance data for >> all. >> >> One good way to implement this feature might be to set the "Name" of >> the >> performance data to some value like "__NONE__" to specify that no >> performance >> data should be output for the check. >> >> I am using jmx4perl 0.91 with perl 5.10.0. on SuSE Linux: >> Linux mrldev36 2.6.32.46-0.3-default #1 SMP 2011-09-29 17:49:31 +0200 >> x86_64 >> x86_64 x86_64 GNU/Linux >> >> Thank you, >> Paul Dubuc
>
Subject: Re: [rt.cpan.org #75062] New Feature: make performance data optional for check_jmx4perl
Date: Mon, 20 Feb 2012 12:38:22 -0500
To: bug-jmx4perl [...] rt.cpan.org
From: "Paul M. Dubuc" <work [...] paul.dubuc.org>
Roland Huss via RT wrote: Show quoted text
> <URL: https://rt.cpan.org/Ticket/Display.html?id=75062> > > You are right, this sounds like a useful addition. There will be probably a > 'NoPerformanceData' directive or so for single checks (or as you suggest a > specific label value for indicating to skip performance data which would have > the advantage that it can be used with placeholders). > > I will consider this for 1.0.5 > > Thanks .... > ... roland
Hello Roland, I was wondering what are placeholders? I don't see anything about them in the 0.91 documentation. If it means that something will be output in the performance data in place of what the check would normally put there, then it might cause problems for graphing programs that parse the data. I am sure that PNP4Nagios would probably have a problem with it. Right now it has a problem with values in the performance data that are not numerical. For example the thread_deadlock check defined in threads.cfg gives the performance data: Thread-Deadlock=no deadlock;;!no deadlock PNP4Nagios will not parse this because it expects only numerical values for performance data. In fact, it will throw away performance data for all checks if it finds one in the list that is considered 'invalid'. It is also not possible to filter out and unwanted performance data with PNP4Nagios. It will try to store and graph everything that is output. (See discussion here for details: http://sourceforge.net/mailarchive/forum.php?set=custom&viewmonth=201202&viewday=0&forum_name=pnp4nagios-users&style=nested&max_rows=75&submit=Change+View). Thanks, Paul
Subject: Re: [rt.cpan.org #75062] New Feature: make performance data optional for check_jmx4perl
Date: Thu, 02 Aug 2012 11:53:24 -0400
To: bug-jmx4perl [...] rt.cpan.org
From: Paul Dubuc <work [...] paul.dubuc.org>
Roland, I made a small change to SingleCheck.pm of version 0.91 to implement this feature and it has been working fine. Here is the diff: 161c161,162 < $np->add_perfdata(label => $label,value => $value, --- Show quoted text
> if ( $label ne "__NONE__" ) { > $np->add_perfdata(label => $label,value => $value,
164a166 Show quoted text
> }
175c177,178 < $np->add_perfdata(label => $label, --- Show quoted text
> if ( $label ne "__NONE__" ) { > $np->add_perfdata(label => $label,
177a181 Show quoted text
> }
If you choose to do it a different way in the next version, I will change my configs. But I would like to upgrade to the latest jmx4perl so we can use the newer version of jolokia. Thanks, Paul Dubuc Roland Huss via RT wrote: Show quoted text
> <URL: https://rt.cpan.org/Ticket/Display.html?id=75062 > > > You are right, this sounds like a useful addition. There will be probably a > 'NoPerformanceData' directive or so for single checks (or as you suggest a > specific label value for indicating to skip performance data which would have > the advantage that it can be used with placeholders). > > I will consider this for 1.0.5 > > Thanks .... > ... roland > On Thu Feb 16 11:05:50 2012, PMDubuc wrote:
>> A great feature of the check_jmx4perl plugin is the use of >> Multichecks. >> Multiple checks can be done with one run of the plugin and status and >> alerting >> is done for all at once. Performance data is also output for each >> check. I >> think there should be some way to specify in the Check configuration >> that the >> performance data not be output. This is so that data collection and >> graphing >> utilities will not collect and try to store graph unwanted data. Not >> all >> performance data is equally valuable like thread deadlock checks or >> other >> binary failure conditions but the plugin prints performance data for >> all. >> >> One good way to implement this feature might be to set the "Name" of >> the >> performance data to some value like "__NONE__" to specify that no >> performance >> data should be output for the check. >> >> I am using jmx4perl 0.91 with perl 5.10.0. on SuSE Linux: >> Linux mrldev36 2.6.32.46-0.3-default #1 SMP 2011-09-29 17:49:31 +0200 >> x86_64 >> x86_64 x86_64 GNU/Linux >> >> Thank you, >> Paul Dubuc
>
Subject: Re: [rt.cpan.org #75062] New Feature: make performance data optional for check_jmx4perl
Date: Thu, 01 Nov 2012 16:43:26 -0400
To: bug-jmx4perl [...] rt.cpan.org
From: Paul Dubuc <work [...] paul.dubuc.org>
Hello Roland, Is there a new way to specify no performance data output in version 1.06? I'm testing that version. I tried adding this change that I used in version 0.91 and it works but the label "__NONE__" is also printed on the plugin output line for the check when there is an error. So this is not a good solution anymore. Thanks, Paul Dubuc Paul Dubuc wrote: Show quoted text
> Roland, > I made a small change to SingleCheck.pm of version 0.91 to implement this > feature and it has been working fine. Here is the diff: > > 161c161,162 > < $np->add_perfdata(label => $label,value => $value, > ---
> > if ( $label ne "__NONE__" ) { > > $np->add_perfdata(label => $label,value => $value,
> 164a166
> > }
> 175c177,178 > < $np->add_perfdata(label => $label, > ---
> > if ( $label ne "__NONE__" ) { > > $np->add_perfdata(label => $label,
> 177a181
> > }
> > If you choose to do it a different way in the next version, I will change my > configs. But I would like to upgrade to the latest jmx4perl so we can use the > newer version of jolokia. > > Thanks, > Paul Dubuc > > Roland Huss via RT wrote:
>> <URL: https://rt.cpan.org/Ticket/Display.html?id=75062 > >> >> You are right, this sounds like a useful addition. There will be probably a >> 'NoPerformanceData' directive or so for single checks (or as you suggest a >> specific label value for indicating to skip performance data which would have >> the advantage that it can be used with placeholders). >> >> I will consider this for 1.0.5 >> >> Thanks .... >> ... roland >> On Thu Feb 16 11:05:50 2012, PMDubuc wrote:
>>> A great feature of the check_jmx4perl plugin is the use of >>> Multichecks. >>> Multiple checks can be done with one run of the plugin and status and >>> alerting >>> is done for all at once. Performance data is also output for each >>> check. I >>> think there should be some way to specify in the Check configuration >>> that the >>> performance data not be output. This is so that data collection and >>> graphing >>> utilities will not collect and try to store graph unwanted data. Not >>> all >>> performance data is equally valuable like thread deadlock checks or >>> other >>> binary failure conditions but the plugin prints performance data for >>> all. >>> >>> One good way to implement this feature might be to set the "Name" of >>> the >>> performance data to some value like "__NONE__" to specify that no >>> performance >>> data should be output for the check. >>> >>> I am using jmx4perl 0.91 with perl 5.10.0. on SuSE Linux: >>> Linux mrldev36 2.6.32.46-0.3-default #1 SMP 2011-09-29 17:49:31 +0200 >>> x86_64 >>> x86_64 x86_64 GNU/Linux >>> >>> Thank you, >>> Paul Dubuc
>>
>
Subject: Re: [rt.cpan.org #75062] New Feature: make performance data optional for check_jmx4perl
Date: Fri, 02 Nov 2012 14:47:39 -0400
To: bug-jmx4perl [...] rt.cpan.org
From: Paul Dubuc <work [...] paul.dubuc.org>
I have it working again for version 1.06. Here is my new 'diff -u' --- SingleCheck.pm.old 2012-11-02 14:35:31.000000000 -0400 +++ SingleCheck.pm.new 2012-11-02 14:39:38.000000000 -0400 @@ -194,10 +194,12 @@ # Performance data. Convert to absolute values before my ($critical,$warning) = $self->_convert_relative_to_absolute($base_value,$self->critical,$self->warning); - $np->add_perfdata(label => $label,value => $value, + if ( $label ne "__NONE__" ) { + $np->add_perfdata(label => $label,value => $value, critical => $critical,warning => $warning, min => 0,max => $base_value, $self->unit ? (uom => $self->unit) : ()); + } # Do the real check. my ($code,$mode) = $self->_check_threshold($rel_value); # For Multichecks, we remember the label of a currently failed check @@ -209,9 +211,11 @@ } else { # Performance data $value = $self->_sanitize_value($value); - $np->add_perfdata(label => $label, + if ( $label ne "__NONE__" ) { + $np->add_perfdata(label => $label, critical => $self->critical, warning => $self->warning, value => $value,$self->unit ? (uom => $self->unit) : ()); + } # Do the real check. my ($code,$mode) = $self->_check_threshold($value); @@ -228,6 +232,7 @@ my $code = shift; my $label = $self->{config}->{name} || $self->{config}->{key}; + if ($label eq "__NONE__") { $label = $self->{config}->{key}; } if ($label) { my $arr = $error_stat->{$code} || []; push @$arr,$label; Paul Dubuc wrote: Show quoted text
> Hello Roland, > Is there a new way to specify no performance data output in version 1.06? I'm > testing that version. I tried adding this change that I used in version 0.91 > and it works but the label "__NONE__" is also printed on the plugin (status line) output > line for the check when there is an error. So this is not a good solution > anymore. > > Thanks, > Paul Dubuc > > Paul Dubuc wrote:
>> Roland, >> I made a small change to SingleCheck.pm of version 0.91 to implement this >> feature and it has been working fine. Here is the diff: >> >> 161c161,162 >> < $np->add_perfdata(label => $label,value => $value, >> ---
>> > if ( $label ne "__NONE__" ) { >> > $np->add_perfdata(label => $label,value => $value,
>> 164a166
>> > }
>> 175c177,178 >> < $np->add_perfdata(label => $label, >> ---
>> > if ( $label ne "__NONE__" ) { >> > $np->add_perfdata(label => $label,
>> 177a181
>> > }
>> >> If you choose to do it a different way in the next version, I will change my >> configs. But I would like to upgrade to the latest jmx4perl so we can use the >> newer version of jolokia. >> >> Thanks, >> Paul Dubuc >> >> Roland Huss via RT wrote:
>>> <URL: https://rt.cpan.org/Ticket/Display.html?id=75062 > >>> >>> You are right, this sounds like a useful addition. There will be probably a >>> 'NoPerformanceData' directive or so for single checks (or as you suggest a >>> specific label value for indicating to skip performance data which would have >>> the advantage that it can be used with placeholders). >>> >>> I will consider this for 1.0.5 >>> >>> Thanks .... >>> ... roland >>> On Thu Feb 16 11:05:50 2012, PMDubuc wrote:
>>>> A great feature of the check_jmx4perl plugin is the use of >>>> Multichecks. >>>> Multiple checks can be done with one run of the plugin and status and >>>> alerting >>>> is done for all at once. Performance data is also output for each >>>> check. I >>>> think there should be some way to specify in the Check configuration >>>> that the >>>> performance data not be output. This is so that data collection and >>>> graphing >>>> utilities will not collect and try to store graph unwanted data. Not >>>> all >>>> performance data is equally valuable like thread deadlock checks or >>>> other >>>> binary failure conditions but the plugin prints performance data for >>>> all. >>>> >>>> One good way to implement this feature might be to set the "Name" of >>>> the >>>> performance data to some value like "__NONE__" to specify that no >>>> performance >>>> data should be output for the check. >>>> >>>> I am using jmx4perl 0.91 with perl 5.10.0. on SuSE Linux: >>>> Linux mrldev36 2.6.32.46-0.3-default #1 SMP 2011-09-29 17:49:31 +0200 >>>> x86_64 >>>> x86_64 x86_64 GNU/Linux >>>> >>>> Thank you, >>>> Paul Dubuc
>>>
>>
>
Sorry Paul, I missed that feature for the latest release. I will add it to 1.07 ASAP in the one way or the other.
Sorry for the long delay, I just released 1.07 with the following new features:

* For 'string' checks, no performance data is added by default now
* For numeric checks you can omit adding performance data by using a config directive 'PerfData off' (or as argument: --perfdata off)
* If you add "PerfData %" for relative checks, the relative values (in percent) are used in the performance data instead of the absolute values.

I hope, this works for you as expected and again, sorry for the long time it took to include it.

I'll close this ticket, please feel free to open a new one if something broke (preferable over there at Github https://github.com/rhuss/jmx4perl/issues )
Subject: Re: [rt.cpan.org #75062] New Feature: make performance data optional for check_jmx4perl
Date: Tue, 16 Apr 2013 10:53:57 -0400
To: bug-jmx4perl [...] rt.cpan.org
From: Paul Dubuc <work [...] paul.dubuc.org>
Roland Huss via RT wrote: Show quoted text
> <URL: https://rt.cpan.org/Ticket/Display.html?id=75062 > > > Sorry for the long delay, I just released 1.07 with the following new features: > > * For 'string' checks, no performance data is added by default now > * For numeric checks you can omit adding performance data by using a config > directive 'PerfData off' (or as argument: --perfdata off) > * If you add "PerfData %" for relative checks, the relative values (in percent) > are used in the performance data instead of the absolute values. > > I hope, this works for you as expected and again, sorry for the long time it > took to include it. > > I'll close this ticket, please feel free to open a new one if something broke > (preferable over there at Github https://github.com/rhuss/jmx4perl/issues ) >
Thank you! I will try it next time we do an upgrade.
Subject: Re: [rt.cpan.org #75062] New Feature: make performance data optional for check_jmx4perl
Date: Thu, 27 Jun 2013 15:33:13 -0400
To: bug-jmx4perl [...] rt.cpan.org
From: Paul Dubuc <work [...] paul.dubuc.org>
Roland Huss via RT wrote: Show quoted text
> <URL: https://rt.cpan.org/Ticket/Display.html?id=75062 > > > Sorry for the long delay, I just released 1.07 with the following new features: > > * For 'string' checks, no performance data is added by default now > * For numeric checks you can omit adding performance data by using a config > directive 'PerfData off' (or as argument: --perfdata off) > * If you add "PerfData %" for relative checks, the relative values (in percent) > are used in the performance data instead of the absolute values. > > I hope, this works for you as expected and again, sorry for the long time it > took to include it. > > I'll close this ticket, please feel free to open a new one if something broke > (preferable over there at Github https://github.com/rhuss/jmx4perl/issues ) >
I'm testing this feature now and it works very well. Thank you very much! Great work!