Good day. I have a question about proceeding accepted connections. I have a pythons tornado IOLoop and listening socket. When a new client is connected and this connection is accepted by tornado handler client - interaction begins. That interaction includes multiple requests/responses, so there is a reason to poll accepted socket for available bytes. How to do polling the correct way? The direct way is to use epoll/select, but this is like reinventing IOLoop. But is this correct to create IOLoop for each new connection?
I've searched how "torando.web" does it. It works with default IOLoop instance and that instance accepts connections and handles (processes) new sockets that were created after connections were accepted. The second part is done by IOStream.
So the answer is to use the same IOLoop object and not to poll sockets manually