Class RetryDetector

  • All Implemented Interfaces:
    java.lang.AutoCloseable, software.amazon.awssdk.metrics.MetricPublisher, software.amazon.awssdk.utils.SdkAutoCloseable

    public class RetryDetector
    extends java.lang.Object
    implements software.amazon.awssdk.metrics.MetricPublisher
    Metrics are the only reliable way provided by the AWS SDK to determine if an API call was retried. This class can be attached to an AWS API call and checked after to determine if retries occurred.
    • Constructor Summary

      Constructors 
      Constructor Description
      RetryDetector()  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void close()  
      void publish​(software.amazon.awssdk.metrics.MetricCollection metricCollection)  
      boolean retried()  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • RetryDetector

        public RetryDetector()
    • Method Detail

      • publish

        public void publish​(software.amazon.awssdk.metrics.MetricCollection metricCollection)
        Specified by:
        publish in interface software.amazon.awssdk.metrics.MetricPublisher
      • close

        public void close()
        Specified by:
        close in interface java.lang.AutoCloseable
        Specified by:
        close in interface software.amazon.awssdk.metrics.MetricPublisher
        Specified by:
        close in interface software.amazon.awssdk.utils.SdkAutoCloseable
      • retried

        public boolean retried()