[SNMP4J] subclassing Variable

Jeff Ramin ramin at berbee.com
Fri Jun 20 20:40:03 CEST 2008


Hi folks.

I want to be able to monitor an application, so I'm using SNMP4J-agent
to provide that functionality (from within the application).

My question is - how would I subclass Variable (or maybe ManagedObject?)
do provide data that changes over time? My plan is to create a ManagedObject
using MOFactory.createScalar() and handing it a Variable.

Let's say I want to provide an OID that returns the number of rows in
a DB table. I'd like to have a Variable that grabs that number when a
request for it is made; in other words, it would support polling. As
opposed to having a Variable that is updated every X seconds.

Is there a clean way to do this? Thanks!


-- 
Jeffrey Ramin
Berbee
ramin at berbee.com
608.298.1024



More information about the SNMP4J mailing list