Beefy Boxes and Bandwidth Generously Provided by pair Networks
Your skill will accomplish
what the force of many cannot
 
PerlMonks  

Re: Boolean Thread::Semaphore ?

by sundialsvc4 (Abbot)
on Feb 08, 2012 at 21:52 UTC ( [id://952593]=note: print w/replies, xml ) Need Help??


in reply to Boolean Thread::Semaphore ?

I agree with BrowserUK’s sentiment that a simple polling loop (with a substantial sleep() delay between each iteration, and an appropriately long or short interval) is the simplest approach in this case.   If, in actual practice, a simple poll keeps the work-to-do list reasonably full most of the time, “you’re done.”   If the feeder process “wastes” a few dozen microseconds every thousand, and in the process it avoids a more complicated timing mechanism ... so what ... it’s a “waste” that you can afford.   Even if, every now and then, “the well runs dry,” but the total waste is not a significant delay to the business operation that it supports ... you can afford the simplicity.

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others browsing the Monastery: (3)
As of 2024-04-20 01:35 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found