1 package System::Introspector::Probe::FileHandles;
4 use System::Introspector::Util qw(
9 has lsof_command => (is => 'ro', default => sub { 'lsof' });
13 return transform_exceptions {
14 my @lines = lines_from_command [$self->_lsof_command_call];
16 for my $line (@lines) {
18 my @fields = split m{\0}, $line;
19 push @handles, { map {
24 return { handles => \@handles };
28 sub _lsof_command_call {
30 return $self->lsof_command, '-F0';
39 System::Introspector::Probe::FileHandles - Gather opened filehandles
43 Uses C<lsof> to build a list of open filehandles.
49 =item L<System::Introspector>
55 Copyright (c) 2012 the L<System::Introspector>
56 L<AUTHOR|System::Introspector/AUTHOR>,
57 L<CONTRIBUTORS|System::Introspector/CONTRIBUTORS> and
58 L<SPONSORS|System::Introspector/SPONSORS>.
62 This library is free software and may be distributed under the same terms