mirror of
https://github.com/GSA/notifications-api.git
synced 2026-07-09 10:53:55 -04:00
change countdown from 30 to 60 seconds for message sends to better match batch insert timing
This commit is contained in:
@@ -324,7 +324,7 @@ def batch_insert_notifications(self):
|
||||
current_app.logger.exception("Notification batch insert failed")
|
||||
for n in batch:
|
||||
# Use 'created_at' as a TTL so we don't retry infinitely
|
||||
if datetime.fromisoformat(n.created_at) < utc_now() - timedelta(minutes=1):
|
||||
if datetime.fromisoformat(n.created_at) < utc_now() - timedelta(seconds=50):
|
||||
current_app.logger.warning(
|
||||
f"Abandoning stale data, could not write to db: {n.serialize_for_redis(n)}"
|
||||
)
|
||||
|
||||
@@ -256,7 +256,7 @@ def save_sms(self, service_id, notification_id, encrypted_notification, sender_i
|
||||
)
|
||||
)
|
||||
provider_tasks.deliver_sms.apply_async(
|
||||
[str(saved_notification.id)], queue=QueueNames.SEND_SMS, countdown=30
|
||||
[str(saved_notification.id)], queue=QueueNames.SEND_SMS, countdown=60
|
||||
)
|
||||
|
||||
current_app.logger.debug(
|
||||
|
||||
Reference in New Issue
Block a user