serum-vial
Advanced tools
Comparing version 1.1.1 to 1.1.2
@@ -296,3 +296,3 @@ "use strict"; | ||
this.onAccountsChange({ reset: true }); | ||
const delayMs = this._retriesCount > 0 ? this._retriesCount * this._retriesCount * 300 : 0; | ||
const delayMs = this._retriesCount > 0 ? Math.min(Math.pow(2, this._retriesCount) * 1000, 32 * 1000) : 0; | ||
logger_1.logger.log('info', 'Restarting RPC WebSocket connection...', { market: this._options.marketName, delayMs }); | ||
@@ -372,3 +372,3 @@ if (delayMs > 0) { | ||
if (this._receivedMessagesCount === 0) { | ||
logger_1.logger.log('info', `Did not received any messages within 60s timeout, terminating connection...`, { | ||
logger_1.logger.log('info', `Did not received any messages within 120s timeout, terminating connection...`, { | ||
market: this._options.marketName | ||
@@ -379,3 +379,3 @@ }); | ||
this._receivedMessagesCount = 0; | ||
}, 60 * 1000); | ||
}, 120 * 1000); | ||
} | ||
@@ -382,0 +382,0 @@ _sendMessage(ws, message) { |
{ | ||
"name": "serum-vial", | ||
"version": "1.1.1", | ||
"version": "1.1.2", | ||
"engines": { | ||
@@ -5,0 +5,0 @@ "node": ">=15" |
@@ -400,3 +400,3 @@ import { Market } from '@project-serum/serum' | ||
const delayMs = this._retriesCount > 0 ? this._retriesCount * this._retriesCount * 300 : 0 | ||
const delayMs = this._retriesCount > 0 ? Math.min(Math.pow(2, this._retriesCount) * 1000, 32 * 1000) : 0 | ||
@@ -489,3 +489,3 @@ logger.log('info', 'Restarting RPC WebSocket connection...', { market: this._options.marketName, delayMs }) | ||
if (this._receivedMessagesCount === 0) { | ||
logger.log('info', `Did not received any messages within 60s timeout, terminating connection...`, { | ||
logger.log('info', `Did not received any messages within 120s timeout, terminating connection...`, { | ||
market: this._options.marketName | ||
@@ -497,3 +497,3 @@ }) | ||
this._receivedMessagesCount = 0 | ||
}, 60 * 1000) | ||
}, 120 * 1000) | ||
} | ||
@@ -500,0 +500,0 @@ |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
277811