[Libwebsockets] Problem of multiple persistent WebSocket connections
Zhang, Luis (Thin Client R&D)
xiaolu.zhang at hp.com
Mon Sep 18 03:46:52 CEST 2017
I will reproduce it and get more detailed logs later.
From: Andy Green [mailto:andy at warmcat.com]
Sent: Monday, September 18, 2017 9:33
To: Zhang, Luis (Thin Client R&D) <xiaolu.zhang at hp.com>; libwebsockets at ml.libwebsockets.org
Subject: RE: [Libwebsockets] Problem of multiple persistent WebSocket connections
On September 18, 2017 9:12:35 AM GMT+08:00, "Zhang, Luis (Thin Client R&D)" <xiaolu.zhang at hp.com> wrote:
>The platform is Debian 8.5 and I used libuv.
OK... so what happens when it seems to go wrong?
Can you reproduce this with the libuv test server? Can you let me know how to reproduce?
LWS_WITH_STATS is on master, it logs a bunch of interesting stats every 10s.
>From: Andy Green [mailto:andy at warmcat.com]
>Sent: Monday, September 18, 2017 9:11
>To: Zhang, Luis (Thin Client R&D) <xiaolu.zhang at hp.com>;
>libwebsockets at ml.libwebsockets.org
>Subject: Re: [Libwebsockets] Problem of multiple persistent WebSocket
>On 09/18/2017 09:07 AM, Andy Green wrote:
>> On 09/18/2017 08:51 AM, Zhang, Luis (Thin Client R&D) wrote:
>>> I'm working on developing a WebSocket Server that supports for
>>> multiple persistent WebSocket connections. Our goal is supporting
>>> 100K connections concurrently. As mentioned in
>>> https://libwebsockets.org/ that per thread can support 250K
>>> connections. So I think that there is no problem for supporting 100K
>>> persistent WebSocket connections. And I verified it with v2.0.0, it
>>> works well.
>>> But, when I upgraded the libwebsockets lib to v2.1, the server
>>> accepted so many connections. It only can accepted about 40K
>>> connections. When about 40K connections were established, I cannot
>>> establish websocket connection any more. I also test it with v2.2
>>> v2.3, I got the same result.
>>> The test environment of all test case are same, just the version of
>>> libwesocket lib are different.
>> - what is the platform?
>> - what *exactly* happens when you "cannot establish websocket
>> connection any more"? Logs?
> - what event loop? Default, using libuv / ev / event?
>> There's no intention to reduce the max clients the server can serve,
>> on the contrary...
>>> Any thoughts? Thank you.
>>> Best Regards,
>>> Libwebsockets mailing list
>>> Libwebsockets at ml.libwebsockets.org
>> Libwebsockets mailing list
>> Libwebsockets at ml.libwebsockets.org
More information about the Libwebsockets