Boost logo

Boost :

From: simon meiklejohn (simon_at_[hidden])
Date: 2006-08-17 16:46:11


Hi Chris,
> The latest asio code in CVS includes the ability to hook and
> customise the dispatching of a handler, pretty much as we
> discussed during the review. There's a short discussion on it in
> the design section of the TR2 draft.

Hi Chris and Beman,

I haven't looked at the CVS code - i'll get onto it soon.
I did look at the link to documentation at the top of the
thread and i don't see too much about hooking the
dispatch in there. I do see that asio supports the CoInitialise
case by getting the user to call that function (or whatever
they want) before calling io_service.run(). That works fine.

I don't mean to re-litigate the asio interface - that subject has
had quite the hammering. I'm responding to Beman's request
in this thread for input on threading in general.

My suggestion, for a more general way to specify precursor
actions to peform before calling user code relates more to
e.g. thread pool's that manage internally the creation of
threads which will then call out into user code when requested
by a method analagous to io_service.post().

Cheers

Simon


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk