def METHOD_NAME(server_process, metrics, interval, socket):
    """ Monitor the metrics of server_process and its child processes
    """
    while True:
        message = []
        collected_metrics = get_metrics(server_process, get_child_processes(server_process), logger)
        metrics_msg = []
        for metric in metrics:
            message.append(str(collected_metrics.get(metric, 0)))
            if collected_metrics.get(metric) is not None:
                metrics_msg.append("{0} : {1}".format(metric, collected_metrics.get(metric, 0)))
        message = "\t".join(message) + "\t\n"
        logger.info("%s", " -- ".join(metrics_msg))
        if socket:
            try:
                socket.send(message.encode("latin-1"))
            except BrokenPipeError:
                logger.info("Stopping monitoring as socket connection is closed.")
                break
        # TODO - log metrics to a file METRICS_LOG_FILE if METRICS_LOG_FILE is provided
        gevent.sleep(interval)