@seidor-cloud-produtos/orbit-backend-lib 2.0.121 → 2.0.122
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -34,6 +34,7 @@ class AmqpQueue {
|
|
|
34
34
|
setSocketOptions(socketOptions) {
|
|
35
35
|
this.socketOptions = {
|
|
36
36
|
maxStoredMessagesOnError: 500,
|
|
37
|
+
heartbeat: 60,
|
|
37
38
|
...(socketOptions || {}),
|
|
38
39
|
};
|
|
39
40
|
return this;
|
|
@@ -349,6 +350,7 @@ class AmqpQueue {
|
|
|
349
350
|
async treatReconnection(vHost) {
|
|
350
351
|
this.logger.info('⛔ Connection Error!!');
|
|
351
352
|
this.logger.info(`🔄 Try connection to the vHost ${vHost}`);
|
|
353
|
+
await this.close().catch(() => null);
|
|
352
354
|
await this.connect(vHost);
|
|
353
355
|
await this.reconnectionChannels();
|
|
354
356
|
await this.publishMessagesOfMemory();
|