| blib/lib/App/RedisTop/Component/Connection.pm | |||
|---|---|---|---|
| Criterion | Covered | Total | % | 
| statement | 5 | 5 | 100.0 | 
| branch | n/a | ||
| condition | n/a | ||
| subroutine | 2 | 2 | 100.0 | 
| pod | 0 | 1 | 0.0 | 
| total | 7 | 8 | 87.5 | 
| line | stmt | bran | cond | sub | pod | time | code | 
|---|---|---|---|---|---|---|---|
| 1 | package App::RedisTop::Component::Connection; | ||||||
| 2 | 2 | 2 | 1444 | use base 'App::RedisTop::Component'; | |||
| 2 | 3 | ||||||
| 2 | 248 | ||||||
| 3 | sub new { | ||||||
| 4 | 1 | 1 | 0 | 2 | my $class = shift; | ||
| 5 | |||||||
| 6 | 1 | 20 | my $self = bless { | ||||
| 7 | group => 'conn', | ||||||
| 8 | items => [ | ||||||
| 9 | { name => 'total/s', stat_key => 'total_connections_received', diff => 1 }, | ||||||
| 10 | { name => 'clients', stat_key => 'connected_clients', }, | ||||||
| 11 | ], | ||||||
| 12 | width => 9, | ||||||
| 13 | unit => 1, | ||||||
| 14 | total => 1, | ||||||
| 15 | @_, | ||||||
| 16 | }, $class; | ||||||
| 17 | } | ||||||
| 18 | |||||||
| 19 | 1; |