Package-level declarations

Types

Link copied to clipboard
class Http4kUndertowHttpHandler(handler: HttpHandler) : HttpHandler

Exposed to allow for insertion into a customised Undertow server instance

Link copied to clipboard
class Http4kUndertowSseFallbackHandler(sse: SseHandler, fallback: HttpHandler) : HttpHandler
Link copied to clipboard
class Http4kWebSocketCallback(ws: WsHandler) : WebSocketConnectionCallback
Link copied to clipboard
class Undertow(port: Int = 8000, val stopMode: ServerConfig.StopMode) : PolyServerConfig

Stock version of an Undertow Server. Not that if you want to configure your own server instance you can duplicate this code and modify it as required. We are purposefully trying to limit options here to keep the API simple for the 99% of use-cases.

Functions

Link copied to clipboard
fun Undertow.Builder.buildHttp4kUndertowServer(httpHandler: HttpHandler, stopMode: ServerConfig.StopMode, port: Int): Http4kServer
Link copied to clipboard
fun buildUndertowHandlers(http: HttpHandler?, ws: WsHandler?, sse: SseHandler?, stopMode1: ServerConfig.StopMode): Pair<HttpHandler, HttpHandler>
Link copied to clipboard
fun defaultUndertowBuilder(port: Int, httpHandler1: HttpHandler): Undertow.Builder
Link copied to clipboard
fun Http4kUndertowSseHandler(request: Request, consumer: SseConsumer): ServerSentEventHandler
Link copied to clipboard
fun requiresWebSocketUpgrade(): (HttpServerExchange) -> Boolean