|
Boost Users : |
Subject: Re: [Boost-users] [asio] schedule work on all threads of a single io_service::run() pool?
From: Anthony Foiani (tkil_at_[hidden])
Date: 2013-05-18 16:57:31
Anthony Foiani <tkil_at_[hidden]> writes:
> I want to set up an io_service-per-thread, with each io_service having
> a deadline_timer to handle the heartbeat. The only other complicated
> bit is selecting an io_service to handle an incoming request.
Then there's this solution (Andrés's answer):
http://stackoverflow.com/questions/12166513/boostasio-thread-pools-and-thread-monitoring
(or: http://preview.tinyurl.com/alot5eo )
If I replace his run_one with poll_one, I think that covers what I'm
looking for.
I think it solves the scalability concern, because threads that are
currently working on other tasks will not be woken by the central
pool's notify.
Just in case someone else finds this in the archives...
Best,
Anthony Foiani
Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net