...
|
...
|
@@ -24,12 +24,12 @@ func main() { |
|
|
beego.Run()
|
|
|
}()
|
|
|
consumerRun := consumer.NewRuner()
|
|
|
if err := consumerRun.InitConsumer(); err != nil {
|
|
|
logs.Error("启动kafka消息消费者失败:%s", err)
|
|
|
}
|
|
|
wg := &sync.WaitGroup{}
|
|
|
wg.Add(1)
|
|
|
go func() {
|
|
|
if err := consumerRun.InitConsumer(); err != nil {
|
|
|
logs.Error("启动kafka消息消费者失败:%s", err)
|
|
|
}
|
|
|
consumerRun.Start(ctx)
|
|
|
wg.Done()
|
|
|
}()
|
...
|
...
|
|