Page 2 of 2
Re: FireFox with SSL
Posted: Thu Feb 04, 2021 4:10 pm
by RebootExpert
I agree UserMain having the lowest priority. But each XHR request will take about 500ms to complete both in firefox and chrome. I can see the SSL/TLS connection negotiation time is about 100ms in the FireFox developer tools panel. Also the XHR request will abort if it's not complete before the next request.
FireFox

- firefox_request_time.png (127.21 KiB) Viewed 4085 times
Chrome

- chrome_request_time.png (87.29 KiB) Viewed 4085 times
The ssl and tcp are have enough socket available to use, even during the delay.

- main_loop.png (73.13 KiB) Viewed 4085 times
Re: FireFox with SSL
Posted: Thu Feb 04, 2021 4:30 pm
by RebootExpert
Even though the web server have the higher priority over the UserMain to run, during those delay xhr request can't establish a connection with server. what could possible stop the server from working with more than enough socket available to use
Re: FireFox with SSL
Posted: Thu Feb 04, 2021 6:50 pm
by RebootExpert
Plus I also test that after the webpage loaded, I wait for 5 minutes to start xhr request . once I start request, it hang immediately. So I don't think it's the negotiation cause all these.
Re: FireFox with SSL
Posted: Fri Feb 05, 2021 9:25 am
by Jon
HI RebootExpert,
I'm going to be testing your posted app later today and will post something as soon as I have the results. =)
Kind Regards,
Jon
Re: FireFox with SSL
Posted: Fri Feb 05, 2021 12:59 pm
by RebootExpert
As I look into
http vs websocket comparison http periodic polling is not recommended. Websocket seems to be a good solution to this. Plus the server wouldn't be powerful enough to handle the requests from multiple https webpage. I will learn and try to build an app use websocket to see if the problem still . However I am not sure if NB support websocket over SSL. If you can still look at my provided app that will be a great help.
Re: FireFox with SSL
Posted: Fri Feb 05, 2021 5:55 pm
by Jon
We do support secure websockets. When you call Connect, you can use one of two functions. In both, the last parameter determines whether or not the connection should be secure:
int WebSocket::Connect( IPADDR host, const char * resource, int portnum, bool useSSL )
int WebSocket::Connect( const char * host, const char * resource, int portnum, bool useSSL )