Package io.vertx.mutiny.httpproxy
Class HttpProxy
- java.lang.Object
-
- io.vertx.mutiny.httpproxy.HttpProxy
-
- All Implemented Interfaces:
io.vertx.core.Handler<HttpServerRequest>,Consumer<HttpServerRequest>
public class HttpProxy extends Object implements io.vertx.core.Handler<HttpServerRequest>, Consumer<HttpServerRequest>
Handles the HTTP reverse proxy logic between the user agent and the origin.
NOTE: This class has been automatically generated from theoriginalnon Mutiny-ified interface using Vert.x codegen.
-
-
Field Summary
Fields Modifier and Type Field Description static TypeArg<HttpProxy>__TYPE_ARG
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaccept(HttpServerRequest item)HttpProxyaddInterceptor(ProxyInterceptor interceptor)booleanequals(Object o)io.vertx.httpproxy.HttpProxygetDelegate()voidhandle(HttpServerRequest request)inthashCode()static HttpProxynewInstance(io.vertx.httpproxy.HttpProxy arg)HttpProxyorigin(int port, String host)HttpProxyorigin(SocketAddress address)HttpProxyoriginSelector(Function<HttpServerRequest,io.smallrye.mutiny.Uni<SocketAddress>> selector)static HttpProxyreverseProxy(io.vertx.httpproxy.ProxyOptions options, HttpClient client)static HttpProxyreverseProxy(HttpClient client)StringtoString()
-
-
-
Constructor Detail
-
HttpProxy
public HttpProxy(io.vertx.httpproxy.HttpProxy delegate)
-
HttpProxy
public HttpProxy(Object delegate)
-
-
Method Detail
-
getDelegate
public io.vertx.httpproxy.HttpProxy getDelegate()
-
reverseProxy
public static HttpProxy reverseProxy(HttpClient client)
- Parameters:
client- theHttpClientthat forwards outbound requests to the origin.- Returns:
- a reference to this, so the API can be used fluently.
-
reverseProxy
public static HttpProxy reverseProxy(io.vertx.httpproxy.ProxyOptions options, HttpClient client)
- Parameters:
options-client- theHttpClientthat forwards outbound requests to the origin.- Returns:
- a reference to this, so the API can be used fluently.
-
origin
public HttpProxy origin(SocketAddress address)
- Parameters:
address- theSocketAddressof the origin- Returns:
- a reference to this, so the API can be used fluently
-
origin
public HttpProxy origin(int port, String host)
- Parameters:
port- the port number of the origin serverhost- the host name of the origin server- Returns:
- a reference to this, so the API can be used fluently
-
originSelector
public HttpProxy originSelector(Function<HttpServerRequest,io.smallrye.mutiny.Uni<SocketAddress>> selector)
- Parameters:
selector- the selector- Returns:
- a reference to this, so the API can be used fluently
-
addInterceptor
public HttpProxy addInterceptor(ProxyInterceptor interceptor)
- Parameters:
interceptor-- Returns:
- a reference to this, so the API can be used fluently
-
handle
public void handle(HttpServerRequest request)
- Specified by:
handlein interfaceio.vertx.core.Handler<HttpServerRequest>- Parameters:
request- the outboundHttpServerRequest
-
accept
public void accept(HttpServerRequest item)
- Specified by:
acceptin interfaceConsumer<HttpServerRequest>
-
newInstance
public static HttpProxy newInstance(io.vertx.httpproxy.HttpProxy arg)
-
-