You can set a timeout for anything by using POE::Kernel's delay().
sub _start {
... in addition to the PoCo::Client::NNTP SYNOPSIS code:
$kernel-delay(connect_timeout = 60); # set it
}
sub _connected {
... in addition to the PoCo::Client::NNTP SYNOPSIS code:
For example, I am using POE::Component::Client::NNTP
http://search.cpan.org/~bingos/POE-Component-Client-NNTP-2.14/lib/POE/Component/Client/NNTP.pm
This module does not specify any timeout, so sometimes my program
seems hanged and does not response.
Is it possible to specify a timeout or
Can't you just use a name-based timer, re-set it every time you get any
activity, and when it goes off (implying no activity for the duration of the
timer), shut down?
http://search.cpan.org/~rcaputo/POE-1.287/lib/POE/Kernel.pm#delay_set_EVENT_NAME,_DURATION_SECONDS_[,_PARAMETER_LIST]
--