Plugin

interface Plugin

Server.Plugin enables Server functionality to be augmented and/or observed.

Server.Plugin function execution is non-blocking, but occurs synchronously within Server proxy operations. Therefore, implement Server.Plugin functions judiciously, considering that long suspension time will impact Server throughput.

Server.Plugin function invocation is not thread-safe. Thus, perform any necessary synchronization in the Server.Plugin implementation.

Inheritors

Types

Link copied to clipboard
abstract class Async : Server.Plugin

Server.Plugin.Async is an asynchronous Server.Plugin intended for use by Java code.

Link copied to clipboard
Link copied to clipboard

Functions

Link copied to clipboard
abstract suspend fun intercept(session: Bolt.Session, message: Bolt.Message): Bolt.Message

Intercept, and optionally transform, the message.

Link copied to clipboard
abstract suspend fun observe(event: Server.Event)

Observe the event.

Link copied to clipboard
open infix fun then(that: Server.Plugin): Server.Plugin

Run this Server.Plugin then that.