作者 庄敏学

add

不能预览此文件类型
@@ -13,6 +13,7 @@ func Run() { @@ -13,6 +13,7 @@ func Run() {
13 messageHandlerMap["demo-v1"] = Demo 13 messageHandlerMap["demo-v1"] = Demo
14 //"指定topic" => 对应的处理方法 14 //"指定topic" => 对应的处理方法
15 messageHandlerMap[constant.KAFKA_BUSINESS_TOPIC] = handle.SyncDataBusinessAdmin 15 messageHandlerMap[constant.KAFKA_BUSINESS_TOPIC] = handle.SyncDataBusinessAdmin
  16 + log.Logger.Debug("kafka host: " + constant.KAFKA_HOSTS + " group id:" + constant.KAFKA_GROUP_ID)
16 err := saramaConsumer.StartConsume(constant.KAFKA_HOSTS, constant.KAFKA_GROUP_ID, messageHandlerMap, log.Logger) 17 err := saramaConsumer.StartConsume(constant.KAFKA_HOSTS, constant.KAFKA_GROUP_ID, messageHandlerMap, log.Logger)
17 log.Logger.Error(err.Error()) 18 log.Logger.Error(err.Error())
18 } 19 }