fix:处理了边界情况

This commit is contained in:
Amnesia
2026-03-14 18:57:02 +08:00
parent 39243c14d7
commit 9eed15efd5
5 changed files with 23 additions and 18 deletions

View File

@@ -130,6 +130,10 @@ func SetRouter(db *gorm.DB, cache *rediscache.Client, rmq *rabbitmq.RabbitMQ) *g
}
//worker
timelineMQ, err := rabbitmq.NewTimelineMQ(rmq)
if err != nil {
log.Printf("timelineMQ init failed (mq disabled): %v", err)
socialMQ = nil
}
worker.StartOutboxPoller(db, timelineMQ)
worker.StartConsumer(timelineMQ, "video.timeline.update.queue", cache)
return r