mirror of
https://github.com/GSA/notifications-api.git
synced 2026-02-02 17:31:14 -05:00
Tweak sending time metrics to only include live notifications
Changes the high volume and not high volume metrics to both only include non test notifications. This is because when looking at the grafana metrics, it was impossible to tell what affect the high volume/non high volume effect was having vs the test/live notification effect. This leaves us with no break down of high volume/not high volume sending times for test notifications but I don't think we really need that.
This commit is contained in:
@@ -80,11 +80,10 @@ def send_sms_to_provider(notification):
|
||||
statsd_client.timing("sms.test-key.total-time", delta_seconds)
|
||||
else:
|
||||
statsd_client.timing("sms.live-key.total-time", delta_seconds)
|
||||
|
||||
if service.id in current_app.config.get('HIGH_VOLUME_SERVICE'):
|
||||
statsd_client.timing("sms.high-volume.total-time", delta_seconds)
|
||||
else:
|
||||
statsd_client.timing("sms.not-high-volume.total-time", delta_seconds)
|
||||
if service.id in current_app.config.get('HIGH_VOLUME_SERVICE'):
|
||||
statsd_client.timing("sms.live-key.high-volume.total-time", delta_seconds)
|
||||
else:
|
||||
statsd_client.timing("sms.live-key.not-high-volume.total-time", delta_seconds)
|
||||
|
||||
|
||||
def send_email_to_provider(notification):
|
||||
@@ -136,11 +135,10 @@ def send_email_to_provider(notification):
|
||||
statsd_client.timing("email.test-key.total-time", delta_seconds)
|
||||
else:
|
||||
statsd_client.timing("email.live-key.total-time", delta_seconds)
|
||||
|
||||
if service.id in current_app.config.get('HIGH_VOLUME_SERVICE'):
|
||||
statsd_client.timing("email.high-volume.total-time", delta_seconds)
|
||||
else:
|
||||
statsd_client.timing("email.not-high-volume.total-time", delta_seconds)
|
||||
if service.id in current_app.config.get('HIGH_VOLUME_SERVICE'):
|
||||
statsd_client.timing("email.live-key.high-volume.total-time", delta_seconds)
|
||||
else:
|
||||
statsd_client.timing("email.live-key.not-high-volume.total-time", delta_seconds)
|
||||
|
||||
|
||||
def update_notification_to_sending(notification, provider):
|
||||
|
||||
Reference in New Issue
Block a user