Loading src/common/tools/grpc/BaseEventCollector.py +7 −1 Original line number Diff line number Diff line Loading @@ -47,6 +47,12 @@ class CollectorThread(threading.Thread): if self._log_events_received: str_event = grpc_message_to_json_string(event) LOGGER.info('[_collect] event: {:s}'.format(str_event)) object_name = str(event.__class__.__name__).lower().replace('event', '') if object_name == 'any': object_name = event.WhichOneof('event') _event = getattr(event, object_name) timestamp = _event.event.timestamp.timestamp else: timestamp = event.event.timestamp.timestamp self._events_queue.put_nowait((timestamp, event)) except grpc.RpcError as e: Loading Loading
src/common/tools/grpc/BaseEventCollector.py +7 −1 Original line number Diff line number Diff line Loading @@ -47,6 +47,12 @@ class CollectorThread(threading.Thread): if self._log_events_received: str_event = grpc_message_to_json_string(event) LOGGER.info('[_collect] event: {:s}'.format(str_event)) object_name = str(event.__class__.__name__).lower().replace('event', '') if object_name == 'any': object_name = event.WhichOneof('event') _event = getattr(event, object_name) timestamp = _event.event.timestamp.timestamp else: timestamp = event.event.timestamp.timestamp self._events_queue.put_nowait((timestamp, event)) except grpc.RpcError as e: Loading