A  B  C  D  E  F  G  H  I  J  K  L  M  N  O  P  R  S  T  U  V  W 

C

close() - function in eu.vstoyanov.natsy.NatsKlient
End everything this klient is running and close the connection immediatelycloseGracefully is the graceful counterpart: it drains first, so nothing in flight is lost.
closeBlocking(kotlin.time.Duration) - function in eu.vstoyanov.natsy.NatsKlient
closeGracefully for callers that cannot suspendBlocks the calling thread for up to timeout on the drain.
CLOSED - enum entry in eu.vstoyanov.natsy.ConnectionStatus

Closed for good; a klient never leaves this state

closeGracefully(kotlin.time.Duration) - function in eu.vstoyanov.natsy.NatsKlient
Drain, then close: the complete shutdown sequence in one calldrain delivers what is already in flight and closes the connection; close then ends the klient's flows and cancels its background work.
CodecRegistry - class in eu.vstoyanov.natsy.codec
Decides which MessageCodec carries a given type on and off the wire.
CodecRegistry.Builder - class in eu.vstoyanov.natsy.codec.CodecRegistry
Collects the codecs that override the JSON default, and the Json every derived codec uses.
codecs(kotlin.jvm.functions.Function1) - function in eu.vstoyanov.natsy.KlientConfigBuilder
Override how a type is carried, or configure the shared kotlinx.serialization.json.JsonNothing has to be registered: any @Serializable type is carried as JSON without appearing here.
CompressionOption - class in eu.vstoyanov.natsy.jetstream
Whether a stream's file storage is compressed
configureJson(kotlin.jvm.functions.Function1) - function in eu.vstoyanov.natsy.codec.CodecRegistry.Builder
Adjust the Json that backs every JSON codec, derived or registered.
connect() - function in eu.vstoyanov.natsy.NatsKlient
Open the connection, or return immediately if it is already openSynchronous and fail-fast: jnats connects before it returns, or it throws.
CONNECTED - enum entry in eu.vstoyanov.natsy.ConnectionStatus

Connected and serving

CONNECTING - enum entry in eu.vstoyanov.natsy.ConnectionStatus

Connecting to a server for the first time

ConnectionStatus - class in eu.vstoyanov.natsy
What a klient's connection is currently doingThe states a health or readiness probe distinguishes: CONNECTED is serving, CLOSED is over, and the three in between are all "not right now, ask again".
connectSuspending() - function in eu.vstoyanov.natsy.NatsKlient
connect for callers that can suspendConnecting parks a thread for the handshake, so this runs it on the configured KlientConfigBuilder.ioDispatcher rather than on the caller's.
consumer(java.lang.String,java.lang.String,kotlin.jvm.functions.Function1) - function in eu.vstoyanov.natsy.jetstream.JetStreamContext
Create or update a JetStream consumerIf the consumer doesn't exist, a new one is created from the configuration block.
consumer(java.lang.String,kotlin.jvm.functions.Function1) - function in eu.vstoyanov.natsy.jetstream.StreamContext
Create or update a consumer on this streamIf the consumer doesn't exist, a new one is created from the configuration block.
ConsumerConfig - class in eu.vstoyanov.natsy.jetstream
DSL for configuring JetStream consumersExample usage:
val consumerCtx = js.consumer("MY_STREAM", "MY_CONSUMER") {
    durable = "MY_CONSUMER"
    deliverPolicy = DeliverPolicy.ALL
    ackPolicy = AckPolicy.EXPLICIT
    ackWait = 30.seconds
    maxDeliver = 5
    filterSubject = "orders.>"
}
ConsumerConfigBuilder - class in eu.vstoyanov.natsy.jetstream
Builder for JetStream consumer configuration
ConsumerContext - class in eu.vstoyanov.natsy.jetstream
Context for JetStream consumer operationsProvides access to consumer management and monitoring including:
  • Consumer information and updates

  • Pause/resume operations

  • Monitoring metrics

Example usage:
val consumerCtx = js.consumer("MY_STREAM", "MY_CONSUMER") {
    durable = "MY_CONSUMER"
    ackPolicy = AckPolicy.EXPLICIT
    maxDeliver = 5
}

// Update the consumer
consumerCtx.update {
    maxDeliver = 10
}

// Pause the consumer until it is explicitly resumed
consumerCtx.pause()

// ...or until a deadline, after which the server resumes it automatically
consumerCtx.pause(30.minutes)

// Everything worth monitoring, in one round trip
val stats = consumerCtx.stats()
println("${stats.ackPending} unacknowledged, ${stats.pending} still to come")
consumers() - function in eu.vstoyanov.natsy.jetstream.StreamContext
List all consumers on this streamA failure reaches the collector rather than completing the flow: an empty result means the stream has no consumers, and nothing else.
ConsumerStats - class in eu.vstoyanov.natsy.jetstream.model
A snapshot of everything worth monitoring about a consumer, from one server round trip.
create(java.lang.String,T) - function in eu.vstoyanov.natsy.jetstream.KeyValueStore
Create a new key only if it does not already exist
A  B  C  D  E  F  G  H  I  J  K  L  M  N  O  P  R  S  T  U  V  W