Req - Type of requests sent on this connection.Resp - Type of responses read from this connection.public interface NettyPipelinedConnection<Req,Resp> extends NettyConnectionContext
NettyConnection to make pipelined requests, typically for a client.
Pipelining allows to have concurrent requests processed on the server but still deliver responses in order. This eliminates the need for request-response correlation, at the cost of head-of-line blocking.
| Modifier and Type | Interface and Description |
|---|---|
static interface |
NettyPipelinedConnection.Writer
A writer to write a request on a connection.
|
NettyConnectionContext.FlushStrategyProviderConnectionContext.Protocol| Modifier and Type | Method and Description |
|---|---|
Publisher<Resp> |
request(NettyPipelinedConnection.Writer writer)
Writes on this connection a request encapsulated in the passed
NettyPipelinedConnection.Writer. |
Publisher<Resp> |
request(NettyPipelinedConnection.Writer writer,
java.util.function.Supplier<java.util.function.Predicate<Resp>> terminalMsgPredicateSupplier)
Writes on this connection a request encapsulated in the passed
NettyPipelinedConnection.Writer. |
Publisher<Resp> |
request(Publisher<Req> request)
Send request(s) produced by a
Publisher on this connection. |
Publisher<Resp> |
request(Publisher<Req> request,
java.util.function.Supplier<NettyConnection.RequestNSupplier> requestNSupplierFactory)
Send request(s) produced by a
Publisher on this connection. |
Publisher<Resp> |
request(Publisher<Req> request,
java.util.function.Supplier<NettyConnection.RequestNSupplier> requestNSupplierFactory,
java.util.function.Supplier<java.util.function.Predicate<Resp>> terminalMsgPredicateSupplier)
Send request(s) produced by a
Publisher on this connection. |
Publisher<Resp> |
request(Req request)
Writes a
Req object on this connection. |
Publisher<Resp> |
request(Req request,
java.util.function.Supplier<java.util.function.Predicate<Resp>> terminalMsgPredicateSupplier)
Writes a
Req object on this connection. |
Publisher<Resp> |
request(Single<Req> request)
Send request produced by a
Single on this connection. |
Publisher<Resp> |
request(Single<Req> request,
java.util.function.Supplier<java.util.function.Predicate<Resp>> terminalMsgPredicateSupplier)
Send request produced by a
Single on this connection. |
Publisher<Resp> |
request(java.util.function.Supplier<java.util.function.Predicate<Resp>> terminalMsgPredicateSupplier,
Publisher<Req> request)
Send request(s) produced by a
Publisher on this connection. |
defaultFlushStrategy, nettyChannel, onClosing, transportError, updateFlushStrategyexecutionContext, localAddress, protocol, remoteAddress, socketOption, sslSessiononClosecloseAsync, closeAsyncGracefullyPublisher<Resp> request(Req request)
Req object on this connection.
Use request(Object, Supplier) to override the predicate used to mark the end of response.
request - to write.Publisher for this request.Publisher<Resp> request(NettyPipelinedConnection.Writer writer)
NettyPipelinedConnection.Writer.
Use request(Writer, Supplier) to override the predicate used to mark the end of response.
writer - to write the request.Publisher for this request.Publisher<Resp> request(NettyPipelinedConnection.Writer writer, java.util.function.Supplier<java.util.function.Predicate<Resp>> terminalMsgPredicateSupplier)
NettyPipelinedConnection.Writer.writer - to write the request.terminalMsgPredicateSupplier - Supplier of a dynamic Predicate for this request that will
mark the end of the response.Publisher for this request.Publisher<Resp> request(Req request, java.util.function.Supplier<java.util.function.Predicate<Resp>> terminalMsgPredicateSupplier)
Req object on this connection.request - to write.terminalMsgPredicateSupplier - Supplier of a dynamic Predicate for this request that will
mark the end of the response.Publisher for this request.Publisher<Resp> request(Single<Req> request)
Single on this connection.
Use request(Single, Supplier) to override the predicate used to mark the end of response.
request - to write.Publisher for this request.Publisher<Resp> request(Single<Req> request, java.util.function.Supplier<java.util.function.Predicate<Resp>> terminalMsgPredicateSupplier)
Single on this connection.Publisher<Resp> request(Publisher<Req> request)
Publisher on this connection.
Use request(Publisher, Supplier) to override the predicate used to mark the end of response.
Publisher<Resp> request(java.util.function.Supplier<java.util.function.Predicate<Resp>> terminalMsgPredicateSupplier, Publisher<Req> request)
Publisher on this connection.Publisher<Resp> request(Publisher<Req> request, java.util.function.Supplier<NettyConnection.RequestNSupplier> requestNSupplierFactory)
Publisher on this connection.
Use request(Publisher, Supplier, Supplier) to override the predicate used to mark the end of
response.
request - Publisher producing the request(s) to write.requestNSupplierFactory - A Supplier of NettyConnection.RequestNSupplier for this request.Publisher for this request.Publisher<Resp> request(Publisher<Req> request, java.util.function.Supplier<NettyConnection.RequestNSupplier> requestNSupplierFactory, java.util.function.Supplier<java.util.function.Predicate<Resp>> terminalMsgPredicateSupplier)
Publisher on this connection.request - Publisher producing the request(s) to write.requestNSupplierFactory - A Supplier of NettyConnection.RequestNSupplier for this request.terminalMsgPredicateSupplier - Supplier of a dynamic Predicate for this request that will
mark the end of the response.Publisher for this request.