Package software.amazon.awssdk.metrics
Interface MetricCollector
- All Known Implementing Classes:
DefaultMetricCollector
,NoOpMetricCollector
Used to collect metrics reported by the SDK.
-
Method Summary
Modifier and TypeMethodDescriptioncollect()
Return the collected metrics.static MetricCollector
createChild
(String name) Create a child of this metric collector.name()
<T> void
reportMetric
(SdkMetric<T> metric, T data) Report a metric.
-
Method Details
-
name
String name()- Returns:
- The name of this collector.
-
reportMetric
Report a metric. -
createChild
Create a child of this metric collector.- Parameters:
name
- The name of the child collector.- Returns:
- The child collector.
-
collect
MetricCollection collect()Return the collected metrics.Calling
collect()
prevents further invocations ofreportMetric(SdkMetric, Object)
.- Returns:
- The collected metrics.
-
create
-