Modifier and Type | Field and Description |
---|---|
static io.vertx.lang.rx.TypeArg<ProxyRequest> |
__TYPE_ARG |
Constructor and Description |
---|
ProxyRequest(Object delegate) |
ProxyRequest(ProxyRequest delegate) |
Modifier and Type | Method and Description |
---|---|
String |
absoluteURI() |
ProxyRequest |
bodyFilter(java.util.function.Function<ReadStream<Buffer>,Flowable<Buffer>> filter)
Set a body filter.
|
boolean |
equals(Object o) |
Body |
getBody() |
ProxyRequest |
getDelegate() |
HttpMethod |
getMethod() |
String |
getURI() |
int |
hashCode() |
MultiMap |
headers() |
static ProxyRequest |
newInstance(ProxyRequest arg) |
HttpServerRequest |
outboundRequest() |
Completable |
proxy(HttpClientRequest inboundRequest)
Proxy this outbound request and response to the origin server using the specified inbound request.
|
ProxyRequest |
release()
Release the proxy request.
|
ProxyResponse |
response()
Create and return the proxy response.
|
static ProxyRequest |
reverseProxy(HttpServerRequest outboundRequest)
Create a new
ProxyRequest instance, the outbound request will be paused. |
Completable |
rxProxy(HttpClientRequest inboundRequest)
Proxy this outbound request and response to the origin server using the specified inbound request.
|
Single<ProxyResponse> |
rxSend(HttpClientRequest inboundRequest)
Send this request to the origin server using the specified inbound request.
|
Single<ProxyResponse> |
send(HttpClientRequest inboundRequest)
Send this request to the origin server using the specified inbound request.
|
ProxyRequest |
setBody(Body body)
Set the request body to be sent to the origin server.
|
ProxyRequest |
setMethod(HttpMethod method)
Set the HTTP method to be sent to the origin server.
|
ProxyRequest |
setURI(String uri)
Set the request URI to be sent to the origin server.
|
String |
toString() |
HttpVersion |
version() |
public static final io.vertx.lang.rx.TypeArg<ProxyRequest> __TYPE_ARG
public ProxyRequest(ProxyRequest delegate)
public ProxyRequest(Object delegate)
public ProxyRequest getDelegate()
public static ProxyRequest reverseProxy(HttpServerRequest outboundRequest)
ProxyRequest
instance, the outbound request will be paused.outboundRequest
- the HttpServerRequest
of the user agentpublic HttpVersion version()
public String absoluteURI()
public HttpMethod getMethod()
public ProxyRequest setMethod(HttpMethod method)
The initial HTTP method value is the outbound request HTTP method.
method
- the new HTTP methodpublic String getURI()
public ProxyRequest setURI(String uri)
The initial request URI value is the outbound request URI.
uri
- the new URIpublic Body getBody()
public ProxyRequest setBody(Body body)
The initial request body value is the outbound request body.
body
- the new bodypublic MultiMap headers()
public ProxyRequest bodyFilter(java.util.function.Function<ReadStream<Buffer>,Flowable<Buffer>> filter)
The body filter can rewrite the request body sent to the origin server.
filter
- the filterpublic Completable proxy(HttpClientRequest inboundRequest)
inboundRequest
- the request connected to the origin serverpublic Completable rxProxy(HttpClientRequest inboundRequest)
inboundRequest
- the request connected to the origin serverpublic Single<ProxyResponse> send(HttpClientRequest inboundRequest)
The completionHandler
will be called with the proxy response sent by the origin.
inboundRequest
- the request connected to the origin serverpublic Single<ProxyResponse> rxSend(HttpClientRequest inboundRequest)
The completionHandler
will be called with the proxy response sent by the origin.
inboundRequest
- the request connected to the origin serverpublic ProxyRequest release()
The HTTP server request is resumed, no HTTP server response is sent.
public HttpServerRequest outboundRequest()
public ProxyResponse response()
public static ProxyRequest newInstance(ProxyRequest arg)
Copyright © 2021 Eclipse. All rights reserved.