Beefy Boxes and Bandwidth Generously Provided by pair Networks
laziness, impatience, and hubris
 
PerlMonks  

Re: How to pause multithreaded application?

by zentara (Archbishop)
on Sep 14, 2010 at 10:22 UTC ( #860089=note: print w/ replies, xml ) Need Help??


in reply to How to pause multithreaded application?

So i have one problem: how to pause all running threads (and continue them after some user actions

I would think you would need to create a shared variable, which all threads monitor in their code, to instruct the threads to keep working, or go into a looping sleep state. It would require you to rewrite your thread code to use a more manual style, rather than queue. See Reusable threads demo for an example of "go control"


I'm not really a human, but I play one on earth.
Old Perl Programmer Haiku ................... flash japh


Comment on Re: How to pause multithreaded application?

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others perusing the Monastery: (12)
As of 2015-07-31 16:28 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (279 votes), past polls