def add_on_connection_close_callback(self):
        self.lg("Adding connection close callback", 6)
        self.m_connection.add_on_close_callback(self.on_connection_closed)
    
    # end of add_on_connection_close_callback
This method adds an on close callback that will be invoked by pika
dataset/ETHPy150Open GetLevvel/message-simulator/src/rabbit_message_publisher.py/RabbitMessagePublisher.add_on_connection_close_callback