updateServerUrl() {
    this.getServers().then((servers) => {
      const index = servers.indexOf(this.serverUrl)
      if (index > -1) {
        servers.splice(index, 1)
      }
      if (servers.length === 0) {
        // No more server available
        this.noServerUrlAvailable()
      } else {
        this.serverUrl = shuffle(servers)
        this.cometd.configure({
          url: `${this.serverUrl}/strd`
        })
        setTimeout(() => {
          this.cometd.handshake(this.getHandshakeFields())
        }, UPDATE_SERVER_URL_DELAY)
      }
    })
  }
/**
  * Remove current server url from the server list and shuffle for another one
  */
Remove current server url from the server list and shuffle for another one
Remove current server url from the server list and shuffle for another one
updateServerUrl() {
    this.getServers().then((servers) => {
      const index = servers.indexOf(this.serverUrl)
      if (index > -1) {
        servers.splice(index, 1)
      }
      if (servers.length === 0) {
        this.noServerUrlAvailable()
      } else {
        this.serverUrl = shuffle(servers)
        this.cometd.configure({
          url: `${this.serverUrl}/strd`
        })
        setTimeout(() => {
          this.cometd.handshake(this.getHandshakeFields())
        }, UPDATE_SERVER_URL_DELAY)
      }
    })
  }
updateServerUrl ( ) { this . getServers ( ) . then ( ( servers ) => { const index = servers . indexOf ( this . serverUrl ) if ( index > - 1 ) { servers . splice ( index , 1 ) } if ( servers . length === 0 ) { this . noServerUrlAvailable ( ) } else { this . serverUrl = shuffle ( servers ) this . cometd . configure ( { url : ` ${ this . serverUrl } ` } ) setTimeout ( ( ) => { this . cometd . handshake ( this . getHandshakeFields ( ) ) } , UPDATE_SERVER_URL_DELAY ) } } ) }
Remove current server url from the server list and shuffle for another one
Remove current server url from the server list and shuffle for another one
// No more server available