mqtt

package
v0.3.0 Latest Latest
Warning

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

Go to latest
Published: Jan 28, 2026 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

View Source
const ClientPrefix = "signal-api-receiver"

Variables

View Source
var (
	// ErrMqttConnectionAttempt is thrown when MQTT connection attempt has failed.
	ErrMqttConnectionAttempt = errors.New("mqtt connection attempt error")

	// ErrMqttConnectionFailed is thrown when waiting for connection has failed.
	ErrMqttConnectionFailed = errors.New("mqtt connection error")
)
View Source
var QosValues = []int{0, 1, 2}

Functions

func Init

func Init(
	ctx context.Context,
	notifier *receiver.MessageNotifier,
	config InitConfig,
) error

func MakeClientID

func MakeClientID(localAddr *net.TCPAddr) string

Types

type InitConfig

type InitConfig struct {
	Server      string
	ClientID    string
	User        string
	Password    string
	TopicPrefix string
	Qos         int
}

Jump to

Keyboard shortcuts

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