Can anyone tell me the difference between io_service dispatch and post? It was not clear to me what is more suitable for my problem.
I need to invoke a handler insid
see this blog entry:
To post or to dispatch? - This Thread
Running the application we'll see the difference between posting and dispatching. Since it could do it, dispatch() would execute fB() directly, so we'll see it runs in the current thread, and synchronously. On the other side, post() would ask to io_service to do the job, asynchronously in another thread, and it immediately returns the control to the caller.