nats

package
v0.1.18 Latest Latest
Warning

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

Go to latest
Published: Aug 8, 2023 License: LGPL-2.1 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Install = definePlugin.Install

Install 安装插件

View Source
var Uninstall = definePlugin.Uninstall

Uninstall 卸载插件

Functions

This section is empty.

Types

type BrokerOption

type BrokerOption func(options *BrokerOptions)

type BrokerOptions

type BrokerOptions struct {
	NatsClient    *nats.Conn
	TopicPrefix   string
	QueuePrefix   string
	FastAddresses []string
	FastUsername  string
	FastPassword  string
}

type WithOption

type WithOption struct{}

func (WithOption) Default

func (WithOption) Default() BrokerOption

func (WithOption) FastAddresses

func (WithOption) FastAddresses(addrs ...string) BrokerOption

func (WithOption) FastAuth

func (WithOption) FastAuth(username, password string) BrokerOption

func (WithOption) NatsClient

func (WithOption) NatsClient(cli *nats.Conn) BrokerOption

func (WithOption) QueuePrefix

func (WithOption) QueuePrefix(prefix string) BrokerOption

func (WithOption) TopicPrefix

func (WithOption) TopicPrefix(prefix string) BrokerOption

Jump to

Keyboard shortcuts

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