mirror of
https://github.com/GSA/notifications-api.git
synced 2025-12-21 07:51:13 -05:00
Merge pull request #3434 from alphagov/prom-celery
disable prometheus writing to files from celery apps
This commit is contained in:
@@ -2,6 +2,11 @@
|
||||
|
||||
from flask import Flask
|
||||
|
||||
# import prometheus before any other code. If gds_metrics is imported first it will write a prometheus file to disk
|
||||
# that will never be read from (since we don't have prometheus celery stats). If prometheus is imported first,
|
||||
# prometheus will simply store the metrics in memory
|
||||
import prometheus_client # noqa
|
||||
|
||||
# notify_celery is referenced from manifest_delivery_base.yml, and cannot be removed
|
||||
from app import notify_celery, create_app # noqa
|
||||
|
||||
|
||||
Reference in New Issue
Block a user