This method closes the connection to RabbitMQ.
(self)
| 91 | self.channel.close() |
| 92 | |
| 93 | def close_connection(self): |
| 94 | """This method closes the connection to RabbitMQ.""" |
| 95 | if self.connection is not None: |
| 96 | logger.info('Closing connection') |
| 97 | self.connection.close() |
| 98 | |
| 99 | def on_connection_closed(self, _unused_connection, reason): |
| 100 | """This method is invoked by pika when the connection to RabbitMQ is |