def child_exit(server, worker): if os.environ.get("prometheus_multiproc_dir", False): from prometheus_flask_exporter.multiprocess import ( GunicornInternalPrometheusMetrics, ) GunicornInternalPrometheusMetrics.mark_process_dead_on_child_exit( worker.pid)
def child_exit(server, worker): GunicornInternalPrometheusMetrics.mark_process_dead_on_child_exit(worker.pid)
def child_exit(server, worker): # pylint: disable=unused-argument """ Clean up prometheus metrics when a worker dies """ GunicornInternalPrometheusMetrics.mark_process_dead_on_child_exit(worker.pid)