feat 初始化
This commit is contained in:
5
topic/define.go
Normal file
5
topic/define.go
Normal file
@@ -0,0 +1,5 @@
|
||||
package topic
|
||||
|
||||
const (
|
||||
namePostSms = "post.sms.send" // 发送短信
|
||||
)
|
||||
15
topic/template.go
Normal file
15
topic/template.go
Normal file
@@ -0,0 +1,15 @@
|
||||
package topic
|
||||
|
||||
import "context"
|
||||
|
||||
type Template struct {
|
||||
MessageSn int64 `json:"messageSn"` // 消息序列号
|
||||
}
|
||||
|
||||
func (t *Template) Name() string {
|
||||
return namePostSms
|
||||
}
|
||||
|
||||
func (t *Template) OnMessage(_ context.Context) error {
|
||||
return nil
|
||||
}
|
||||
Reference in New Issue
Block a user