AbstractPgmqEventHandler

abstract class AbstractPgmqEventHandler(pgmq: Pgmq, queue: PgmqClient.Queue, options: PgmqConsumer.Options = DEFAULT_OPTIONS, defaultUser: Principal? = null) : Component(source)

Constructors

Link copied to clipboard
constructor(pgmq: Pgmq, queue: PgmqClient.Queue, options: PgmqConsumer.Options = DEFAULT_OPTIONS, defaultUser: Principal? = null)

Types

Link copied to clipboard
object Companion

Properties

Link copied to clipboard
open val app: Application
Link copied to clipboard
val log: Logger
Link copied to clipboard
val trace: Tracer

Functions

Link copied to clipboard
context(_: ExecContext, _: QueryExecutor)
suspend fun archive(message: Message): EitherThrowable<Boolean>
context(ec: ExecContext, _: QueryExecutor)
suspend fun archive(msgId: Long): EitherThrowable<Boolean>
Link copied to clipboard
open suspend fun ctx(): ExecContext
Link copied to clipboard
context(_: ExecContext)
abstract suspend fun EventContext.handler(message: Message)
Link copied to clipboard
open suspend fun onFailToAck(e: Throwable)
Link copied to clipboard
open suspend fun onFailToNack(e: Throwable)
Link copied to clipboard
open suspend fun onFailToProcess(e: Throwable)
Link copied to clipboard
open suspend fun onFailToRead(e: Throwable)
Link copied to clipboard
context(ec: ExecContext, _: QueryExecutor)
suspend fun send(message: String, headers: Map<String, String> = emptyMap(), delay: Duration = 0.seconds): EitherThrowable<Long>
context(ec: ExecContext, _: QueryExecutor)
suspend fun send(headers: Map<String, String> = emptyMap(), delay: Duration = 0.seconds, supplier: () -> String): EitherThrowable<Long>
Link copied to clipboard
fun start()
Link copied to clipboard
suspend fun stop()