public final class MetricUtils extends Object
| Modifier and Type | Method and Description |
|---|---|
static void |
collectHttpMetrics(software.amazon.awssdk.metrics.MetricCollector metricCollector,
software.amazon.awssdk.http.SdkHttpFullResponse httpResponse) |
static software.amazon.awssdk.metrics.MetricCollector |
createAttemptMetricsCollector(RequestExecutionContext context) |
static software.amazon.awssdk.metrics.MetricCollector |
createHttpMetricsCollector(RequestExecutionContext context) |
static <T> software.amazon.awssdk.utils.Pair<T,Duration> |
measureDuration(Supplier<T> c)
Measure the duration of the given callable.
|
static <T> software.amazon.awssdk.utils.Pair<T,Duration> |
measureDurationUnsafe(Callable<T> c)
Measure the duration of the given callable.
|
public static <T> software.amazon.awssdk.utils.Pair<T,Duration> measureDuration(Supplier<T> c)
c - The callable to measure.Pair containing the result of c and the duration.public static <T> software.amazon.awssdk.utils.Pair<T,Duration> measureDurationUnsafe(Callable<T> c) throws Exception
c - The callable to measure.Pair containing the result of c and the duration.Exceptionpublic static void collectHttpMetrics(software.amazon.awssdk.metrics.MetricCollector metricCollector,
software.amazon.awssdk.http.SdkHttpFullResponse httpResponse)
public static software.amazon.awssdk.metrics.MetricCollector createAttemptMetricsCollector(RequestExecutionContext context)
public static software.amazon.awssdk.metrics.MetricCollector createHttpMetricsCollector(RequestExecutionContext context)
Copyright © 2022. All rights reserved.