brian d foy > MyCPAN-Indexer-1.28 > MyCPAN::Indexer::Dispatcher::Parallel

Download:
MyCPAN-Indexer-1.28.tar.gz

Dependencies

Annotate this POD

Website

CPAN RT

New  1
Open  1
View/Report Bugs
Module Version: 1.28   Source   Latest Release: MyCPAN-Indexer-1.28_10

NAME ^

MyCPAN::Indexer::Dispatcher::Parallel - Pass out work to sub-processes

SYNOPSIS ^

Use this in backpan_indexer.pl by specifying it as the queue class:

        # in backpan_indexer.config
        dispatch_class  MyCPAN::Indexer::Dispatcher::Parallel

DESCRIPTION ^

This class takes the list of distributions to process and passes them out to the code that will do the work.

Methods

get_dispatcher

Takes the $Notes hash and adds the dispatcher key with a code reference. This module uses Parallel::ForkManager to run jobs in parallel, and looks at the

It also sets up keys for PID, whose value is an anonymous array of process IDs. That array matches up with the one in the key recent which keeps track of the distributions it's processing. It adds:

        dispatcher => sub { ... },
        PID        => [],
        recent     => [],

SEE ALSO ^

MyCPAN::Indexer, MyCPAN::Indexer::Tutorial

SOURCE AVAILABILITY ^

This code is in Github:

        git://github.com/briandfoy/mycpan-indexer.git

AUTHOR ^

brian d foy, <bdfoy@cpan.org>

COPYRIGHT AND LICENSE ^

Copyright (c) 2008-2009, brian d foy, All Rights Reserved.

You may redistribute this under the same terms as Perl itself.

syntax highlighting: