Alvis-Pipeline
view release on metacpan or search on metacpan
lib/Alvis/Pipeline/Read.pm view on Meta::CPAN
my(%opts) = @_;
my $this = bless {}, $class;
$this->{spooldir} = delete $opts{spooldir}
or die "new($class) with no spooldir";
$this->{port} = delete $opts{port}
or die "new($class) with no port";
$this->_setopts(sleep => 10, %opts);
# Asynchronicity: server process accepts pushes and stores them
$this->log(1, "forking");
my $pid = fork();
die "couldn't fork: $!" if !defined $pid;
if ($pid == 0) {
# Child process
$this->_start_server();
die "_start_server() returned! It should never do that";
}
# Automatic reaper prevents the child going zombie when we kill
( run in 0.355 second using v1.01-cache-2.11-cpan-0d8aa00de5b )