Jmx4Perl/Product/Jonas.pm

filter: Statementstmt 68.1% 15 / 22 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 54.5% 6 / 11 Podpod 100% 7 / 7 totaltotal 70.0% 28 / 40 CC 1 SCAR 3.7
CC
1
Cov
68%
name
2.0
autodetect_pattern
2.0
server_info
2.0
CRAP 1.5
« Jmx4Perl/Alias/Object.pm ↑ Summary Jmx4Perl/Product/Websphere.pm »
1 #!/usr/bin/perl
2 package JMX::Jmx4Perl::Product::Jonas;
3  
4 4 ▶use JMX::Jmx4Perl::Product::BaseHandler;
Subroutine BEGIN: called CC=1 SCAR=0.0
5 4 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
6 4 ▶use base "JMX::Jmx4Perl::Product::BaseHandler";
Subroutine BEGIN: called CC=1 SCAR=0.0
7  
8 4 ▶use Carp qw(croak);
Subroutine BEGIN: called CC=1 SCAR=0.0
9  
10 =head1 NAME
11  
12 JMX::Jmx4Perl::Product::Jonas - Handler for Jonas
13  
14 =head1 DESCRIPTION
15  
16 This is the product handler support Jonas 4 and 5 (L<http://jonas.ow2.org/>)
17  
18 =cut
19  
20 4 ▶sub id {
Subroutine id: called CC=1 SCAR=0.0
Pod documented
21 4 return "jonas";
22 }
23  
24 0 ▶sub name {
Subroutine name: not called CC=1 SCAR=6.9
Pod documented
25 0 return "Jonas";
26 }
27  
28 4 ▶sub order {
Subroutine order: called CC=1 SCAR=0.0
Pod documented
29 4 return 10;
30 }
31  
32 0 ▶sub autodetect_pattern {
Subroutine autodetect_pattern: not called CC=1 SCAR=6.9
Pod documented
33 0 return ("vendor",qr/OW2/i);
34 }
35  
36 0 ▶sub server_info {
Subroutine server_info: not called CC=1 SCAR=6.9
Pod documented
37 0 my $self = shift;
38 0 my $ret = $self->SUPER::server_info();
39 0 $ret .= sprintf("%-10.10s %s\n","Web:",$self->{jmx4perl}->get_attribute("jonas:name=webContainers,type=service","ServerName"));
40 }
41  
42 0 ▶sub jsr77 {
Subroutine jsr77: not called CC=1 SCAR=6.9
Pod documented
43 0 return 1;
44 }
45  
46 0 ▶sub init_aliases {
Subroutine init_aliases: not called CC=1 SCAR=6.9
Pod documented
47 return
48 {
49 0 attributes =>
50 {
51 #SERVER_ADDRESS => [ "jboss.system:type=ServerInfo", "HostAddress"],
52 #SERVER_HOSTNAME => [ "jonas:name=jonas,type=ServerProxy", "HostName"],
53 },
54 operations =>
55 {
56 #THREAD_DUMP => [ "jboss.system:type=ServerInfo", "listThreadDump"]
57 }
58 # Alias => [ "mbean", "attribute", "path" ]
59 };
60 }
61  
62  
63 =head1 LICENSE
64  
65 This file is part of jmx4perl.
66  
67 Jmx4perl is free software: you can redistribute it and/or modify
68 it under the terms of the GNU General Public License as published by
69 the Free Software Foundation, either version 2 of the License, or
70 (at your option) any later version.
71  
72 jmx4perl is distributed in the hope that it will be useful,
73 but WITHOUT ANY WARRANTY; without even the implied warranty of
74 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
75 GNU General Public License for more details.
76  
77 You should have received a copy of the GNU General Public License
78 along with jmx4perl. If not, see <http://www.gnu.org/licenses/>.
79  
80 A commercial license is available as well. Please contact roland@cpan.org for
81 further details.
82  
83 =head1 AUTHOR
84  
85 roland@cpan.org
86  
87 =cut
88  
89 4 1;
« Jmx4Perl/Alias/Object.pm ↑ Summary Jmx4Perl/Product/Websphere.pm »