org.jboss.services.loggingmonitor
Interface LoggingMonitorMBean

All Superinterfaces:
org.jboss.system.Service, org.jboss.system.ServiceMBean
All Known Implementing Classes:
LoggingMonitor

public interface LoggingMonitorMBean
extends org.jboss.system.ServiceMBean

This is the management interface of the LoggingMonitor service which provides the ability to create monitoring logs for various MBeans and their attributes.

Version:
$Revision: 1.1.2.2 $
Author:
James Wilson, Dimitris Andreadis

Field Summary
 
Fields inherited from interface org.jboss.system.ServiceMBean
CREATE_EVENT, CREATED, DESTROY_EVENT, DESTROYED, FAILED, REGISTERED, START_EVENT, STARTED, STARTING, states, STOP_EVENT, STOPPED, STOPPING, UNREGISTERED
 
Method Summary
 boolean getAppendToFile()
           
 String getFilename()
           
 long getMonitorPeriod()
           
 String getPatternLayout()
           
 String getRolloverFormat()
          This monitor's log file rollover format as determined by the RolloverPeriod attribute.
 String getRolloverPeriod()
           
 void setAppendToFile(boolean appendToFile)
          Flag to indicate whether or not this monitor's log file should have information appended to it, if it already exists.
 void setFilename(String filename)
          The name of the file to which this monitor's information will be logged.
 void setMonitoredObjects(Element monitoredObjects)
          Sets the monitored objects configuration.
 void setMonitorPeriod(long monitorPeriod)
          The period to delay between monitoring snapshots.
 void setPatternLayout(String patternLayout)
          The PatternLayout for logging entries (default is "%d %-5p [%c] %m%n")
 void setRolloverPeriod(String rolloverPeriod)
          This monitor's log file rollover period.
 
Methods inherited from interface org.jboss.system.ServiceMBean
getName, getState, getStateString, jbossInternalLifecycle
 
Methods inherited from interface org.jboss.system.Service
create, destroy, start, stop
 

Method Detail

setFilename

public void setFilename(String filename)
The name of the file to which this monitor's information will be logged.


getFilename

public String getFilename()

setAppendToFile

public void setAppendToFile(boolean appendToFile)
Flag to indicate whether or not this monitor's log file should have information appended to it, if it already exists. (default is true)


getAppendToFile

public boolean getAppendToFile()

setRolloverPeriod

public void setRolloverPeriod(String rolloverPeriod)
This monitor's log file rollover period. Valid values are MONTH, WEEK, DAY, HALFDAY, HOUR, and MINUTE (case insensitive). (default is DAY)


getRolloverPeriod

public String getRolloverPeriod()

setMonitorPeriod

public void setMonitorPeriod(long monitorPeriod)
The period to delay between monitoring snapshots. (non-zero positive value)


getMonitorPeriod

public long getMonitorPeriod()

setPatternLayout

public void setPatternLayout(String patternLayout)
The PatternLayout for logging entries (default is "%d %-5p [%c] %m%n")


getPatternLayout

public String getPatternLayout()

getRolloverFormat

public String getRolloverFormat()
This monitor's log file rollover format as determined by the RolloverPeriod attribute.


setMonitoredObjects

public void setMonitoredObjects(Element monitoredObjects)
                         throws javax.management.MalformedObjectNameException
Sets the monitored objects configuration.

Parameters:
monitoredObjects - the objects to be monitored specified in the following format:
 <attribute name="MonitoredObjects">
   <configuration>
      <monitoredmbean name="[object name]" logger="[logger name]">
         <attribute>[attribute name]</attribute>
         <attribute>[attribute name]</attribute>
         ...
      </monitoredmbean>
   </configuration>
 </attribute>
 
Throws:
javax.management.MalformedObjectNameException - if the monitored objects configuration contains an invalid object name.


Copyright © 2002 JBoss Group, LLC. All Rights Reserved.