[SNMP4J] Duplicate V3 Informs being sent

Beau Anderson banderson at rfcode.com
Thu Aug 4 20:20:15 CEST 2011


I'm new to this mailing list list so I don't know if this has been covered yet.  If so, I apologize.

This is a bug report.  Using SNMP4j v1.11.3 if you send an SNMP v3 Inform and pdu.isConfirmedPdu() returns false then it creates an asynchronous pending request and registers a timer for it then it also performs a synchronous send on the inform.  The result is that duplicate messages are sent a few seconds apart from each other.

The relevant code is in MessageDispatcherImpl lines 458 - 462:



458        if (pduHandleCallback != null) {
459          pduHandleCallback.pduHandleAssigned(pduHandle, pdu);
460        }
461        byte[] messageBytes = outgoingMessage.getBuffer().array();
462       sendMessage(transport, transportAddress, messageBytes);


Line 462 should not get called on asynchronous calls.


More information about the SNMP4J mailing list