From 7e9328fc588710d4ddc0c10f44cafe759ed9526d Mon Sep 17 00:00:00 2001 From: Christopher Fullarton Date: Mon, 9 Sep 2019 18:26:08 +0200 Subject: [PATCH] Adds checks if the amqp channel has an error and inits the connection again --- src/db/AMQPConnector.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/src/db/AMQPConnector.ts b/src/db/AMQPConnector.ts index 2e53bf1..1a0039c 100644 --- a/src/db/AMQPConnector.ts +++ b/src/db/AMQPConnector.ts @@ -34,6 +34,7 @@ class AMQPConnector { this._channel = await this._connection.createChannel(); this._channel.on('error', error => { console.error('Exception in amqp channel occured', error); + this.initConnection(); }); } } -- 2.23.0.rc1