receiverOptions

fun <K, V> receiverOptions(options: MutableReceiverOptions<K, V>.() -> Unit): ReceiverOptions<K, V>

This function provides ReceiverOptions using provided options.

Return

ReceiverOptions.

Example usage:

val receiverOptions = receiverOptions<String, String> {
keyDeserializer { _, data -> String(data) }
valueDeserializer { _, data -> String(data) }

properties {
BOOTSTRAP_SERVERS_CONFIG to "localhost:9092"
GROUP_ID_CONFIG to "my-group-id"
AUTO_OFFSET_RESET_CONFIG to "earliest"
}
}

Parameters

options

A lambda with receiver to configure MutableReceiverOptions.