Class MemoryUsageMonitorEntry
java.lang.Object
com.unboundid.ldap.sdk.unboundidds.monitors.MonitorEntry
com.unboundid.ldap.sdk.unboundidds.monitors.MemoryUsageMonitorEntry
- All Implemented Interfaces:
Serializable
@NotMutable
@ThreadSafety(level=COMPLETELY_THREADSAFE)
public final class MemoryUsageMonitorEntry
extends MonitorEntry
This class defines a monitor entry that provides information about the memory
usage for the JVM in which the Directory Server is running. In particular,
it reports information about the memory pools and garbage collectors defined
in the JVM.
The information that may be available in the memory usage monitor entry includes:
NOTE: This class, and other classes within the
com.unboundid.ldap.sdk.unboundidds package structure, are only
supported for use against Ping Identity, UnboundID, and
Nokia/Alcatel-Lucent 8661 server products. These classes provide support
for proprietary functionality or for external specifications that are not
considered stable or mature enough to be guaranteed to work in an
interoperable way with other types of LDAP servers.
The information that may be available in the memory usage monitor entry includes:
- The names of the memory pools that are in use within the JVM.
- The number of bytes currently used within each memory pool.
- The number of bytes used within each memory pool after the last garbage collection.
- The names of the garbage collectors that are in use within the JVM.
- The number of garbage collections performed by each collector.
- The total duration of all garbage collections performed by each collector.
- The average duration of garbage collections performed by each collector.
- The duration of the most recent garbage collection performed by each collector.
- The amount of non-heap memory consumed by the JVM.
- The number of detected pauses of various durations detected by the server.
- The duration of the longest pause detected by the server.
MonitorManager.getMemoryUsageMonitorEntry(com.unboundid.ldap.sdk.LDAPConnection) method.
This entry provides specific methods for accessing information about JVM
memory usage (e.g., the getMemoryPoolNames()
method can be used to retrieve the names of the memory pool). Alternately,
this information may be accessed using the generic API. See the
MonitorManager class documentation for an example that demonstrates
the use of the generic API for accessing monitor data.- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionMemoryUsageMonitorEntry(Entry entry) Creates a new memory usage monitor entry from the provided entry. -
Method Summary
Modifier and TypeMethodDescriptiongetAverageCollectionDuration(String collectorName) Retrieves the average garbage collection duration (in milliseconds) for the specified collector.Retrieves a map containing the average garbage collection duration (in milliseconds) per garbage collector.Retrieves a map containing the number of bytes used after the last garbage collection per memory pool.getBytesUsedAfterLastCollection(String poolName) Retrieves the number of bytes used after the last garbage collection for the specified memory pool.Retrieves a map containing the current number of bytes used per memory pool.getCurrentBytesUsed(String poolName) Retrieves the current number of bytes used for the specified memory pool.Retrieves the amount of memory (in megabytes) that is currently allocated for use by the JVM.Retrieves the number of pauses of various durations detected by the server.Retrieves the amount of memory (in megabytes) allocated for use by the JVM that is not currently in use for holding Java objects.Retrieves the names of the garbage collectors for which information is available.Retrieves the duration of the longest pause detected by the server.Retrieves the maximum amount of memory (in megabytes) that may be allocated and used by the JVM.Retrieves the names of the memory pools for which information is available.Retrieves the set of parsed monitor attributes for this monitor entry, mapped from a unique identifier (in all lowercase characters) to the corresponding monitor attribute.Retrieves a human-readable description name for this monitor entry.Retrieves a human-readable display name for this monitor entry.Retrieves the amount of non-heap memory consumed by the JVM.Retrieves the percentage of the committed amount of tenured memory that is used by memory consumers (assuming that all memory used by memory consumers is contained in the tenured generation).Retrieves the percentage of the maximum allowed amount of tenured memory that is used by memory consumers (assuming that all memory used by memory consumers is contained in the tenured generation).getRecentCollectionDuration(String collectorName) Retrieves the duration (in milliseconds) of the most recent garbage collection for the specified collector.Retrieves a map containing the most recent garbage collection duration (in milliseconds) per garbage collector.Retrieves the percent of the currently-reserved memory that is actually in use by the JVM for storing Java objects.Retrieves the total amount of memory in bytes held by memory consumers.getTotalCollectionCount(String collectorName) Retrieves the total number of garbage collections performed by the specified collector.Retrieves a map containing the total number of garbage collections performed per collector.getTotalCollectionDuration(String collectorName) Retrieves the total length of time (in milliseconds) spent performing garbage collection for the specified collector.Retrieves a map containing the total length of time (in milliseconds) spent performing garbage collection per collector.Retrieves the amount of memory (in megabytes) allocated for use by the JVM that is currently in use for holding Java objects.Methods inherited from class com.unboundid.ldap.sdk.unboundidds.monitors.MonitorEntry
addMonitorAttribute, addMonitorAttribute, addMonitorAttribute, addMonitorAttribute, addMonitorAttribute, addMonitorAttribute, addMonitorAttribute, decode, getBoolean, getDate, getDN, getDouble, getEntry, getInteger, getLong, getMonitorClass, getMonitorName, getString, getStrings, toString, toString
-
Constructor Details
-
MemoryUsageMonitorEntry
Creates a new memory usage monitor entry from the provided entry.- Parameters:
entry- The entry to be parsed as a memory usage monitor entry. It must not benull.
-
-
Method Details
-
getMaxReservableMemoryMB
Retrieves the maximum amount of memory (in megabytes) that may be allocated and used by the JVM.- Returns:
- The maximum amount of memory (in megabytes) that may be allocated
and used by the JVM, or
nullif this was not included in the monitor entry.
-
getCurrentReservedMemoryMB
Retrieves the amount of memory (in megabytes) that is currently allocated for use by the JVM.- Returns:
- The amount of memory (in megabytes) that is currently allocated
for use by the JVM, or
nullif this was not included in the monitor entry.
-
getUsedReservedMemoryMB
Retrieves the amount of memory (in megabytes) allocated for use by the JVM that is currently in use for holding Java objects.- Returns:
- The amount of memory (in megabytes) allocated for use by the JVM
that is currently in use for holding Java objects, or
nullif this was not included in the monitor entry.
-
getFreeReservedMemoryMB
Retrieves the amount of memory (in megabytes) allocated for use by the JVM that is not currently in use for holding Java objects.- Returns:
- The amount of memory (in megabytes) allocated for use by the JVM
that is not currently in use for holding Java objects, or
nullif this was not included in the monitor entry.
-
getReservedMemoryPercentFull
Retrieves the percent of the currently-reserved memory that is actually in use by the JVM for storing Java objects.- Returns:
- The percent of the currently-reserved memory that is actually in use by the JVM for storing Java objects.
-
getGarbageCollectorNames
Retrieves the names of the garbage collectors for which information is available.- Returns:
- The names of the garbage collectors for which information is available.
-
getMemoryPoolNames
Retrieves the names of the memory pools for which information is available.- Returns:
- The names of the memory pools for which information is available.
-
getTotalCollectionCounts
Retrieves a map containing the total number of garbage collections performed per collector.- Returns:
- A map containing the total number of garbage collections performed per collector.
-
getTotalCollectionCount
Retrieves the total number of garbage collections performed by the specified collector.- Parameters:
collectorName- The name of the garbage collector for which to retrieve the information.- Returns:
- The total number of garbage collections performed by the specified
collector, or
nullif that information is not available.
-
getTotalCollectionDurations
Retrieves a map containing the total length of time (in milliseconds) spent performing garbage collection per collector.- Returns:
- A map containing the total length of time (in milliseconds) spent performing garbage collection per collector.
-
getTotalCollectionDuration
Retrieves the total length of time (in milliseconds) spent performing garbage collection for the specified collector.- Parameters:
collectorName- The name of the garbage collector for which to retrieve the information.- Returns:
- The total length of time (in milliseconds) spent performing
garbage collection for the specified collector, or
nullif that information is not available.
-
getAverageCollectionDurations
Retrieves a map containing the average garbage collection duration (in milliseconds) per garbage collector.- Returns:
- A map containing the average garbage collection duration (in milliseconds) per garbage collector.
-
getAverageCollectionDuration
Retrieves the average garbage collection duration (in milliseconds) for the specified collector.- Parameters:
collectorName- The name of the garbage collector for which to retrieve the information.- Returns:
- The average garbage collection duration (in milliseconds) for the
specified collector, or
nullif that information is not available.
-
getRecentCollectionDurations
Retrieves a map containing the most recent garbage collection duration (in milliseconds) per garbage collector.- Returns:
- A map containing the duration of the most recent garbage collection duration (in milliseconds) per garbage collector.
-
getRecentCollectionDuration
Retrieves the duration (in milliseconds) of the most recent garbage collection for the specified collector.- Parameters:
collectorName- The name of the garbage collector for which to retrieve the information.- Returns:
- The duration (in milliseconds) of the most recent garbage
collection for the specified collector, or
nullif that information is not available.
-
getCurrentBytesUsed
Retrieves a map containing the current number of bytes used per memory pool.- Returns:
- A map containing the current number of bytes used per memory pool.
-
getCurrentBytesUsed
Retrieves the current number of bytes used for the specified memory pool.- Parameters:
poolName- The name of the memory pool for which to retrieve the information.- Returns:
- The current number of bytes used for the specified memory pool, or
nullif that information is not available.
-
getBytesUsedAfterLastCollection
Retrieves a map containing the number of bytes used after the last garbage collection per memory pool.- Returns:
- A map containing the number of bytes used after the last garbage collection per memory pool.
-
getBytesUsedAfterLastCollection
Retrieves the number of bytes used after the last garbage collection for the specified memory pool.- Parameters:
poolName- The name of the memory pool for which to retrieve the information.- Returns:
- The number of bytes used after the last garbage collection for the
specified memory pool, or
nullif that information is not available.
-
getNonHeapMemoryBytesUsed
Retrieves the amount of non-heap memory consumed by the JVM.- Returns:
- The amount of non-heap memory consumed by the JVM, or
nullif that information is not available.
-
getTotalBytesUsedByMemoryConsumers
Retrieves the total amount of memory in bytes held by memory consumers.- Returns:
- The total amount of memory in bytes held by memory consumers, or
nullif that information is not available.
-
getPercentageOfMaximumTenuredMemoryUsedByMemoryConsumers
Retrieves the percentage of the maximum allowed amount of tenured memory that is used by memory consumers (assuming that all memory used by memory consumers is contained in the tenured generation).- Returns:
- The percentage of the maximum allowed amount of tenured memory
that is used by memory consumers, or
nullif that information is not available.
-
getPercentageOfCommittedTenuredMemoryUsedByMemoryConsumers
Retrieves the percentage of the committed amount of tenured memory that is used by memory consumers (assuming that all memory used by memory consumers is contained in the tenured generation).- Returns:
- The percentage of the committed amount of tenured memory that is
used by memory consumers, or
nullif that information is not available.
-
getDetectedPauseCounts
Retrieves the number of pauses of various durations detected by the server. The value returned will contain a map between the minimum duration in milliseconds for the associated bucket and the number of pauses detected of at least that duration.- Returns:
- The number of pauses of various durations detected by the server.
-
getMaxDetectedPauseTimeMillis
Retrieves the duration of the longest pause detected by the server.- Returns:
- The duration of the longest pause detected by the server, or
nullif that information is not available.
-
getMonitorDisplayName
Retrieves a human-readable display name for this monitor entry.- Overrides:
getMonitorDisplayNamein classMonitorEntry- Returns:
- A human-readable display name for this monitor entry.
-
getMonitorDescription
Retrieves a human-readable description name for this monitor entry.- Overrides:
getMonitorDescriptionin classMonitorEntry- Returns:
- A human-readable description name for this monitor entry.
-
getMonitorAttributes
Retrieves the set of parsed monitor attributes for this monitor entry, mapped from a unique identifier (in all lowercase characters) to the corresponding monitor attribute.- Overrides:
getMonitorAttributesin classMonitorEntry- Returns:
- The set of parsed monitor attributes for this monitor entry.
-