line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Proc::Launcher::Supervisor; |
2
|
3
|
|
|
3
|
|
17
|
use strict; |
|
3
|
|
|
|
|
5
|
|
|
3
|
|
|
|
|
116
|
|
3
|
3
|
|
|
3
|
|
15
|
use warnings; |
|
3
|
|
|
|
|
4
|
|
|
3
|
|
|
|
|
137
|
|
4
|
|
|
|
|
|
|
|
5
|
|
|
|
|
|
|
our $VERSION = '0.0.35'; # VERSION |
6
|
|
|
|
|
|
|
|
7
|
3
|
|
|
3
|
|
13
|
use Mouse; |
|
3
|
|
|
|
|
6
|
|
|
3
|
|
|
|
|
16
|
|
8
|
|
|
|
|
|
|
|
9
|
|
|
|
|
|
|
has 'monitor_delay' => ( is => 'rw', |
10
|
|
|
|
|
|
|
isa => 'Int', |
11
|
|
|
|
|
|
|
default => 15, |
12
|
|
|
|
|
|
|
); |
13
|
|
|
|
|
|
|
|
14
|
|
|
|
|
|
|
has 'manager' => ( is => 'rw', |
15
|
|
|
|
|
|
|
isa => 'Proc::Launcher::Manager', |
16
|
|
|
|
|
|
|
required => 1, |
17
|
|
|
|
|
|
|
); |
18
|
|
|
|
|
|
|
|
19
|
|
|
|
|
|
|
sub monitor { |
20
|
0
|
|
|
0
|
1
|
|
my ( $self ) = @_; |
21
|
|
|
|
|
|
|
|
22
|
0
|
|
|
|
|
|
sleep 5; |
23
|
|
|
|
|
|
|
|
24
|
0
|
|
|
|
|
|
while ( 1 ) { |
25
|
0
|
|
|
|
|
|
$self->manager->start(); |
26
|
0
|
|
|
|
|
|
sleep $self->monitor_delay; |
27
|
|
|
|
|
|
|
} |
28
|
|
|
|
|
|
|
} |
29
|
|
|
|
|
|
|
|
30
|
3
|
|
|
3
|
|
1181
|
no Mouse; |
|
3
|
|
|
|
|
6
|
|
|
3
|
|
|
|
|
13
|
|
31
|
|
|
|
|
|
|
|
32
|
|
|
|
|
|
|
1; |
33
|
|
|
|
|
|
|
|
34
|
|
|
|
|
|
|
__END__ |