-
February 23rd, 2016, 04:08 PM
#1
TIME_WAIT and HTTP version
Hi,
I'm using LS behind a NAT. What I observe is that when LS is under load, there is a large number of sockets in TIME_WAIT state on the server, and the clients start to receive "connection refused" errors.
This happens both when the clients are making frequent connection/disconnections (but very few subscriptions), and also very few connections but frequent subs/unsubs.
This made me think that the server is closing all TCP connections, since only the FIN initiating party enters TIME_WAIT state. This is understandable for disconnections, because it is done asynchronously (client issuing control command and the server closes the connection).
But I don't understand why this also happens for unsubscriptions. Is it because LS is using HTTP 1.0? What HTTP version is used by different versions of LS?
Thanks
-
February 24th, 2016, 12:22 PM
#2
Hi carenot,
First I want to confirm that Lightstreamer uses HTTP 1.1 (or HTTP 1.0 only if explicitly requested by the client); and that the server does not close a connection on its own initiative at least in normal scenario.
Now, I am not sure if you're complaining that due to too many sockets in TIME_WAIT you end up running out of available TCP ports and consequently you got connections rejected.
Or, on the contrary, that since the server is simply refusing too many connections figuring out if TIME_WAITs are related in some way.
By the way, could you confirm whether you are leveraging the <server_pool_max_queue> parameter (in lightstreamer_conf.xml)? Indeed, in this case I confirm that the Lightstreamer server, as long as the number is exceeded, keeps waiting the accept loops of all the listening sockets.
Regards,
Giuseppe
Similar Threads
-
By mello151 in forum Adapter SDKs
Replies: 2
Last Post: June 13th, 2014, 02:22 AM
-
By rebatch in forum Client SDKs
Replies: 1
Last Post: November 30th, 2012, 08:37 AM
-
By riwang in forum Client SDKs
Replies: 1
Last Post: January 7th, 2009, 10:56 AM
-
By DarioCrivelli in forum Client SDKs
Replies: 0
Last Post: December 22nd, 2006, 12:18 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
-
Forum Rules
All times are GMT +1. The time now is 04:33 AM.
Bookmarks