server

package
v1.28.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 27, 2024 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewNatsStream

func NewNatsStream(opts ...nats.Option) (events.Stream, error)

NewNatsStream returns a streaming client used by `Consume` and `Publish` methods retries exponentially to connect to a nats server.

func RunNatsServer

func RunNatsServer(opts ...Option) error

RunNatsServer runs the nats streaming server.

Types

type Option

type Option func(*natsServer.Options, *stanServer.Options)

Option configures the nats server.

func Host

func Host(url string) Option

Host sets the host URL for the nats server.

func NatsOpts

func NatsOpts(opt func(*natsServer.Options)) Option

NatsOpts allows setting Options from nats package directly.

func Port

func Port(port int) Option

Port sets the host URL for the nats server.

func StanOpts

func StanOpts(opt func(*stanServer.Options)) Option

StanOpts allows setting Options from stan package directly.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL