Is there a way to find how many clients opened the web page?

detectivet
Posts: 2
Joined: Thu Jan 02, 2020 1:40 pm

Is there a way to find how many clients opened the web page?

Postby detectivet » Thu Jan 02, 2020 2:01 pm

I have a ESP32-CAM, it only allows one client to access the camera web page per time, it will return a 400 code if there is a already a client opened this web page. The problem is, sometime the web server returns a 400 code when there isn't any client using the web, an error/bug I guess. What I did is using

Code: Select all

HTTPClient
to make GET request on the web it's hosting, if the return code is 400, I restart the service, now I realise that I need to know if the web is actually down or there is just a client using the web.
Is there a function that can tell the number of clients that opened the web? Or perhaps any other solutions to this issue? Thanks!

Who is online

Users browsing this forum: No registered users and 76 guests