mirror of
https://github.com/zulip/zulip.git
synced 2025-11-05 14:35:27 +00:00
queue: Log how long it takes to connect to rabbitmq.
(imported from commit be3cd9da5e7c213cfed62feda2e676038ade57a6)
This commit is contained in:
@@ -25,9 +25,10 @@ class SimpleQueueClient(object):
|
||||
self._connect()
|
||||
|
||||
def _connect(self):
|
||||
start = time.time()
|
||||
self.connection = pika.BlockingConnection(self._get_parameters())
|
||||
self.channel = self.connection.channel()
|
||||
self.log.info('SimpleQueueClient connected')
|
||||
self.log.info('SimpleQueueClient connected (connecting took %.3fs)' % (time.time() - start,))
|
||||
|
||||
def _reconnect(self):
|
||||
self.connection = None
|
||||
|
||||
Reference in New Issue
Block a user