Results 1 to 2 of 2

Thread: unsubscribe

  1. #1
    Join Date
    Mar 2007


    After user establishes the connection and subscribes one or more items, if user closes browser or user's machine crashes, what event will be sent to Lightstreamer server? And what APIs for MetadataAdapter & DataAdapter will be called on server and in what sequence?

  2. #2
    Join Date
    Jul 2006
    If the browser operation is interrupted abruptly, the Server will only see that the streaming connection is broken; hence, it will close the Session in short time, as soon as it tries to write something (possibly a keepalive packet).
    In principle, it is possible that an intermediate node keeps the connection open even if the browser has closed (and becomes itself the client, on behalf of the browser). We currently don't handle this case and the Server keeps streaming until the content-length is consumed, but it doesn't seem to be a common case.

    If the browser is interrupted while no request is under processing (for instance, in polling mode, between two subsequent polls), the Server is totally unaware and will keep waiting for a client action and will close the Session after the related timeout.

    Upon session closing, notifySessionClosed is invoked on the Metadata Adapter.
    If wantsTablesNotifications had returned true for that session, then notifyTablesClose is also invoked, before notifySessionClosed, once for each currently subscribed table.
    If the involved unsubscriptions cause some item not to be requested by any client, then unsubscribe is also issued to the Data Adapter for each of them. All the latter calls are concurrent with one another and with respect to the Metadata Adapter calls.



Similar Threads

  1. IE - unexpected unsubscribe
    By shayzweig in forum Client SDKs
    Replies: 3
    Last Post: April 6th, 2010, 08:46 AM
  2. unsubscribe by itself intermittenly
    By ddhanis in forum Client SDKs
    Replies: 1
    Last Post: May 21st, 2009, 09:54 AM
  3. unsubscribe
    By jamesclinton in forum Adapter SDKs
    Replies: 2
    Last Post: March 14th, 2007, 07:04 AM


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 11:09 PM.