Skip to content
Snippets Groups Projects
Commit c688687d authored by Lluis Gifre Renom's avatar Lluis Gifre Renom
Browse files

Minor bug fixes

parent 41a97970
No related branches found
No related tags found
1 merge request!320Resolve "(CTTC) Telemetry Enhancement"
......@@ -55,11 +55,9 @@ class KpiValueWriter(GenericGrpcService):
if raw_kpi is None:
continue
elif raw_kpi.error():
if raw_kpi.error().code() == KafkaError._PARTITION_EOF:
continue
else:
if raw_kpi.error().code() != KafkaError._PARTITION_EOF:
print("Consumer error: {}".format(raw_kpi.error()))
continue
continue
try:
kpi_value = json.loads(raw_kpi.value().decode('utf-8'))
LOGGER.info("Received KPI : {:}".format(kpi_value))
......@@ -79,5 +77,5 @@ class KpiValueWriter(GenericGrpcService):
metric_writer.create_and_expose_cooked_kpi(kpi_descriptor_object, kpi_value)
else:
LOGGER.info("No KPI Descriptor found in Database for Kpi ID: {:}".format(kpi_id))
except Exception as e:
LOGGER.info("Unable to get KpiDescriptor. Error: {:}".format(e))
except:
LOGGER.exception("Unable to get KpiDescriptor")
......@@ -64,6 +64,8 @@ RUN python3 -m pip install -r requirements.txt
WORKDIR /var/teraflow
COPY src/context/__init__.py context/__init__.py
COPY src/context/client/. context/client/
COPY src/device/__init__.py device/__init__.py
COPY src/device/client/. device/client/
COPY src/kpi_manager/client/. kpi_manager/client/
COPY src/kpi_manager/__init__.py kpi_manager/__init__.py
COPY src/telemetry/__init__.py telemetry/__init__.py
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment