Results 1 to 3 of 3
  1. #1

    Question Getting to Status DISCONNECTED

    I am working on connection troubleshooting for my implementation of the Java SE Client 4.3.8 and there is a functionality I can't seem to figure out. I have a primary and secondary connection hence, if my client disconnects and the connection cannot be recovered I would like to manually swap over to my other connection, however, despite messing around with the values in the connection options I can't seem to get my client to go into status DISCONNECTED.

    It simply loops between DISCONNECTED:WILL-RETRY and CONNECTING indefinitely. I would like it to retry a few times (maybe for 30 seconds or so) but eventually give up. This seems like something that would be supported in the connection options but I can't seem to figure it out. I appreciate any pointers, thank you.

  2. #2
    The Lightstreamer Client SDK does not provide an option to configure a timeout such that if a connection cannot be established within the timeout, then the client is forced to give up.
    However you can easily implement a similar functionality by using the same pattern that was discussed in your previous thread:

    Timer timer = null;
    void onStatusChange(status) {
      if (status.equals("DISCONNECTED:WILL-RETRY")) {
        if (timer == null) {
          timer = new Timer();
          timer.schedule(() -> {
            if (!client.getStatus().startsWith("CONNECTED")) {
          }, TIMEOUT);

  3. #3
    Hey, thanks again for another reply! Yeah, I have a similar functionality to above up and running, was just hoping there was a cleaner way using only the lightstreamer built in functionality. Thanks for the help, good to know it just isn't an option.



Similar Threads

  1. DISCONNECTED:WILL-RETRY on the Android Client
    By syg5201314 in forum Client SDKs
    Replies: 9
    Last Post: May 30th, 2018, 02:04 PM
  2. Replies: 6
    Last Post: March 9th, 2016, 08:53 AM
  3. Network disconnected at client side
    By mhasan in forum Client SDKs
    Replies: 1
    Last Post: June 25th, 2015, 09:40 AM
  4. Replies: 3
    Last Post: February 11th, 2014, 08:43 AM
  5. Streaming system is disconnected
    By ivailo in forum Client SDKs
    Replies: 2
    Last Post: December 1st, 2009, 12:07 PM

Tags for this Thread


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
All times are GMT +1. The time now is 05:32 PM.