Event handler

def handle(client_message, handle_event_topic=None, to_object=None):
    """ Event handler """
    message_type = client_message.get_message_type()
    if message_type == EVENT_TOPIC and handle_event_topic is not None:
        item = client_message.read_data()
        publish_time = client_message.read_long()
        uuid = client_message.read_str()
        handle_event_topic(item=item, publish_time=publish_time, uuid=uuid)