File Coverage

blib/lib/JMX/Jmx4Perl/Product/ActiveMQ.pm
Criterion Covered Total %
statement 17 25 68.0
branch n/a
condition n/a
subroutine 7 12 58.3
pod 6 6 100.0
total 30 43 69.7


line stmt bran cond sub pod time code
1             #!/usr/bin/perl
2             package JMX::Jmx4Perl::Product::ActiveMQ;
3              
4 4     4   30 use JMX::Jmx4Perl::Product::BaseHandler;
  4         9  
  4         115  
5 4     4   21 use strict;
  4         8  
  4         106  
6 4     4   30 use base "JMX::Jmx4Perl::Product::BaseHandler";
  4         10  
  4         347  
7 4     4   52 use Data::Dumper;
  4         19  
  4         248  
8              
9 4     4   27 use Carp qw(croak);
  4         8  
  4         807  
10              
11             =head1 NAME
12              
13             JMX::Jmx4Perl::Product::ActiveMQ - Handler for Jonas
14              
15             =head1 DESCRIPTION
16              
17             This is the product handler support for ActiveMQ
18             (L) which works with the JVM Agent provided for
19             Sun JDK 6 based applications
20              
21             =cut
22              
23             sub id {
24 4     4 1 29 return "activemq";
25             }
26              
27             sub name {
28 0     0 1 0 return "ActiveMQ";
29             }
30              
31             sub vendor {
32 0     0 1 0 return "Apache";
33             }
34              
35             sub version {
36             # No way to detect version until yet.
37 0     0 1 0 return "";
38             }
39             sub order {
40 4     4 1 18 return 200;
41             }
42              
43             sub autodetect_pattern {
44             return sub {
45 0     0     my $self = shift;
46 0           my $j4p = $self->{jmx4perl};
47 0           my $ret = $j4p->search("org.apache.activemq:*");
48             #print Dumper($ret);
49 0           return $ret;
50 0     0 1   };
51             }
52              
53             =head1 LICENSE
54              
55             This file is part of jmx4perl.
56              
57             Jmx4perl is free software: you can redistribute it and/or modify
58             it under the terms of the GNU General Public License as published by
59             the Free Software Foundation, either version 2 of the License, or
60             (at your option) any later version.
61              
62             jmx4perl is distributed in the hope that it will be useful,
63             but WITHOUT ANY WARRANTY; without even the implied warranty of
64             MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
65             GNU General Public License for more details.
66              
67             You should have received a copy of the GNU General Public License
68             along with jmx4perl. If not, see .
69              
70             A commercial license is available as well. Please contact roland@cpan.org for
71             further details.
72              
73             =head1 AUTHOR
74              
75             roland@cpan.org
76              
77             =cut
78              
79             1;