suxunbin

Results 18 comments of suxunbin

I have read the https://github.com/eidheim/Simple-Web-Server/blob/master/http_examples.cpp#L183 example. ![6](https://user-images.githubusercontent.com/22476651/38991492-903077c0-4410-11e8-8f4a-2931372f05a4.PNG) My purpose is to use referrence of the response and request object on the location in the picture. In other words, I hope...

However, I need thread scheduling. So I only store them in query_handler(). Another thread is responsible for query_thread(). I can't directly pass the shared_ptr to query_thread() in query_handler(). I need...

For example,if there are 60 queries but I only have 30 threads in the threadpool. If I directly pass the shared_ptr to query_thread().Then there are 30 shared_ptr that can't pass.I...

In this way,if 30 threads are running,then what about the new shared_ptr ?

If use workers.service.post, how should I sort these handlers in io_service. I could not handle thest tasks according to the order of their entry.

![11](https://user-images.githubusercontent.com/22476651/39048905-c58d24ec-44d1-11e8-8ef6-745131988eb0.PNG) ![13](https://user-images.githubusercontent.com/22476651/39048909-ca178822-44d1-11e8-9006-ec08f237e775.PNG) I use the example you give me. But client gets nothing.

![14](https://user-images.githubusercontent.com/22476651/39049028-3d5f5008-44d2-11e8-9480-38b378bd6ac5.PNG) If I don't use workers.service.post(), client can directly get the data.

So, when I leave this scope, the response shared_ptr becomes invalid.