clients

package
v0.4.3 Latest Latest
Warning

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

Go to latest
Published: Apr 26, 2023 License: AGPL-3.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (

	// MqttSetOnConnectHandler 如果会话断开可以通过该回调函数来重新订阅消息
	//不使用mqtt的clean session是因为会话保持期间共享订阅也会给离线的客户端,这会导致在线的客户端丢失消息
	MqttSetOnConnectHandler func()
)

Functions

func NewMqttClient

func NewMqttClient(conf *conf.MqttConf) (mc mqtt.Client, err error)

func NewNatsClient

func NewNatsClient(conf conf.NatsConf) (nc *nats.Conn, err error)

Types

type Td

type Td struct {
	Dsn string
	*sql.DB
}

func NewTDengine

func NewTDengine(DataSource string) (*Td, error)

Jump to

Keyboard shortcuts

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