ilog.rules.monitor.jmx

Class IlrJMXAbstractThreadMonitor

  • java.lang.Object
    • ilog.rules.monitor.jmx.IlrJMXAbstractThreadMonitor
    • Method Summary

      Methods 
      Modifier and Type Method and Description
      protected void createModelFactory() 
      boolean enableThreadContentionMonitoring()
      Call this method to enable the JVM thread contention monitoring.
      abstract void endUsage()
      To end usage of a instance of this.
      IlrClassDescriptionSet getBlockingClass(int stackTraceDepth, java.util.EnumSet<java.lang.Thread.State> threadStates, long[] excludedThreadIds)
      Build or complete the monitoring model.
      protected abstract void initalizeThreadMXBean()
      Initialize the java.lang.management.ThreadMXBean instance.
      void reset()
      To reset the model.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • IlrJMXAbstractThreadMonitor

        public IlrJMXAbstractThreadMonitor()
    • Method Detail

      • initalizeThreadMXBean

        protected abstract void initalizeThreadMXBean()
        Initialize the java.lang.management.ThreadMXBean instance. It is called in constructor.
        Throws:
        java.lang.RuntimeException - if any exception occurs.
      • createModelFactory

        protected final void createModelFactory()
      • enableThreadContentionMonitoring

        public final boolean enableThreadContentionMonitoring()
        Call this method to enable the JVM thread contention monitoring.
        Returns:
        true if the feature has been enable successfully.
        See Also:
        ThreadMXBean.isThreadContentionMonitoringSupported(), ThreadMXBean.setThreadContentionMonitoringEnabled(boolean)
      • getBlockingClass

        public final IlrClassDescriptionSet getBlockingClass(int stackTraceDepth,
                                              java.util.EnumSet<java.lang.Thread.State> threadStates,
                                              long[] excludedThreadIds)
        Build or complete the monitoring model.
        Throws:
        java.lang.IllegalArgumentException - if stackTraceDepth is inferior or equals to 0.
        Parameters:
        stackTraceDepth - indicates the depth of the stacktrace inside the model built. Should be a positive int value.
        threadStates - an enum set containing all the state of threads that we want in the model. For instance EnumSet.of( Thread.State.BLOCKED)
        excludedThreadIds - ids of thread that we don't want to monitor.
        Returns:
        an instance of IlrClassDescriptionSet.
        See Also:
        Thread.State
      • reset

        public final void reset()
        To reset the model. After a call to this method, the previous model if any is forget.
      • endUsage

        public abstract void endUsage()
        To end usage of a instance of this.

© Copyright IBM Corp. 1987, 2017