ServerConfiguration

data class ServerConfiguration @JvmOverloads constructor(val verbose: Boolean = false, val name: String? = "Mokksy", val journalMode: JournalMode = JournalMode.LEAN, val contentNegotiationConfigurer: (ContentNegotiationConfig) -> Unit = ::configureContentNegotiation)(source)

Configuration for a MokksyServer instance.

Constructors

Link copied to clipboard
constructor(verbose: Boolean = false, name: String? = "Mokksy", journalMode: JournalMode = JournalMode.LEAN, contentNegotiationConfigurer: (ContentNegotiationConfig) -> Unit = ::configureContentNegotiation)

Properties

Link copied to clipboard

Configures the Ktor ContentNegotiationConfig installed on the server. Defaults to JSON with Json.ignoreUnknownKeys enabled.

Link copied to clipboard

Controls which requests are recorded in the dev.mokksy.mokksy.request.RequestJournal. Defaults to JournalMode.LEAN (only unmatched requests).

Link copied to clipboard
val name: String?

Human-readable server name used in log output. Defaults to "Mokksy".

Link copied to clipboard

Enables DEBUG-level request logging when true. Defaults to false.