msq

package
v0.7.0 Latest Latest
Warning

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

Go to latest
Published: Mar 26, 2023 License: GPL-2.0 Imports: 5 Imported by: 0

README

消息

  1. 会员更新
push 

Documentation

Index

Constants

View Source
const (
	// MemberUpdated 会员创建或更新
	MemberUpdated = "go2o-member-updated"
	// MemberAccountUpdated 会员账户更新
	MemberAccountUpdated = "go2o-member-account-updated"
	// MemberAccountLogTopic 会员账户日志订阅
	MemberAccountLogTopic = "go2o-member-account-log-topic"
	// MemberWithdrawalTopic 用户提现
	MembertWithdrawalTopic = "go2o-member-withdrawal-topic"
	// NormalOrderStatusTopic 普通订单状态变更
	NormalOrderStatusTopic = "go2o-normal-order-status-topic"
	// NormalOrderAffiliateTopic 订单分销
	NormalOrderAffiliateTopic = "go2o-normal-order-affiliate-topic"
	// RegistryTopic 自定义键值变更订阅
	RegistryTopic = "go2o-registry-topic"
	// SendSmsTopic 发送短信
	SendSmsTopic = "go2o-send-sms-topic"
)
View Source
const KAFKA = 2
View Source
const NATS = 1
View Source
const REDIS = 3

Variables

This section is empty.

Functions

func Close

func Close()

Close 关闭生产者

func Configure

func Configure(mqType int, address []string) error

Configure 设置

func Push

func Push(topic string, message string) error

Push 推送消息

func PushDelay

func PushDelay(topic string, message string, delay int) error

PushDelay 延迟推送消息

Types

type Producer

type Producer interface {
	// Push 推送消息
	Push(topic string, message string) error
	// Close 关闭生产者
	Close()
}

Jump to

Keyboard shortcuts

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