[SNMP4J] SNMP Dispatcher

Scott MacKay scottmackay at yahoo.com
Tue Sep 19 16:41:02 CEST 2006


Hi, I am making a SNMP poller and wanted to make sure
I was doing it right...

With a class SNMPEntity, implementing
ResponseListener, each having a PDU and Target.  The
idea is that the class's object will get back the
results for its own PDU/Target.

I have a dispatching thread, with:
Transport transport=new DefaultUdpTransportMapping();
Snmp snmp=new Snmp(transport);
snmp.listen();

In a loop of an array of SNMPEntity, I want to issue a
SNMP to the it's target.
   I basically do a:
for (int i=0;i<SNMPEntityArray.size();i++) {
  SNMPEntity entity=SNMPEntityArray.get(i);
  snmp.send(pdu, entity.getTarget(), null, entity);
}

Is there any more setup/preparation needed?
Will this cause problems/overwrites/etc when sending a
number of requests back to back?

-Scott




__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 



More information about the SNMP4J mailing list