Package io.quarkus.vertx.http.runtime
Class VertxHttpRecorder
- java.lang.Object
-
- io.quarkus.vertx.http.runtime.VertxHttpRecorder
-
public class VertxHttpRecorder extends Object
-
-
Field Summary
Fields Modifier and Type Field Description static int
DEFAULT_ROUTE_ORDER
static String
GET
(package private) HttpBuildTimeConfig
httpBuildTimeConfig
(package private) RuntimeValue<HttpConfiguration>
httpConfiguration
static String
MAX_REQUEST_SIZE_KEY
static String
REQUEST_START_TIME
The key that the request start time is stored under(package private) static io.vertx.core.Handler<io.vertx.core.http.HttpServerRequest>
rootHandler
static io.quarkus.netty.runtime.virtual.VirtualAddress
VIRTUAL_HTTP
protected static io.netty.bootstrap.ServerBootstrap
virtualBootstrap
protected static io.netty.channel.ChannelFuture
virtualBootstrapChannel
-
Constructor Summary
Constructors Constructor Description VertxHttpRecorder(HttpBuildTimeConfig httpBuildTimeConfig, RuntimeValue<HttpConfiguration> httpConfiguration)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addRoute(RuntimeValue<io.vertx.ext.web.Router> router, Function<io.vertx.ext.web.Router,io.vertx.ext.web.Route> route, io.vertx.core.Handler<io.vertx.ext.web.RoutingContext> handler, HandlerType blocking)
io.vertx.core.Handler<io.vertx.ext.web.RoutingContext>
createBodyHandler()
GracefulShutdownFilter
createGracefulShutdownHandler()
RuntimeValue<io.vertx.mutiny.ext.web.Router>
createMutinyRouter(RuntimeValue<io.vertx.ext.web.Router> router)
void
finalizeRouter(io.quarkus.arc.runtime.BeanContainer container, Consumer<io.vertx.ext.web.Route> defaultRouteHandler, List<Filter> filterList, Supplier<io.vertx.core.Vertx> vertx, LiveReloadConfig liveReloadConfig, Optional<RuntimeValue<io.vertx.ext.web.Router>> mainRouterRuntimeValue, RuntimeValue<io.vertx.ext.web.Router> httpRouterRuntimeValue, RuntimeValue<io.vertx.mutiny.ext.web.Router> mutinyRouter, String rootPath, LaunchMode launchMode, boolean requireBodyHandler, io.vertx.core.Handler<io.vertx.ext.web.RoutingContext> bodyHandler, GracefulShutdownFilter gracefulShutdownFilter, ShutdownConfig shutdownConfig, Executor executor)
static Object
getCurrentApplicationState()
used in the live reload handler to make sure the application has not been changed by another source (e.g.io.vertx.core.Handler<io.vertx.ext.web.RoutingContext>
getNonApplicationRedirectHandler()
static io.vertx.core.Handler<io.vertx.core.http.HttpServerRequest>
getRootHandler()
RuntimeValue<io.vertx.ext.web.Router>
initializeRouter(Supplier<io.vertx.core.Vertx> vertxRuntimeValue)
void
mountFrameworkRouter(RuntimeValue<io.vertx.ext.web.Router> mainRouter, RuntimeValue<io.vertx.ext.web.Router> frameworkRouter, String frameworkPath)
static void
setHotReplacement(io.vertx.core.Handler<io.vertx.ext.web.RoutingContext> handler, io.quarkus.dev.spi.HotReplacementContext hrc)
void
setNonApplicationRedirectHandler(String nonApplicationPath, String rootPath)
static void
shutDownDevMode()
void
startServer(Supplier<io.vertx.core.Vertx> vertx, ShutdownContext shutdown, LaunchMode launchMode, boolean startVirtual, boolean startSocket, Supplier<Integer> ioThreads, List<String> websocketSubProtocols, boolean auxiliaryApplication)
static void
startServerAfterFailedStart()
-
-
-
Field Detail
-
REQUEST_START_TIME
public static final String REQUEST_START_TIME
The key that the request start time is stored under- See Also:
- Constant Field Values
-
MAX_REQUEST_SIZE_KEY
public static final String MAX_REQUEST_SIZE_KEY
- See Also:
- Constant Field Values
-
DEFAULT_ROUTE_ORDER
public static final int DEFAULT_ROUTE_ORDER
- See Also:
- Constant Field Values
-
rootHandler
static volatile io.vertx.core.Handler<io.vertx.core.http.HttpServerRequest> rootHandler
-
GET
public static final String GET
- See Also:
- Constant Field Values
-
httpBuildTimeConfig
final HttpBuildTimeConfig httpBuildTimeConfig
-
httpConfiguration
final RuntimeValue<HttpConfiguration> httpConfiguration
-
virtualBootstrap
protected static io.netty.bootstrap.ServerBootstrap virtualBootstrap
-
virtualBootstrapChannel
protected static io.netty.channel.ChannelFuture virtualBootstrapChannel
-
VIRTUAL_HTTP
public static io.quarkus.netty.runtime.virtual.VirtualAddress VIRTUAL_HTTP
-
-
Constructor Detail
-
VertxHttpRecorder
public VertxHttpRecorder(HttpBuildTimeConfig httpBuildTimeConfig, RuntimeValue<HttpConfiguration> httpConfiguration)
-
-
Method Detail
-
setHotReplacement
public static void setHotReplacement(io.vertx.core.Handler<io.vertx.ext.web.RoutingContext> handler, io.quarkus.dev.spi.HotReplacementContext hrc)
-
shutDownDevMode
public static void shutDownDevMode()
-
startServerAfterFailedStart
public static void startServerAfterFailedStart()
-
initializeRouter
public RuntimeValue<io.vertx.ext.web.Router> initializeRouter(Supplier<io.vertx.core.Vertx> vertxRuntimeValue)
-
createMutinyRouter
public RuntimeValue<io.vertx.mutiny.ext.web.Router> createMutinyRouter(RuntimeValue<io.vertx.ext.web.Router> router)
-
startServer
public void startServer(Supplier<io.vertx.core.Vertx> vertx, ShutdownContext shutdown, LaunchMode launchMode, boolean startVirtual, boolean startSocket, Supplier<Integer> ioThreads, List<String> websocketSubProtocols, boolean auxiliaryApplication) throws IOException
- Throws:
IOException
-
mountFrameworkRouter
public void mountFrameworkRouter(RuntimeValue<io.vertx.ext.web.Router> mainRouter, RuntimeValue<io.vertx.ext.web.Router> frameworkRouter, String frameworkPath)
-
finalizeRouter
public void finalizeRouter(io.quarkus.arc.runtime.BeanContainer container, Consumer<io.vertx.ext.web.Route> defaultRouteHandler, List<Filter> filterList, Supplier<io.vertx.core.Vertx> vertx, LiveReloadConfig liveReloadConfig, Optional<RuntimeValue<io.vertx.ext.web.Router>> mainRouterRuntimeValue, RuntimeValue<io.vertx.ext.web.Router> httpRouterRuntimeValue, RuntimeValue<io.vertx.mutiny.ext.web.Router> mutinyRouter, String rootPath, LaunchMode launchMode, boolean requireBodyHandler, io.vertx.core.Handler<io.vertx.ext.web.RoutingContext> bodyHandler, GracefulShutdownFilter gracefulShutdownFilter, ShutdownConfig shutdownConfig, Executor executor)
-
addRoute
public void addRoute(RuntimeValue<io.vertx.ext.web.Router> router, Function<io.vertx.ext.web.Router,io.vertx.ext.web.Route> route, io.vertx.core.Handler<io.vertx.ext.web.RoutingContext> handler, HandlerType blocking)
-
setNonApplicationRedirectHandler
public void setNonApplicationRedirectHandler(String nonApplicationPath, String rootPath)
-
getNonApplicationRedirectHandler
public io.vertx.core.Handler<io.vertx.ext.web.RoutingContext> getNonApplicationRedirectHandler()
-
createGracefulShutdownHandler
public GracefulShutdownFilter createGracefulShutdownHandler()
-
getRootHandler
public static io.vertx.core.Handler<io.vertx.core.http.HttpServerRequest> getRootHandler()
-
getCurrentApplicationState
public static Object getCurrentApplicationState()
used in the live reload handler to make sure the application has not been changed by another source (e.g. reactive messaging)
-
createBodyHandler
public io.vertx.core.Handler<io.vertx.ext.web.RoutingContext> createBodyHandler()
-
-