diff --git a/puppet/zulip_ops/files/nagios3/conf.d/services.cfg b/puppet/zulip_ops/files/nagios3/conf.d/services.cfg index 7626705c9e..744282a305 100644 --- a/puppet/zulip_ops/files/nagios3/conf.d/services.cfg +++ b/puppet/zulip_ops/files/nagios3/conf.d/services.cfg @@ -393,10 +393,27 @@ define service { contact_groups admins } -# The following queue workers batch-process events and thus can't be -# monitored by checking for running consumers: -# -# user_activity, missedmessage_emails +define service { + use generic-service + service_description Check rabbitmq missedmessage email consumers + check_command check_rabbitmq_consumers!missedmessage_email + # Workaround weird checks 40s after first error causing alerts + # from a single failure because cron hasn't run again yet + max_check_attempts 3 + hostgroup_name frontends + contact_groups admins +} + +define service { + use generic-service + service_description Check rabbitmq user activity consumers + check_command check_rabbitmq_consumers!user_activity + # Workaround weird checks 40s after first error causing alerts + # from a single failure because cron hasn't run again yet + max_check_attempts 3 + hostgroup_name frontends + contact_groups admins +} define service { use generic-service diff --git a/zerver/worker/queue_processors.py b/zerver/worker/queue_processors.py index ffa3c882a3..80aaf2de77 100644 --- a/zerver/worker/queue_processors.py +++ b/zerver/worker/queue_processors.py @@ -434,7 +434,7 @@ class ConfirmationEmailWorker(QueueProcessingWorker): context=context, delay=datetime.timedelta(days=settings.INVITATION_LINK_VALIDITY_DAYS - 2)) -@assign_queue('user_activity', queue_type="loop") +@assign_queue('user_activity') class UserActivityWorker(LoopQueueProcessingWorker): """The UserActivity queue is perhaps our highest-traffic queue, and requires some care to ensure it performs adequately. @@ -515,7 +515,7 @@ class UserPresenceWorker(QueueProcessingWorker): status = event["status"] do_update_user_presence(user_profile, client, log_time, status) -@assign_queue('missedmessage_emails', queue_type="loop") +@assign_queue('missedmessage_emails') class MissedMessageWorker(QueueProcessingWorker): # Aggregate all messages received over the last BATCH_DURATION # seconds to let someone finish sending a batch of messages and/or