(connection: Connection, queue: Queue)
Run a task that reads multipart messages: topic, data.

    This is the publisher server. Clients connect using zmq.PUSH pattern and
    send messages to topics. Each topic, data pair is enqueued in queue.

    :param connection: The network connection.
    :param queue: Queue for received messages.
    :return: None
Run a task that reads multipart messages: topic, data.
Run a task that reads multipart messages : topic data .
async def _publisher_server_task(connection: Connection, queue: Queue) -> None:
    """
    Run a task that reads multipart messages: topic, data.

    This is the publisher server. Clients connect using zmq.PUSH pattern and
    send messages to topics. Each topic, data pair is enqueued in queue.

    :param connection: The network connection.
    :param queue: Queue for received messages.
    :return: None
    """
    try:
        while True:
            m = await connection.recv_multipart()
            log.debug("Event: %s", m)
            await queue.put(m)
    except asyncio.CancelledError:
        log.exception("Done")
    finally:
        connection.close()
async def _publisher_server_task ( connection : Connection , queue : Queue ) -> None : try : while True : m = await connection . recv_multipart ( ) log . debug ( "Event: %s" , m ) await queue . put ( m ) except asyncio . CancelledError : log . exception ( "Done" ) finally : connection . close ( )