All Implemented Interfaces:
GCData, HealthCenterData, NotificationBroadcaster, NotificationEmitter

public class GCDataImpl extends HealthCenterDataImpl implements GCData
  • Field Details

  • Constructor Details

    • GCDataImpl

      public GCDataImpl(com.ibm.java.diagnostics.common.datamodel.data.Data data)
  • Method Details

    • getHeapSizeData

      public HeapData[] getHeapSizeData()
      Description copied from interface: GCData
      Gets the data that is associated with heap size. NOTE If running in "event only" mode, this data will always return an empty array. This is because "event only" does not store any data to inquire on. Instead, you need to use the api calls to register listeners and get notification of when events occur
      Specified by:
      getHeapSizeData in interface GCData
      Returns:
      an array of HeapData objects.
    • getUsedHeapData

      public HeapData[] getUsedHeapData()
      Description copied from interface: GCData
      Gets the data that is associated with used heap after a garbage collection. NOTE If running in "event only" mode, this data will always return an empty array. This is because "event only" does not store any data to inquire on. Instead, you need to use the api calls to register listeners and get notification of when events occur
      Specified by:
      getUsedHeapData in interface GCData
      Returns:
      An array of HeapData objects.
    • getGCPauseTimeData

      public PauseData[] getGCPauseTimeData()
      Description copied from interface: GCData
      Gets the data associated with garbage collection pause times. NOTE If running in "event only" mode, this data will always return an empty array. This is because "event only" does not store any data to inquire on. Instead, you need to use the api calls to register listeners and get notification of when events occur
      Specified by:
      getGCPauseTimeData in interface GCData
      Returns:
      an array of PauseData objects.
    • getConcurrentCollectionCount

      public int getConcurrentCollectionCount()
      Description copied from interface: GCData
      Gets the concurrent collection count
      Specified by:
      getConcurrentCollectionCount in interface GCData
      Returns:
      the number of concurrent collections or -1 if there aren't any concurrent collections.
    • getGCMode

      public Enum<GCData.GCmodes> getGCMode()
      Description copied from interface: GCData
      Gets the garbage collection mode that is used by the monitored application.
      Specified by:
      getGCMode in interface GCData
      Returns:
      the garbage collection mode.
    • getGlobalAverageGCPauseTime

      public double getGlobalAverageGCPauseTime()
      Description copied from interface: GCData
      Gets the average global garbage collection pause time, in milliseconds.
      Specified by:
      getGlobalAverageGCPauseTime in interface GCData
      Returns:
      the average global garbage collection pause time or -1 if there aren't any global collections.
    • getGlobalAverageCollectionInterval

      public double getGlobalAverageCollectionInterval()
      Description copied from interface: GCData
      Gets the average interval, in milliseconds, between global garbage collections.
      Specified by:
      getGlobalAverageCollectionInterval in interface GCData
      Returns:
      the average global collection interval or -1 if there aren't any global collections
    • getGlobalGCCount

      public int getGlobalGCCount()
      Description copied from interface: GCData
      Gets the number of global garbage collections.
      Specified by:
      getGlobalGCCount in interface GCData
      Returns:
      the number of global garbage collections or -1 if there aren't any global collections.
    • getLargestMemoryRequest

      public long getLargestMemoryRequest()
      Description copied from interface: GCData
      Gets the largest memory request (in bytes) made by the application.
      Specified by:
      getLargestMemoryRequest in interface GCData
      Returns:
      the largest memory request that triggered a garbage collection or -1 if there aren't any.
    • getNurseryAverageGCPauseTime

      public double getNurseryAverageGCPauseTime()
      Description copied from interface: GCData
      Gets the average nursery garbage collection pause time, in milliseconds.
      Specified by:
      getNurseryAverageGCPauseTime in interface GCData
      Returns:
      the average nursery garbage collection pause times or -1 if there aren't any nursery collections.
    • getNurseryAverageCollectionInterval

      public double getNurseryAverageCollectionInterval()
      Description copied from interface: GCData
      Gets the average interval, in milliseconds, between nursery garbage collections.
      Specified by:
      getNurseryAverageCollectionInterval in interface GCData
      Returns:
      the average nursery garbage collection interval time or -1 if there aren't any nursery collections.
    • getNurseryGCCount

      public int getNurseryGCCount()
      Description copied from interface: GCData
      Gets the number of nursery garbage collections.
      Specified by:
      getNurseryGCCount in interface GCData
      Returns:
      the number of nursery garbage collections or -1 if there aren't s any nursery collections.
    • getNurseryTotalAmountFlipped

      public long getNurseryTotalAmountFlipped()
      Description copied from interface: GCData
      Gets the total amount flipped for nursery garbage collections.
      Specified by:
      getNurseryTotalAmountFlipped in interface GCData
      Returns:
      The total amount flipped in nursery collections in bytes or -1 if there aren't any.
    • getGMPCycleCount

      public int getGMPCycleCount()
      Description copied from interface: GCData
      Gets the global mark phase cycle count.
      Specified by:
      getGMPCycleCount in interface GCData
      Returns:
      the count of the number of global mark phases or -1 if there aren't any.
    • getAverageGMPCollections

      public int getAverageGMPCollections()
      Description copied from interface: GCData
      Gets the average number of global mark phase collections per cycle.
      Specified by:
      getAverageGMPCollections in interface GCData
      Returns:
      the average number of global mark phase collections or -1 if there aren't any.
    • getQuantumCollectionCount

      public int getQuantumCollectionCount()
      Description copied from interface: GCData
      Gets the total number of quantum collections. This applies only to IBM WebSphere Real Time.
      Specified by:
      getQuantumCollectionCount in interface GCData
      Returns:
      the number of quantum collections or -1 if there aren't any quantum collections.
    • getSynchGCCount

      public int getSynchGCCount()
      Description copied from interface: GCData
      Gets the total number of synchronous garbage collections.
      Specified by:
      getSynchGCCount in interface GCData
      Returns:
      the number of synchronous garbage collections or -1 if there aren't any synchronous collections.
    • getNumberOfAllocationFailures

      public int getNumberOfAllocationFailures()
      Description copied from interface: GCData
      Gets the number of garbage collections triggered by allocation failure.
      Specified by:
      getNumberOfAllocationFailures in interface GCData
      Returns:
      the number of allocation failures or -1 if there aren't any.
    • getProportionTimeSpentInGCPause

      public double getProportionTimeSpentInGCPause()
      Description copied from interface: GCData
      Gets the proportion of time spent in garbage collection pauses. Returned as a percentage.
      Specified by:
      getProportionTimeSpentInGCPause in interface GCData
      Returns:
      the percentage of time spent in garbage collections pauses or -1 if there aren't any collections.
    • getProportionTimeSpentUnpaused

      public double getProportionTimeSpentUnpaused()
      Description copied from interface: GCData
      Gets the proportion of time spent unpaused (not in a garbage collection). Returned as a percentage.
      Specified by:
      getProportionTimeSpentUnpaused in interface GCData
      Returns:
      the percentage of time spent unpaused or -1 if there aren't any collections.
    • getRateOfGarbageCollection

      public double getRateOfGarbageCollection()
      Description copied from interface: GCData
      Gets the rate of garbage collection in MB/minute.
      Specified by:
      getRateOfGarbageCollection in interface GCData
      Returns:
      the rate of garbage collection or -1 if there aren't any collections.
    • getNumberSystemGC

      public int getNumberSystemGC()
      Description copied from interface: GCData
      Gets the number of system (forced) garbage collections.
      Specified by:
      getNumberSystemGC in interface GCData
      Returns:
      the number of system garbage collections or -1 if there aren't any.
    • getRecommendationLabel

      protected String getRecommendationLabel()
      Specified by:
      getRecommendationLabel in class HealthCenterDataImpl
    • getSubsystemLabel

      protected String getSubsystemLabel()
      Specified by:
      getSubsystemLabel in class HealthCenterDataImpl
    • getPreferences

      public GCPreferences getPreferences()
      Description copied from interface: GCData
      Gets a GCPreferences object on which preferences can be set.
      Specified by:
      getPreferences in interface GCData
      Returns:
      the GCPreferences object for this GCData object.
    • getObjectAllocationEvents

      public ObjectAllocationEvent[] getObjectAllocationEvents()
      Description copied from interface: GCData
      Gets an array of the object allocation events.
      Specified by:
      getObjectAllocationEvents in interface GCData
      Returns:
      an array of ObjectAllocation objects.
    • getOutOfLineAllocationEvents

      public OutOfLineAllocationEvent[] getOutOfLineAllocationEvents()
      Description copied from interface: GCData
      Gets an array of the out-of-line allocation events.
      Specified by:
      getOutOfLineAllocationEvents in interface GCData
      Returns:
      an array of OutOfLineAllocationEvent objects.
    • getAverageCollectionInterval

      public double getAverageCollectionInterval()
      Description copied from interface: GCData
      Gets average interval, in milliseconds, between garbage collections.
      Specified by:
      getAverageCollectionInterval in interface GCData
      Returns:
      the average collection interval or -1 if there aren't any collections.
    • getAverageGCPauseTime

      public double getAverageGCPauseTime()
      Description copied from interface: GCData
      Gets the average garbage collection pause time, in milliseconds.
      Specified by:
      getAverageGCPauseTime in interface GCData
      Returns:
      the average garbage collection pause time or -1 if there aren't any collections.
    • getGCCount

      public int getGCCount()
      Description copied from interface: GCData
      Gets the number of garbage collections.
      Specified by:
      getGCCount in interface GCData
      Returns:
      the total number of garbage collections or -1 if there aren't any collections.
    • startNotifying

      public void startNotifying()
      Description copied from interface: HealthCenterData
      Starts a thread which checks for changes in the data every 2000 milliseconds and sends notifications if an update has occurred. To handle these notifications, a NotificationListener needs to be added to the object the thread is being started from.
      Specified by:
      startNotifying in interface HealthCenterData
    • startNotifying

      public void startNotifying(long delay)
      Description copied from interface: HealthCenterData
      Starts a thread which checks for changes in the data and sends notifications if an update has occurred. To handle these notifications, a NotificationListener needs to be added to the object the thread is being started from.
      Specified by:
      startNotifying in interface HealthCenterData
      Parameters:
      delay - The number of milliseconds between each update. The default is 2000 milliseconds and anything below this will not be accepted.
    • getMaxHeapSize

      public long getMaxHeapSize()
      Description copied from interface: GCData
      Gets the maximum heap size.
      Specified by:
      getMaxHeapSize in interface GCData
      Returns:
      maximum heap size in bytes
    • getMeanHeapSize

      public double getMeanHeapSize()
      Description copied from interface: GCData
      Gets the mean heap size.
      Specified by:
      getMeanHeapSize in interface GCData
      Returns:
      mean heap size in bytes
    • getMinHeapSize

      public long getMinHeapSize()
      Description copied from interface: GCData
      Gets the minimum heap size.
      Specified by:
      getMinHeapSize in interface GCData
      Returns:
      minimum heap size in bytes
    • getMaxUsedHeap

      public long getMaxUsedHeap()
      Description copied from interface: GCData
      Gets the maximum used heap.
      Specified by:
      getMaxUsedHeap in interface GCData
      Returns:
      maximum used heap in bytes
    • getMeanUsedHeap

      public double getMeanUsedHeap()
      Description copied from interface: GCData
      Gets the mean used heap.
      Specified by:
      getMeanUsedHeap in interface GCData
      Returns:
      mean used heap in bytes
    • getMinUsedHeap

      public long getMinUsedHeap()
      Description copied from interface: GCData
      Gets the minimum used heap.
      Specified by:
      getMinUsedHeap in interface GCData
      Returns:
      minimum used heap in bytes
    • getMaxPauseTime

      public long getMaxPauseTime()
      Description copied from interface: GCData
      Gets the maximum pause time.
      Specified by:
      getMaxPauseTime in interface GCData
      Returns:
      maximum pause time in ms
    • getMeanPauseTime

      public double getMeanPauseTime()
      Description copied from interface: GCData
      Gets the mean pause time.
      Specified by:
      getMeanPauseTime in interface GCData
      Returns:
      mean pause time in ms
    • getMinPauseTime

      public long getMinPauseTime()
      Description copied from interface: GCData
      Gets the minimum pause time.
      Specified by:
      getMinPauseTime in interface GCData
      Returns:
      minimum pause time in ms
    • addGCListener

      public void addGCListener(GCEventListener listener)
      Description copied from interface: GCData
      Add a listener for notification of when GC events occur
      Specified by:
      addGCListener in interface GCData
    • removeGCListener

      public void removeGCListener(GCEventListener listener)
      Description copied from interface: GCData
      Remove one of registered listeners.
      Specified by:
      removeGCListener in interface GCData
    • addObjectAllocationListener

      public void addObjectAllocationListener(ObjectAllocationEventListener listener)
      Description copied from interface: GCData
      Add a listener for notification of when ObjectAllocation events occur
      Specified by:
      addObjectAllocationListener in interface GCData
    • removeObjectAllocationListener

      public void removeObjectAllocationListener(ObjectAllocationEventListener listener)
      Description copied from interface: GCData
      Remove one of registered listeners.
      Specified by:
      removeObjectAllocationListener in interface GCData