Class R2TransportClient

  • All Implemented Interfaces:
    java.io.Closeable, java.lang.AutoCloseable

    public class R2TransportClient
    extends InternalTransportClient
    R2 based Transport Client Interface. So far, this class doesn't do anything special about the connection management, such as connection pool (size), and connection warming and so on, and we will rely on the features offered by R2. If we notice anything specific required to be implemented outside of R2, we will improve the implementation here.
    • Constructor Detail

      • R2TransportClient

        public R2TransportClient​(com.linkedin.r2.transport.common.Client r2Client)
    • Method Detail

      • get

        public java.util.concurrent.CompletableFuture<TransportClientResponse> get​(java.lang.String requestUrl,
                                                                                   java.util.Map<java.lang.String,​java.lang.String> headers)
        Specified by:
        get in class TransportClient
      • post

        public java.util.concurrent.CompletableFuture<TransportClientResponse> post​(java.lang.String requestUrl,
                                                                                    java.util.Map<java.lang.String,​java.lang.String> headers,
                                                                                    byte[] requestBody)
        Specified by:
        post in class TransportClient
      • close

        public void close()
                   throws java.io.IOException
        Throws:
        java.io.IOException