POE-Component-SNMP
view release on metacpan or search on metacpan
lib/POE/Component/SNMP/Dispatcher.pm view on Meta::CPAN
my ($this, @pdu_args) = @_[OBJECT, ARG0..$#_];
# these are the args this state was invoked with:
# @pdu_args = ( $pdu, $timeout, $retries );
my $pdu = $pdu_args[0];
my $fileno = $pdu->transport->fileno;
# enqueue or execute
if ($this->_current_pdu($fileno)) {
# this socket is busy. enqueue.
$this->_enqueue_pending_pdu($fileno => \@pdu_args);
DEBUG_INFO('queued request for [%d] %d requests pending',
$fileno, $this->_pending_pdu_count($fileno));
} else {
# this socket is free. execute.
DEBUG_INFO('sending request for [%d]', $fileno);
( run in 0.249 second using v1.01-cache-2.11-cpan-87723dcf8b7 )