def METHOD_NAME(
    monitor: zmq.asyncio.Socket, loop: asyncio.BaseEventLoop
) -> None:
    """A thread that prints events
    This is a convenience method. It could serve as an example for your code of a monitor,
    For example if you don't need the prints, then copy paste this part of code to your code and modify it to your needs.
    parameters:
    monitor: a zmq monitor socket, from calling:  my_zmq_socket.get_monitor_socket()
    loop: an asyncio event loop, from calling zmq.asyncio.asyncio.get_event_loop() , whens starting a thread it does not contains an event loop
    """
    print("libzmq-%s" % zmq.zmq_version())
    if zmq.zmq_version_info() < (4, 0):
        raise RuntimeError("monitoring in libzmq version < 4.0 is not supported")
    EVENT_MAP = {}
    print("Event names:")
    for name in dir(zmq):
        if name.startswith('EVENT_'):
            value = getattr(zmq, name)
            print("%21s : %4i" % (name, value))
            EVENT_MAP[value] = name
    print("\n")
    asyncio.set_event_loop(loop)
    async def run_loop() -> None:
        while True:
            try:
                while monitor.poll():
                    evt: Dict[str, Any] = {}
                    mon_evt = await recv_monitor_message(monitor)
                    evt.update(mon_evt)
                    evt['description'] = EVENT_MAP[evt['event']]
                    print(f"Event: {evt}")
                    if evt['event'] == zmq.EVENT_MONITOR_STOPPED:
                        break
            except RuntimeError as e:
                print(e)
                time.sleep(1)
        monitor.close()
        print()
        print("event monitor thread done!")
    asyncio.ensure_future(run_loop())