Class BytesWrittenTrackingPublisher

java.lang.Object
software.amazon.awssdk.core.internal.metrics.BytesWrittenTrackingPublisher
All Implemented Interfaces:
org.reactivestreams.Publisher<ByteBuffer>

@SdkInternalApi public final class BytesWrittenTrackingPublisher extends Object implements org.reactivestreams.Publisher<ByteBuffer>
Publisher that tracks how many bytes are published from the wrapped publisher to the downstream subscriber, along with timing information for throughput calculation.
  • Constructor Details

    • BytesWrittenTrackingPublisher

      public BytesWrittenTrackingPublisher(org.reactivestreams.Publisher<ByteBuffer> upstream, RequestBodyMetrics metrics)
  • Method Details

    • subscribe

      public void subscribe(org.reactivestreams.Subscriber<? super ByteBuffer> subscriber)
      Specified by:
      subscribe in interface org.reactivestreams.Publisher<ByteBuffer>