StreamConsumerOverrides
Defined in: src/interfaces/options.interface.ts:91
Overrides for JetStream stream and consumer configuration.
Properties
ackExtension?
optionalackExtension?:AckExtensionConfig
Defined in: src/interfaces/options.interface.ts:126
Auto-extend the NATS ack deadline via msg.working() during handler execution.
false(default): disabled; NATS redelivers afterack_waitif not acked.true: auto-extend atack_wait / 2interval (calculated from consumer config).number: explicit extension interval in milliseconds.
concurrency?
optionalconcurrency?:number
Defined in: src/interfaces/options.interface.ts:117
Maximum number of concurrent handler executions (RxJS mergeMap limit).
Default: undefined (unlimited, naturally bounded by max_ack_pending).
Set this to protect downstream systems from overload.
Important: if concurrency < max_ack_pending, messages buffer in RxJS
while their NATS ack timer ticks. Increase ack_wait proportionally to
prevent unnecessary redeliveries.
consume?
optionalconsume?:Partial<ConsumeOptions>
Defined in: src/interfaces/options.interface.ts:105
Options passed to the nats.js consumer.consume() call.
Controls prefetch buffer size, idle heartbeat interval, and auto-refill thresholds.
nats.js supports two consumption modes (message-based and byte-based).
Do not mix max_bytes/threshold_bytes with threshold_messages;
use one mode or the other.
See
https://github.com/nats-io/nats.js ConsumeOptions
consumer?
optionalconsumer?:Partial<ConsumerConfig>
Defined in: src/interfaces/options.interface.ts:93
management?
optionalmanagement?:EntityManagement
Defined in: src/interfaces/options.interface.ts:129
Provisioning control for this kind's stream/consumer. Falls back to provisioning.management.
stream?
optionalstream?:Partial<Omit<StreamConfig,"retention">>
Defined in: src/interfaces/options.interface.ts:92
subjectPrefix?
optionalsubjectPrefix?:string
Defined in: src/interfaces/options.interface.ts:132
Custom subject prefix (trailing dot normalized), e.g. 'company.orders.'.