wwatts
We have a client that initializes a number of subscriptions to different items. Sometimes during this process, we receive and error on the client that states "The underlying connection was closed. The connection was closed unexpectedly". Reviewing the Lightstreamer log file we see the following error code 38 being reported with a Sync Error.
17-Feb-12 14:12:18,261|INFO |LightstreamerLogger.requests |FOR PUMPS PARKING DESTROYER|Closed session Sfde77fce01081e71T0851448 with internal cause code: 38
17-Feb-12 14:12:20,383|INFO |LightstreamerLogger.requests |SERVER POOLED THREAD 9 |Serving request: /lightstreamer/control.txt --> LS_session=Sfde77fce01081e71T0851448&LS_op=destroy from xxx.xx.xxx.xxx:2650
17-Feb-12 14:12:20,383|INFO |LightstreamerLogger.requests |SERVER POOLED THREAD 9 |Destroying session: Sfde77fce01081e71T0851448 from xxx.xx.xxx.xxx:2650
17-Feb-12 14:12:20,383|INFO |LightstreamerLogger.requests |SERVER POOLED THREAD 9 |Sync error: Can't find session from xxx.xx.xxx.xxx:2650
Note that the IP addresses have been removed for sanitization reasons. Could you please help us understand what might be happening and possibly what internal cause code 38 might be? For your information we are using Presto 4.0.1 version of Lightstreamer running on a windows 2008 R2 server and the client is currently running on windows XP using a C# implementation for both the client and Data Adapters.
Thanks in advance for the help.
Dario Crivelli
From the Server perspective, the connection was closed by the Client (this is the error 38).
However, as suggested by the exception you received, from the Client perspective, the connection was closed by the Server.
We should clarify if the two messages refer to the same or different connections.
Did you receive the exception upon a subscribe call or through onFailure on the connection listener?
The subsequent "sync error" may be just a consequence:
When the Client finds a broken connection, it still tries to inform the Server that the session is no longer needed with a "destroy" request.
In this case, the session has been already closed, because the Server has noticed the connection break, hence the error.
However, the "sync error" demonstrates that the client-server connectivity is still working after the issue.