VOL-1481 Removed some logs that put binary in the logs and added in a log for the transaction_id
Change-Id: I945c3c52c94bc815ddd11c00fe2fa717dd77ae43
diff --git a/pyvoltha/adapters/kafka/kafka_inter_container_library.py b/pyvoltha/adapters/kafka/kafka_inter_container_library.py
index 37f11d0..4ef3262 100644
--- a/pyvoltha/adapters/kafka/kafka_inter_container_library.py
+++ b/pyvoltha/adapters/kafka/kafka_inter_container_library.py
@@ -550,9 +550,10 @@
wait_for_result = Deferred()
self.transaction_id_deferred_map[
self._to_string(request.header.id)] = wait_for_result
-
+ log.debug("message-send", transaction_id=transaction_id, to_topic=to_topic,
+ from_topic=reply_topic, kafka_request=request)
yield self._send_kafka_message(to_topic, request)
- log.debug("message-sent", to_topic=to_topic,
+ log.debug("message-sent", transaction_id=transaction_id, to_topic=to_topic,
from_topic=reply_topic, kafka_request=request)
if response_required:
diff --git a/pyvoltha/adapters/kafka/kafka_proxy.py b/pyvoltha/adapters/kafka/kafka_proxy.py
index 85983bc..2885226 100644
--- a/pyvoltha/adapters/kafka/kafka_proxy.py
+++ b/pyvoltha/adapters/kafka/kafka_proxy.py
@@ -292,13 +292,13 @@
endpoint=self.kafka_endpoint)
return
- log.debug('sending-kafka-msg', topic=topic, kafka_msg=msg)
+ log.debug('sending-kafka-msg', topic=topic)
msgs = [msg]
if self.kproducer is not None and self.event_bus_publisher and self.faulty is False:
d = deferToThread(self.kproducer.produce, topic, msg, key)
yield d
- log.debug('sent-kafka-msg', topic=topic, kafka_msg=msg)
+ log.debug('sent-kafka-msg', topic=topic)
# send a lightweight poll to avoid an exception after 100k messages.
d1 = deferToThread(self.kproducer.poll, 0)
yield d1
@@ -307,7 +307,7 @@
except Exception, e:
self.faulty = True
- log.error('failed-to-send-kafka-msg', topic=topic, kafka_msg=msg,
+ log.error('failed-to-send-kafka-msg', topic=topic,
e=e)
# set the kafka producer to None. This is needed if the