Interface MetricCollector<T>
- Type Parameters:
T- the type of metrics this collector produces
- All Known Implementing Classes:
ContainerCollector, CpuCollector, DiskCollector, FileDescriptorCollector, JvmClassCollector, JvmGcCollector, JvmMemoryCollector, JvmThreadCollector, UptimeCollector
public interface MetricCollector<T>
Interface for collecting a specific type of metric.
Implementations should be stateless and thread-safe. The collect() method
may be called concurrently from multiple threads.
-
Method Summary
Modifier and TypeMethodDescriptioncollect()Collects metrics.booleanChecks if this collector is available on the current platform.
-
Method Details
-
collect
-
isAvailable
boolean isAvailable()Checks if this collector is available on the current platform.This method should return quickly and may cache its result.
- Returns:
- true if this collector can collect metrics on the current platform
-