chore(queue): support NSQ as backend. (#600)

This commit is contained in:
Bo-Yi Wu
2021-07-17 20:14:19 +08:00
committed by GitHub
parent c7112a6eb3
commit 2e2dd9b8d6
18 changed files with 272 additions and 12 deletions

View File

@@ -250,6 +250,11 @@ func handleNotification(ctx context.Context, cfg config.ConfYaml, req gorush.Req
var count int
wg := sync.WaitGroup{}
newNotification := []*gorush.PushNotification{}
if cfg.Core.Sync && !core.IsLocalQueue(core.Queue(cfg.Queue.Engine)) {
cfg.Core.Sync = false
}
for i := range req.Notifications {
notification := &req.Notifications[i]
switch notification.Platform {