[SEBA-930] update GRPC version to 1.27 and change kafka message producing
Change-Id: I14145a1351eb2523fa54e66381ad97abc5eedf50
diff --git a/main.go b/main.go
index c27b8e2..4ccce34 100644
--- a/main.go
+++ b/main.go
@@ -261,14 +261,11 @@
data := s.get_status(ip_address, resource)
for _, str := range data {
str = "Device IP: " + ip_address + " " + str
- fmt.Printf("collected data %s\n ...", str)
+ logrus.Infof("collected data %s", str)
b := []byte(str)
msg := &sarama.ProducerMessage{Topic: importerTopic, Value: sarama.StringEncoder(b)}
- select {
- case s.dataproducer.Input() <- msg:
- logrus.Info("Produce message")
- default:
- }
+ s.dataproducer.Input() <- msg
+ logrus.Info("Produce message")
}
}
case <-donechan: