require ( 'dotenv' ) . config ( ) ; import scClusterBrokerClient from 'scc-broker-client' ; import SCBroker from 'socketcluster/scbroker' ; class Broker extends SCBroker { public run ( ) { console . log ( '   >> Broker PID:' , process . pid ) ; if ( this . options . clusterStateServerHost ) { scClusterBrokerClient . attach ( this , { authKey : this . options . clusterAuthKey , clientPoolSize : this . options . clusterClientPoolSize , mappingEngine : this . options . clusterMappingEngine , stateServerAckTimeout : this . options . clusterStateServerAckTimeout , stateServerConnectTimeout : this . options . clusterStateServerConnectTimeout , stateServerHost : this . options . clusterStateServerHost , stateServerPort : this . options . clusterStateServerPort , stateServerReconnectRandomness : this . options . clusterStateServerReconnectRandomness } ) ; } } } new Broker ( ) ;