Skip Menu |

This queue is for tickets about the jmx4perl CPAN distribution.

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

People
Owner: roland [...] cpan.org
Requestors: Daniel.Schwager [...] dtnet.de
Cc:
AdminCc:

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



Subject: Featurerequest: adding attributes/path to "check_jmx4perl --mbean"
Date: Tue, 20 Oct 2009 18:07:23 +0200
To: <bug-jmx4perl [...] rt.cpan.org>
From: "Daniel Schwager" <Daniel.Schwager [...] dtnet.de>
Hi Roland, to setup some checks for nagios, we have to tell check_jmx4perl a lot of parameters inside nagios/service.cfg file. To reduce the amount of parameters, I would suggest to implement the --mbean parameter (or another new one) to use the same syntax that the current --base parameter: --base java.lang:type=Memory/HeapMemoryUsage/max So, you can remove (normly always required) two parameters from $CMD \ --name memory_used \ --mbean java.lang:type=Memory \ --attribute HeapMemoryUsage \ --path used \ --critical 10000000 --warning 5000000 to $CMD \ --name memory_used \ --mbean java.lang:type=Memory/HeapMemoryUsage/used --critical 10000000 --warning 5000000 regards Danny
On Tue Oct 20 12:07:46 2009, Daniel.Schwager@dtnet.de wrote: Show quoted text
> To reduce the amount of parameters, I would suggest to > implement the --mbean parameter (or another new one) to > use the same syntax that the current --base parameter: > --base java.lang:type=Memory/HeapMemoryUsage/max > > So, you can remove (normly always required) two parameters from > $CMD \ > --name memory_used \ > --mbean java.lang:type=Memory \ > --attribute HeapMemoryUsage \ > --path used \ > --critical 10000000 --warning 5000000 > > to > $CMD \ > --name memory_used \ > --mbean java.lang:type=Memory/HeapMemoryUsage/used > --critical 10000000 --warning 5000000
That's a nice idea, however there is still a slight problem: "/" is a valid character for an MBean name as well, so it's not that easy to distinguish which part is the MBean name and which is the atrribute/path. In so far --base is a bit flawed with this syntax, working only with MBeans with no slash, so this is a bit limited. And yes, this is not an academic discussion, e.g. Websphere use quite a bunch of MBeans, where the name contains file path elements (including slashes) ;-( So, one would have to escape the slash separator as well, but then, after all, isn't easier to specify the parts separately ? I will think about it and probably will come up with a new parameter (e.g. --value) which is uses this abbreviated syntax including some sort of escaping (which then will be added for --base as well)) thanks for your suggestion ....
On Thu Oct 22 05:56:58 2009, ROLAND wrote:

Show quoted text
> I will think about it and probably will come up with a new parameter
> (e.g. --value) which is uses this abbreviated syntax including some sort
> of escaping (which then will be added for --base as well))

Sorry, I forgot: This feature has been implemented since 0.70 (current version: 0.91 ;-), so I will
close this ticket for now.

ciao ...
... roland