Re: [Cppcms-users] Asynchronous app calls thread_pool.post() and blocks current thread
Brought to you by:
artyom-beilis
|
From: Artyom B. <art...@ya...> - 2014-07-16 07:35:05
|
Can you please send the code via attachment/inline and not "pastie" and explain in more details what happens? Artyom Beilis -------------- CppCMS - C++ Web Framework: http://cppcms.com/ CppDB - C++ SQL Connectivity: http://cppcms.com/sql/cppdb/ >________________________________ > From: dieterm57 <die...@gm...> >To: cpp...@li... >Sent: Monday, July 14, 2014 10:34 PM >Subject: [Cppcms-users] Asynchronous app calls thread_pool.post() and blocks current thread > > >Hey all, >I try to run an eventhandler inside of an asynchronous application, >using the following code: >http://pastie.org/private/9kuhjwvrzswmnpoczvvqw > >This seems to not block the eventloop, but the eventhandler gets called >in the same thread the application runs in, resulting in the application >not responding to new incoming requests. > >Is this the way it is designed or am I screwing up again :-[ ? >What would be the correct application design to execute a 'background' >job in the thread_pool, while not blocking the incoming requests? > >Sincerely >Dieter > >------------------------------------------------------------------------------ >Want fast and easy access to all the code in your enterprise? Index and >search up to 200,000 lines of code with a free copy of Black Duck® >Code Sight™ - the same software that powers the world's largest code >search on Ohloh, the Black Duck Open Hub! Try it now. >http://p.sf.net/sfu/bds >_______________________________________________ >Cppcms-users mailing list >Cpp...@li... >https://lists.sourceforge.net/lists/listinfo/cppcms-users > > > |