Beefy Boxes and Bandwidth Generously Provided by pair Networks
Think about Loose Coupling
 
PerlMonks  

Re: Parallel::Runner and Amazon SQS Issue

by runrig (Abbot)
on Sep 13, 2012 at 17:06 UTC ( #993536=note: print w/ replies, xml ) Need Help??


in reply to Parallel::Runner and Amazon SQS Issue

Seeing as how this is probably a one-shot, I might just select data in the main loop, and feed it to Amazon in parallel processes. It shouldn't take ALL that long to select 70G of data. The bottleneck, I would think, would be the Amazon request. Something like:

while ( my $records = fetch_next_5000_records_from_sth() ) { $runner->run( ..feed records to Amazon... ); )

Update: And it looks like you really only feed one record at a time to the web service, so it might as well be:

while ( my $record = $sth->fetch() ) { $runner->run(... feed record to service ...); }


Comment on Re: Parallel::Runner and Amazon SQS Issue
Select or Download Code
Re^2: Parallel::Runner and Amazon SQS Issue
by stonecolddevin (Vicar) on Sep 13, 2012 at 18:45 UTC

    Hmmm good point. I've implemented this and unless something explodes, all looks like it's going according to plan. Thanks runrig!

    Three thousand years of beautiful tradition, from Moses to Sandy Koufax, you're god damn right I'm living in the fucking past

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://993536]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others avoiding work at the Monastery: (9)
As of 2014-08-29 19:06 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The best computer themed movie is:











    Results (287 votes), past polls