作者 庄敏学

kafka

不能预览此文件类型
  1 +package service
  2 +
  3 +type AuthService struct {
  4 +}
@@ -11,7 +11,7 @@ import ( @@ -11,7 +11,7 @@ import (
11 11
12 func Run() { 12 func Run() {
13 messageHandlerMap := make(map[string]func(message *sarama.ConsumerMessage) error) 13 messageHandlerMap := make(map[string]func(message *sarama.ConsumerMessage) error)
14 - messageHandlerMap["demo-v1"] = Demo 14 + //messageHandlerMap["demo-v1"] = Demo
15 //"指定topic" => 对应的处理方法 15 //"指定topic" => 对应的处理方法
16 messageHandlerMap[constant.KAFKA_BUSINESS_TOPIC] = handle.SyncDataBusinessAdmin 16 messageHandlerMap[constant.KAFKA_BUSINESS_TOPIC] = handle.SyncDataBusinessAdmin
17 hosts := strings.Split(constant.KAFKA_HOSTS, ",") 17 hosts := strings.Split(constant.KAFKA_HOSTS, ",")