[SNMP4J] Setting the log level
Eugene R. Snider
gene at cvtt.net
Thu Jan 10 19:39:52 CET 2008
The technology underlying the logger is the apache log4j package
(bundled with snmp4j). Additional documentation about properties and the
API are available
from the apache web site ( http://logging.apache.org/log4j/1.2/index.html )
Gene
inliner683 at gmx.de wrote:
> Hello,
>
> what is the suggested way to set the log level for an agent implemented with snmp4j?
>
> I know the method
>
> LogFactory.getLogger(Foo.class).setLogLevel(LogLevel.ALL)
>
> but this seems to affect only one class. I tried it on BaseAgent.class
> but this seems to have no impact.
>
> I am using
>
> LogFactory.setLogFactory(new JavaLogFactory());
>
> in my agent.
>
> I also discovered that logging can be influenced with the system property
>
> snmp4j.LogFactory
>
> Is there any documentation how the logging (and perhaps the log level too) can
> be influenced with system properties/command line parameters?
>
> Thank you.
>
More information about the SNMP4J
mailing list