def METHOD_NAME(
        sub_id: str,
        shutdown: threading.Event,
        channel: connection.Connection,
        callback: Callable[[Dict[str, Any]], None],
) -> None:
    while not shutdown.is_set():
        try:
            if channel.poll(timeout=1):
                ev = channel.recv()
                if ev['event_name'] == eventNames.SUBSCRIBED:
                    logger.info(
                        'Subscriber#{0} subscribe ack received'.format(
                            sub_id,
                        ),
                    )
                elif ev['event_name'] == eventNames.UNSUBSCRIBED:
                    logger.info(
                        'Subscriber#{0} unsubscribe ack received'.format(
                            sub_id,
                        ),
                    )
                    break
                elif ev['event_name'] == eventNames.DISPATCHER_SHUTDOWN:
                    logger.info(
                        'Subscriber#{0} received dispatcher shutdown event'.format(
                            sub_id,
                        ),
                    )
                    break
                else:
                    callback(ev)
        except queue.Empty:
            pass
        except EOFError:
            break
        except KeyboardInterrupt:
            break
    logger.debug('bbye!!!')