Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW
 
PerlMonks  

Search for module helping to spawn a filter like child process

by McA (Curate)
on Mar 05, 2013 at 09:23 UTC ( #1021779=perlquestion: print w/ replies, xml ) Need Help??
McA has asked for the wisdom of the Perl Monks concerning the following question:

Hi all,

I want to spawn 1..n child processes in a way that the STDIN of the child is connected to one pipe file handle of the parent (writing to the child) and the STDOUT of the child is connected to a file handle of the parent talking results to the parent.

Is there a package out there supporting this kind of spawning and communicating. I know that you have to be careful not to get a deadlock with this kind of communication.

Backround for other solutions: I want to implement a process which grabs job tickets from database and dispatches them to 1..n worker scripts and then collecting the results. Probably there is also a ready to use solution out there.

Best regards
McA

Comment on Search for module helping to spawn a filter like child process
Re: Search for module helping to spawn a filter like child process
by kielstirling (Scribe) on Mar 05, 2013 at 09:32 UTC
    Look at IO::Pipe.
Re: Search for module helping to spawn a filter like child process
by McA (Curate) on Mar 06, 2013 at 07:32 UTC

    Good morning,

    really no other advices, hints how to solve such a batch job queue with several workers?.

    Nice day
    McA

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: perlquestion [id://1021779]
Front-paged by Arunbear
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others scrutinizing the Monastery: (6)
As of 2014-09-18 22:40 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    How do you remember the number of days in each month?











    Results (126 votes), past polls