10 Apr 2009 06:50:12 UTC
- Distribution: Net-SNMP-EV
- Module version: 0.12
- Source (raw)
- Browse (raw)
- How to Contribute
- Testers (525 / 0 / 17)
- KwaliteeBus factor: 1
- 55.17% Coverage
- License: unknown
- Activity24 month
- Download (2.43KB)
- MetaCPAN Explorer
- Subscribe to distribution
- This version
- Latest versionMLEHMANN Marc A. Lehmann
Net::SNMP::EV - adaptor to integrate Net::SNMP into the EV event loop.
use EV; use Net::SNMP; use Net::SNMP::EV; # just use Net::SNMP and EV as you like: ... start non-blocking snmp request(s)... EV::loop;
This module coerces the Net::SNMP scheduler to use the EV high performance event loop as underlying event loop, i.e. EV will be used by Net::SNMP for all events.
This integrates Net::SNMP into EV: You can make non-blocking Net::SNMP calls and as long as your main program uses the EV event loop, they will run in parallel to anything else that uses EV or AnyEvent.
This module does not export anything and does not require you to do anything special apart from loading it.
The module is quite short, you can use it as example to implement a similar integration into e.g. Event or other event loops.
Net::SNMP has no (documented or otherwise) API to do what this module does. As such, this module rummages around in the internals of Net::SNMP in a rather inacceptable way, and as thus might be very sensitive to the version of Net::SNMP used (it has been tested with some 5.x versions only, YMMV).
Marc Lehmann <firstname.lastname@example.org> http://home.schmorp.de/
Module Install Instructions
To install Net::SNMP::EV, copy and paste the appropriate command in to your terminal.
perl -MCPAN -e shell install Net::SNMP::EV
For more information on module installation, please visit the detailed CPAN module installation guide.