nats_jetstream

package
v1.2.0 Latest Latest
Warning

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

Go to latest
Published: Jan 26, 2022 License: MIT Imports: 22 Imported by: 0

Documentation

Index

Constants

View Source
const BackendName = "nats-jetstream"

Variables

View Source
var (
	ErrMissingTLSKey  = errors.New("--tls-client-key-file cannot be blank if using ssl")
	ErrMissingTlsCert = errors.New("--tls-client-cert-file cannot be blank if using ssl")
	ErrMissingTLSCA   = errors.New("--tls-ca-file cannot be blank if using ssl")
	ErrMissingStream  = errors.New("--stream cannot be empty")
)

Functions

This section is empty.

Types

type NatsJetstream

type NatsJetstream struct {
	// contains filtered or unexported fields
}

func New

func New(connOpts *opts.ConnectionOptions) (*NatsJetstream, error)

func (*NatsJetstream) Close

func (n *NatsJetstream) Close(_ context.Context) error

func (*NatsJetstream) DisplayError

func (n *NatsJetstream) DisplayError(msg *records.ErrorRecord) error

DisplayError will parse an Error record and print (pretty) output to STDOUT

func (*NatsJetstream) DisplayMessage

func (n *NatsJetstream) DisplayMessage(cliOpts *opts.CLIOptions, msg *records.ReadRecord) error

DisplayMessage will parse a Read record and print (pretty) output to STDOUT

func (*NatsJetstream) Dynamic

func (n *NatsJetstream) Dynamic(ctx context.Context, dynamicOpts *opts.DynamicOptions, dynamicSvc dynamic.IDynamic) error

func (*NatsJetstream) Name

func (n *NatsJetstream) Name() string

func (*NatsJetstream) Read

func (n *NatsJetstream) Read(ctx context.Context, readOpts *opts.ReadOptions, resultsChan chan *records.ReadRecord, errorChan chan *records.ErrorRecord) error

func (*NatsJetstream) Relay

func (n *NatsJetstream) Relay(ctx context.Context, relayOpts *opts.RelayOptions, relayCh chan interface{}, _ chan *records.ErrorRecord) error

func (*NatsJetstream) Test

func (n *NatsJetstream) Test(_ context.Context) error

func (*NatsJetstream) Write

func (n *NatsJetstream) Write(_ context.Context, writeOpts *opts.WriteOptions, errorCh chan *records.ErrorRecord, messages ...*records.WriteRecord) error

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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