Types

Link copied to clipboard
Link copied to clipboard
object Companion
Link copied to clipboard
interface Factory
Link copied to clipboard
class MessageMetadata(val epoch: Int, val logOffset: LogOffset, val logTimestamp: LogTimestamp)
Link copied to clipboard
class Record<out M>(val epoch: Int, val logOffset: LogOffset, val logTimestamp: Instant, val message: M)
Link copied to clipboard
fun interface RecordProcessor<in M>
Link copied to clipboard
interface Registration
Link copied to clipboard
fun interface Subscription : AutoCloseable
Link copied to clipboard

The transport's handle on a partition's leader election, driven as a three-step state machine (follower → prepared → leading). See allium/log-processor-lifecycle.allium.

Link copied to clipboard
data class TailSpec<M>(val afterMsgId: MessageId, val processor: Log.RecordProcessor<M>)

Properties

Link copied to clipboard
abstract val epoch: Int
Link copied to clipboard
Link copied to clipboard

Functions

Link copied to clipboard
abstract suspend fun appendMessage(message: M): Log.MessageMetadata
Link copied to clipboard
Link copied to clipboard
abstract fun close()
Link copied to clipboard
abstract fun openAtomicProducer(transactionalId: String): Log.AtomicProducer<M>
Link copied to clipboard
abstract suspend fun openGroupSubscription(listener: Log.SubscriptionListener<M>)
Link copied to clipboard
abstract fun readLastMessage(): M?
Link copied to clipboard
abstract fun readRecords(fromMsgId: MessageId, toMsgId: MessageId): Sequence<Log.Record<M>>

Reads records in the range [fromMsgId, toMsgId) (start-inclusive, end-exclusive). Returns a lazy sequence of decoded records in offset order. If toMsgId exceeds the latest submitted offset, reads up to the latest available record.

Link copied to clipboard
abstract suspend fun tailAll(afterMsgId: MessageId, processor: Log.RecordProcessor<M>)