Interface SummaryMBean

All Superinterfaces:
InfoMBean, SelfEmailingMBean

public interface SummaryMBean extends InfoMBean
Provides configurable periodic "summary" logging of JMX attributes

Supported API: true

Extendable: true
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    addCustomDelegateFactory(String factoryName, String factoryClass)
    Add custom delegate factory instance and associate it with the given name.
    int
    Delay, in seconds, prior to first logging; when negative, the IntervalSeconds value is used instead

    Supported API: true
    Low-level (java.util.Formatter) log format string; if specified, overrides UseShortFormat and SeparatorString

    Supported API: true
    int
    Interval, in seconds, at which logging will be done

    Supported API: true
    Logging level; valid values are ALL, TRACE, DEBUG, INFO, WARN, ERROR, FATAL, OFF (or blank/unspecified); must be INFO (or DEBUG when LogAsDebug is true) for log messages to be produced

    Supported API: true
    Name of logger to which this bean logs

    Supported API: true
    Return the message string that would be sent to a logger based on this MBeans' current configuration

    Supported API: true
    Item separator string used in log format

    Supported API: true
    boolean
    Whether a garbage collection should be explicitly performed immediately to querying the JMX attributes to log

    Supported API: true
    boolean
    Whether log messages should be generated as DEBUG or INFO level messages; see also LoggerLevel

    Supported API: true
    boolean
    Whether multi-line format is used

    Supported API: true
    boolean
    Whether short format (which contains only attribute values, not names) is used for logging

    Supported API: true
    void
    Disable this summary and remove it from the management console

    Supported API: true
    void
    setFirstDelaySeconds(int firstDelaySeconds)
    Delay, in seconds, prior to first logging; when negative, the IntervalSeconds value is used instead

    Supported API: true
    void
    setFormatString(String formatString)
    Low-level (java.util.Formatter) log format string; if specified, overrides UseShortFormat and SeparatorString

    Supported API: true
    void
    setGCFirst(boolean gcFirst)
    Whether a garbage collection should be explicitly performed immediately to querying the JMX attributes to log

    Supported API: true
    void
    setIntervalSeconds(int intervalSeconds)
    Interval, in seconds, at which logging will be done

    Supported API: true
    void
    setLogAsDebug(boolean logAsDebug)
    Whether log messages should be generated as DEBUG or INFO level messages; see also LoggerLevel

    Supported API: true
    void
    Logging level; valid values are ALL, TRACE, DEBUG, INFO, WARN, ERROR, FATAL, OFF (or blank/unspecified); must be INFO (or DEBUG when LogAsDebug is true) for log messages to be produced

    Supported API: true
    void
    setMultiLineFormat(boolean multiLineFormat)
    Whether multi-line format is used

    Supported API: true
    void
    setSeparatorString(String separatorString)
    Item separator string used in log format

    Supported API: true
    void
    setUseShortFormat(boolean useShortFormat)
    Whether short format (which contains only attribute values, not names) is used for logging

    Supported API: true

    Methods inherited from interface wt.jmx.core.mbeans.SelfEmailingMBean

    emailThisMBean
  • Method Details

    • getLogMessage

      String getLogMessage()
      Return the message string that would be sent to a logger based on this MBeans' current configuration

      Supported API: true
    • isLogAsDebug

      boolean isLogAsDebug()
      Whether log messages should be generated as DEBUG or INFO level messages; see also LoggerLevel

      Supported API: true
    • setLogAsDebug

      void setLogAsDebug(boolean logAsDebug)
      Whether log messages should be generated as DEBUG or INFO level messages; see also LoggerLevel

      Supported API: true
    • getLoggerName

      String getLoggerName()
      Name of logger to which this bean logs

      Supported API: true
    • getLoggerLevel

      String getLoggerLevel()
      Logging level; valid values are ALL, TRACE, DEBUG, INFO, WARN, ERROR, FATAL, OFF (or blank/unspecified); must be INFO (or DEBUG when LogAsDebug is true) for log messages to be produced

      Supported API: true
    • setLoggerLevel

      void setLoggerLevel(String level)
      Logging level; valid values are ALL, TRACE, DEBUG, INFO, WARN, ERROR, FATAL, OFF (or blank/unspecified); must be INFO (or DEBUG when LogAsDebug is true) for log messages to be produced

      Supported API: true
    • getFirstDelaySeconds

      int getFirstDelaySeconds()
      Delay, in seconds, prior to first logging; when negative, the IntervalSeconds value is used instead

      Supported API: true
    • setFirstDelaySeconds

      void setFirstDelaySeconds(int firstDelaySeconds)
      Delay, in seconds, prior to first logging; when negative, the IntervalSeconds value is used instead

      Supported API: true
    • getIntervalSeconds

      int getIntervalSeconds()
      Interval, in seconds, at which logging will be done

      Supported API: true
    • setIntervalSeconds

      void setIntervalSeconds(int intervalSeconds)
      Interval, in seconds, at which logging will be done

      Supported API: true
    • isGCFirst

      boolean isGCFirst()
      Whether a garbage collection should be explicitly performed immediately to querying the JMX attributes to log

      Supported API: true
    • setGCFirst

      void setGCFirst(boolean gcFirst)
      Whether a garbage collection should be explicitly performed immediately to querying the JMX attributes to log

      Supported API: true
    • isUseShortFormat

      boolean isUseShortFormat()
      Whether short format (which contains only attribute values, not names) is used for logging

      Supported API: true
    • setUseShortFormat

      void setUseShortFormat(boolean useShortFormat)
      Whether short format (which contains only attribute values, not names) is used for logging

      Supported API: true
    • isMultiLineFormat

      boolean isMultiLineFormat()
      Whether multi-line format is used

      Supported API: true
    • setMultiLineFormat

      void setMultiLineFormat(boolean multiLineFormat)
      Whether multi-line format is used

      Supported API: true
    • getSeparatorString

      String getSeparatorString()
      Item separator string used in log format

      Supported API: true
    • setSeparatorString

      void setSeparatorString(String separatorString)
      Item separator string used in log format

      Supported API: true
    • getFormatString

      String getFormatString()
      Low-level (java.util.Formatter) log format string; if specified, overrides UseShortFormat and SeparatorString

      Supported API: true
    • setFormatString

      void setFormatString(String formatString)
      Low-level (java.util.Formatter) log format string; if specified, overrides UseShortFormat and SeparatorString

      Supported API: true
    • addCustomDelegateFactory

      @MBeanOperationImpact(1) void addCustomDelegateFactory(String factoryName, String factoryClass) throws ClassNotFoundException, InstantiationException, IllegalAccessException
      Add custom delegate factory instance and associate it with the given name.

      An attempt is made to find a constructor in the specified class taking a single String argument and call this constructor passing the specified name. If this fails, the no-arg constructor (which must be public) is used instead and an attempt is also made to call setName(String) on the instance. An attempt is also made to call setOwnerMBean(BaseObjectNamed) on the instance, passing it this MBean, so that any interested delegate factory can obtain this information.

      If the factory is a SelfAwareMBean, then the factory is registered as a child MBean of this MBean.

      The factory class must implement SummaryDelegateFactory. The factory class should also override equals() to return 'true' for logically equivalent instances.

      Supported API: true

      Specified by:
      addCustomDelegateFactory in interface InfoMBean
      Parameters:
      factoryName - Name to associate with custom delegate factory; will use factoryClass if this is null
      factoryClass - Name of custom delegate factory class; class must implement SummaryDelegateFactory
      Throws:
      ClassNotFoundException
      InstantiationException
      IllegalAccessException
    • remove

      @MBeanOperationImpact(1) void remove()
      Disable this summary and remove it from the management console

      Supported API: true