Configuration

class Configuration

Status pages feature config

Constructors

Link copied to clipboard
fun Configuration()

Functions

Link copied to clipboard
inline fun <T : Throwable> exception(noinline handler: suspend PipelineContext<Unit, ApplicationCall>.(T) -> Unit)

Register exception handler for exception type T and it's children

fun <T : Throwable> exception(klass: Class<T>, handler: suspend PipelineContext<Unit, ApplicationCall>.(T) -> Unit)

Register exception handler for exception class klass and it's children

Link copied to clipboard
fun status(vararg status: HttpStatusCode, handler: suspend PipelineContext<*, ApplicationCall>.(HttpStatusCode) -> Unit)

Register status handler for status code

Properties

Link copied to clipboard
val exceptions: MutableMap<Class<*>, suspend PipelineContext<*, ApplicationCall>.(Throwable) -> Unit>

Exception handlers map by exception class

Link copied to clipboard
val statuses: MutableMap<HttpStatusCode, suspend PipelineContext<*, ApplicationCall>.(HttpStatusCode) -> Unit>

Status handlers by status code

Extensions

Link copied to clipboard
fun StatusPages.Configuration.statusFile(vararg code: HttpStatusCode, filePattern: String)

Register a status page file(s) using filePattern for multiple status code list