[snmp] SnmpContest question

Brian Jewell brian.jewell at modius.com
Tue Aug 21 11:36:17 BST 2007


Hi,

I'm having a little trouble understanding the use of SnmpContexts and
SnmpContextPool's.

1) When sending GET requests to the same host, is it correct to call "new
SnmpContextPool()" to retrieve a context each time a PDU is to be sent?

2) If an SnmpContext is created for receiving traps, and a trap listener is
added with 

	SnmpContest context = new SnmpContext(.);
	context.addListener(.);


When I wish to stop receiving traps from a specified host, do I need to call
removeTrapListener() using the *same* context (as I used for calling
addListener(), or is it ok to create a *new* SnmpContext (with the same
properties) and use it for calling removeTrapListener()?

Thanks for your help.

--Brian




More information about the snmp mailing list