JBI Support deprecated in Apache ServiceMix 4

JBI 1.0 support is available in Apache ServiceMix 4 to allow existing users to migrate more easily to this latest version - if you're a new user, you should consider JBI deprecated and not use it for your project. Take a look at our technology selection guidelines for more information.



The ServiceMix SNMP component provides support for receiving SNMP events via the enterprise service bus by using the SNMP4J library.

Namespace and xbean.xml

The namespace URI for the servicemix-bean JBI component is http://servicemix.apache.org/snmp/1.0. This is an example of an xbean.xml file with a namespace definition with prefix bean.

<beans xmlns:snmp="http://servicemix.apache.org/snmp/1.0">

  <!-- add snmp:poller or snmp:sender definitions here -->


Endpoint types

The servicemix-snmp component defines two endpoint types:

  • snmp:poller :: Periodically polls a device status using SNMP and sends the OIDs as a JBI MessageExchange

  • snmp:trap-consumer :: Consumes an SNMP trap message and sends the OIDs as a JBI MessageExchange


Endpoint properties

Property Name Type Description
address java.lang.String <p>Specifies the connection URI used to connect to a snmp capable device. <br /><br /> <b><u>Template:</u></b> <br />  nbsp; i><rotocol><ost><ort>/i> <br /><br /> <b><u>Details:</u></b><br /><br/> <table border="0" cellpadding="0" cellspacing="0"> <tr> <td width="40%" align="left"><b><u>Name</u></b></td> <td width="60%" align="left"><b><u>Description</u></b></td> </tr> <tr> <td>protocol</td> <td>the protocol to use (udp or tcp)</td> </tr> <tr> <td>host</td> <td>the name or ip address of the snmp capable device</td> </tr> <tr> <td>port</td> <td>the port number to use</td> </tr> </table> <br/> <b><u>Example:</u></b><br />  nbsp; i>udp:</i></p> <i> nbsp; he default value is <b>null</b></i><br/><br/>
concurrentPolling boolean Sets whether more than one poll can be active at a time (true means yes). Default value is <code>false</code>.
delay long Sets the amount of time in milliseconds that the endpoint should wait before making the first poll.
endpoint java.lang.String The name of the endpoint.
firstTime java.util.Date Sets the date on which the first poll will be executed. If a delay is also set using <code>setDelay</code>, the delay interval will be added after the date specified.
interfaceName javax.xml.namespace.QName The qualified name of the interface exposed by the endpoint.
marshaler org.apache.servicemix.snmp.marshaler.SnmpMarshalerSupport <p>Specifies a marshaler class which provides the logic for converting a snmp response into a normalized message. This class has to implement the <code>SnmpMarshalerSupport</code> interface. If you don't specify a marshaler, the <code>DefaultSnmpMarshaler</code> will be used.</p>
oids (java.lang.Object)\* <p>Specifies a reference to a list of OID values which will be used for the snmp request. You have two possibilities how to specify the value: <br /><br />  i>a) referencing to a file containing a list of OID values separated by a line feed <br/> nbsp; nbsp;or<br/>  i>b) defining a coma (<b>,</b>) separated list of OID values <br /><br /> <b><u>Examples:</u></b><br />  nbsp; i>a) oids="classpath:myOids.txt"<br />  nbsp; nbsp; nbsp; ids="file:/home/lhein/snmp/device_a/oids.txt"<br/> <br />  nbsp; i>b) oids=" , , ,"</i></p> <i> nbsp; he default value is <b>null</b></i><br/><br/>
period long Sets the number of milliseconds between polling attempts.
retries int <p>Specifies the connection retries.</p> <i> nbsp; he default value is <b>2</b></i><br/><br/>
scheduler org.apache.servicemix.common.scheduler.Scheduler Set a custom Scheduler implementation if you need more fine-grained control over the polling schedule.
service javax.xml.namespace.QName The qualified name of the service the endpoint exposes.
snmpCommunity java.lang.String <p>Specifies the snmp community to use.</p> <i> nbsp; he default value is <b>"public"</b></i><br/><br/>
snmpVersion int <p>Specifies the snmp protocol version to use.</p> <i> nbsp; he default value is <b>0 (version 1)</b></i><br/><br/>
targetEndpoint java.lang.String the name of the endpoint to which requests are sent
targetInterface javax.xml.namespace.QName the QName of the interface to which requests are sent
targetOperation javax.xml.namespace.QName the QName of the operation to which requests are sent
targetService javax.xml.namespace.QName the QName of the service to which requests are sent
targetUri java.lang.String Set the target service/endpoint/interface using a URI.
timeout int <p>Specifies the connection time out in milliseconds.</p> <i> nbsp; he default value is <b>1500</b></i><br/><br/>


Endpoint properties