Re: How to get rid of the delay after the real work is done?
Michael Lackhoff <[email protected]>
| Newsgroups | gmane.comp.lang.perl.poe |
|---|---|
| Message-ID | <[email protected]> |
On 20.06.2009 03:04 Rocco Caputo wrote:
> You can shut down POE::Component::Client::HTTP by posting a "shutdown"
> event to it, generally by its alias.
Eventually I could figure out how to do this and it is working fine now,
thank you very much!
For future reference this is how I did it:
1. Add KERNEL parameter to the got_response sub
2. Add some sort of flag to indicate that all URLs are processed
3. Do the actual shutdown at the end of the got_response sub:
if ($everything_processed) {
$kernel->post(ua => 'shutdown' );
}
-Michael