vinipsmaker / tufao

An asynchronous web framework for C++ built on top of Qt

Home Page:http://vinipsmaker.github.io/tufao/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Fast requests hanging Tufao

cijic opened this issue · comments

I use tufao for playing video and audio from libtorrent. So, when I make frequently requests, like frequently switching audio files, tufao starts hanging. I added additional logs in sources and here what have I got:

virtual void Tufao::TcpServerWrapper::incomingConnection(qintptr)
void Tufao::HttpServer::onNewConnection(qintptr)
virtual bool Tufao::HttpConnectionHandler::incomingConnection(qintptr)
virtual void Tufao::TcpServerWrapper::incomingConnection(qintptr)
void Tufao::HttpServer::onNewConnection(qintptr)
virtual bool Tufao::HttpConnectionHandler::incomingConnection(qintptr)

As You see, starting from Tufao::TcpServerWrapper::incomingConnection(qintptr) we have recirculation. In 10 seconds I've got more than 10 000 of calls of these methods.

So, can it be fixed and in what may be problem? In tufao or in Qt?

What Tufão version are you using? Can you provide a reduced code sample that trigger this problem?

I use last version of Tufao from github.com
I can't provide reduced code sample, because I don't know exact conditions to repeat this bug.
But I catch it when I make frequently requests to tufao, but NOT always.
Here logs for usual work state http://pastebin.com/6MwULzfM and problem work state http://pastebin.com/Xnb5rtFb

I use last version of Tufao from github.com

What is last version? I hope you aren't using code from branch master, because this is development code where any commit makes in. In fact, I hope you only use tagged releases, because I don't even guarantee any API/ABI stability if you're using "unreleased" versions.

And thank you for the logs. I will take a deeper look at the weekend.

I used code from master branch. Now I switched to last release in tagged releases, but bug repeated.

One last thing. I understood that the error happens when many requests using differente tcp connections are issued within a short time span. What platform are you using? What Qt version? I'd like to setup an environment as close as possible to yours to replicate the problem.

Qt 5.3.1
Windows 7 x64