Class GarbageCollector
java.lang.Object
io.opentelemetry.instrumentation.runtimetelemetry.internal.GarbageCollector
Registers instruments that generate metrics about JVM garbage collection. The metrics generated
by this class follow the
stable JVM metrics semantic conventions.
This class is internal and is hence not for public use. Its APIs are unstable and can change at any time.
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic List<AutoCloseable> registerObservers(io.opentelemetry.api.metrics.Meter meter, boolean captureGcCause) Register observers for java runtime memory metrics.static List<AutoCloseable> registerObservers(io.opentelemetry.api.metrics.Meter meter, List<GarbageCollectorMXBean> gcBeans, Function<Notification, com.sun.management.GarbageCollectionNotificationInfo> notificationInfoExtractor, boolean captureGcCause)
-
Field Details
-
GC_DURATION_BUCKETS
-
-
Constructor Details
-
GarbageCollector
protected GarbageCollector()
-
-
Method Details
-
registerObservers
public static List<AutoCloseable> registerObservers(io.opentelemetry.api.metrics.Meter meter, boolean captureGcCause) Register observers for java runtime memory metrics. -
registerObservers
public static List<AutoCloseable> registerObservers(io.opentelemetry.api.metrics.Meter meter, List<GarbageCollectorMXBean> gcBeans, Function<Notification, com.sun.management.GarbageCollectionNotificationInfo> notificationInfoExtractor, boolean captureGcCause)
-