Re: [Cppcms-users] Document regarding input content filtering
Brought to you by:
artyom-beilis
From: CN <cn...@fa...> - 2016-04-13 16:21:45
|
On Wed, Apr 13, 2016, at 06:24 PM, Artyom Beilis wrote: > Ok got your problem... > > See, resubmitting the context is to take a context from an application > in one pool and move to another, > for example to do filter in async application and move the context to > sync application for processing. > > The idea is following: > > You create one pool - lets say synchronous and keep a week_ptr on it. > Than you create a new asynchronous filtering pool and pass it to the > filtering pool: > > shared_ptr processor = cppcms::create_pool<myprcessor>(); > srv.applications_pool().mount(processor,...) > weak_ptr weak_pool = processor; > srv.applications_pool().mount(cppcms::create_pool<myfilter>(weak_pool),asynchronous|filter) > > So the weak reference to the pool is reference to another pool not my own > pool. > I think I finally have learned how to send asynchronous jobs to synchronously run in applications pool. Many thanks for your patience! Best regards, CN -- http://www.fastmail.com - A no graphics, no pop-ups email service |