modulepackage
0.0.0-20210911093321-41b91674d612
Repository: https://github.com/kthomas/go-natsutil.git
Documentation: pkg.go.dev
# Functions
EstablishSharedNatsConnection establishes or reestablishes the default shared NATS connection.
GetNatsConnection establishes, caches and returns a new NATS connection.
GetNatsConsumerConcurrency returns the environment-configured concurrency specified for consumers; useful for configuring the number of subscriptions to create per NATS connection.
GetNatsJetstreamContext establishes, caches and returns a new NATS jetstream context; the underlying NATS connection will not be closed when the NATS jetstream subsystem exits.
GetSharedJetstreamContext retrieves the default shared NATS jetstream context.
GetSharedNatsConnection retrieves the default shared NATS connection.
IsSharedNatsConnectionValid returns true if the default NATS connection is valid for use.
NatsCreateStream creates a jetstream stream.
NatsJetstreamPublish publishes a NATS jetstream message using the default shared NATS connection.
NatsJetstreamPublishAsync asynchronously publishes a NATS message using the default shared NATS jetstream context.
NatsPublish publishes a NATS message using the default shared NATS connection.
NatsPublishRequest publishes a NATS message using the default shared NATS connection.
RequireNatsJetstreamSubscription establishes, caches and returns a new NATS jetstream context using GetNatsJetstreamContext.