Send count of sent letters to performance platform

Now we’ve been sending real letters for quite a while it would be nice
to show how many.
This commit is contained in:
Chris Hill-Scott
2018-03-02 16:05:26 +00:00
parent d4db959a55
commit 7e1aa03371
3 changed files with 16 additions and 1 deletions

View File

@@ -221,6 +221,7 @@ def send_total_sent_notifications_to_performance_platform():
count_dict = total_sent_notifications.get_total_sent_notifications_yesterday()
email_sent_count = count_dict.get('email').get('count')
sms_sent_count = count_dict.get('sms').get('count')
letter_sent_count = count_dict.get('letter').get('count')
start_date = count_dict.get('start_date')
current_app.logger.info(
@@ -240,6 +241,12 @@ def send_total_sent_notifications_to_performance_platform():
email_sent_count
)
total_sent_notifications.send_total_notifications_sent_for_day_stats(
start_date,
'letter',
letter_sent_count
)
@notify_celery.task(name='switch-current-sms-provider-on-slow-delivery')
@statsd(namespace="tasks")