diff --git a/consumers/consumerAXYraw.go b/consumers/consumerAXYraw.go index 50be402..2cda1cd 100644 --- a/consumers/consumerAXYraw.go +++ b/consumers/consumerAXYraw.go @@ -8,6 +8,7 @@ import ( "goInOut/dbOperate/_kafka" "goInOut/models" "log" + "os" "sync" "time" ) @@ -118,9 +119,11 @@ func (the *consumerAXYraw) toSink() { } } -const logTagDeviceId = "91da4d1f-fbc7-4dad-bedd-f8ff05c0e0e0" +var logTagDeviceId = "91da4d1f-fbc7-4dad-bedd-f8ff05c0e0e0" func (the *consumerAXYraw) Work() { + logTagDeviceId = os.Getenv("logTagDeviceId") + log.Printf("监控 指定设备 logTagDeviceId=[%s]", logTagDeviceId) go the.sinkTask() go func() { for {