@@ -464,7 +464,6 @@ const retrieveExchanges = require('./snapshots/exchanges/retrieveExchanges'),
464464 SymbolParser = require ( './../utilities/parsers/SymbolParser' ) ;
465465const DiagnosticsControllerBase = require ( './diagnostics/DiagnosticsControllerBase' ) ;
466466const LoggerFactory = require ( './../logging/LoggerFactory' ) ;
467- const version = require ( './../meta' ) . version ;
468467module . exports = ( ( ) => {
469468 'use strict' ;
470469
@@ -518,6 +517,7 @@ module.exports = (() => {
518517 let __connectionCount = 0 ;
519518 let __paused = false ;
520519 let __reconnectAllowed = false ;
520+ let __reconnectToken = null ;
521521 let __pollingFrequency = null ;
522522 let __extendedProfile = false ;
523523 let __extendedQuote = false ;
@@ -620,6 +620,10 @@ module.exports = (() => {
620620 event : 'disconnecting'
621621 } ) ;
622622 __reconnectAllowed = false ;
623+ if ( __reconnectToken !== null ) {
624+ clearTimeout ( __reconnectToken ) ;
625+ __reconnectToken = null ;
626+ }
623627 __loginInfo . mode = null ;
624628 __loginInfo . hostname = null ;
625629 __loginInfo . username = null ;
@@ -782,9 +786,12 @@ module.exports = (() => {
782786 }
783787 if ( __reconnectAllowed ) {
784788 __logger . log ( `Connection [ ${ __instance } ]: Scheduling reconnect attempt.` ) ;
785- const reconnectAction = ( ) => connect ( __loginInfo . hostname , __loginInfo . username , __loginInfo . password , __loginInfo . jwtProvider ) ;
789+ const reconnectAction = ( ) => {
790+ connect ( __loginInfo . hostname , __loginInfo . username , __loginInfo . password , __loginInfo . jwtProvider ) ;
791+ __reconnectToken = null ;
792+ } ;
786793 const reconnectDelay = _RECONNECT_INTERVAL + Math . floor ( Math . random ( ) * _WATCHDOG_INTERVAL ) ;
787- setTimeout ( reconnectAction , reconnectDelay ) ;
794+ __reconnectToken = setTimeout ( reconnectAction , reconnectDelay ) ;
788795 }
789796 } ;
790797 __connection . onmessage = event => {
@@ -2167,7 +2174,7 @@ module.exports = (() => {
21672174 return Connection ;
21682175} ) ( ) ;
21692176
2170- } , { "./../logging/LoggerFactory" :15 , "./../meta" : 22 , "./../ utilities/parse/ddf/message" :38 , "./../utilities/parsers/SymbolParser" :41 , "./ConnectionBase" :3 , "./diagnostics/DiagnosticsControllerBase" :7 , "./snapshots/exchanges/retrieveExchanges" :8 , "./snapshots/profiles/retrieveExtensions" :9 , "./snapshots/quotes/retrieveExtensions" :10 , "./snapshots/quotes/retrieveSnapshots" :11 , "@barchart/common-js/lang/array" :51 , "@barchart/common-js/lang/assert" :52 , "@barchart/common-js/lang/object" :54 } ] , 3 :[ function ( require , module , exports ) {
2177+ } , { "./../logging/LoggerFactory" :15 , "./../utilities/parse/ddf/message" :38 , "./../utilities/parsers/SymbolParser" :41 , "./ConnectionBase" :3 , "./diagnostics/DiagnosticsControllerBase" :7 , "./snapshots/exchanges/retrieveExchanges" :8 , "./snapshots/profiles/retrieveExtensions" :9 , "./snapshots/quotes/retrieveExtensions" :10 , "./snapshots/quotes/retrieveSnapshots" :11 , "@barchart/common-js/lang/array" :51 , "@barchart/common-js/lang/assert" :52 , "@barchart/common-js/lang/object" :54 } ] , 3 :[ function ( require , module , exports ) {
21712178const is = require ( '@barchart/common-js/lang/is' ) ;
21722179const Environment = require ( './../environment/Environment' ) ,
21732180 EnvironmentForBrowsers = require ( './../environment/EnvironmentForBrowsers' ) ;
@@ -5420,7 +5427,7 @@ module.exports = (() => {
54205427 'use strict' ;
54215428
54225429 return {
5423- version : '6.3.1 '
5430+ version : '6.3.2 '
54245431 } ;
54255432} ) ( ) ;
54265433
0 commit comments