+ this.on(ChargingStationEvents.accepted, () => {
+ this.startMessageSequence(
+ this.wsConnectionRetried
+ ? true
+ : this.getAutomaticTransactionGeneratorConfiguration()?.stopAbsoluteDuration
+ ).catch(error => {
+ logger.error(`${this.logPrefix()} Error while starting the message sequence:`, error)
+ })
+ this.wsConnectionRetried = false
+ })
+ this.on(ChargingStationEvents.rejected, () => {
+ this.wsConnectionRetried = false
+ })
+ this.on(ChargingStationEvents.disconnected, () => {
+ try {
+ this.internalStopMessageSequence()
+ } catch (error) {
+ logger.error(
+ `${this.logPrefix()} Error while stopping the internal message sequence:`,
+ error
+ )
+ }
+ })