Boost logo

Boost Users :

Subject: Re: [Boost-users] [boost-users][asio]timeout-isio_service.reset()safe with pool of threads?
From: tomasz jankowski (tomasz_jacek_at_[hidden])
Date: 2009-02-03 09:07:29


Dnia 3-02-2009 o godz. 12:29 Igor R napisał(a):
First of all, there're more tasks: pay attention that before issuing new async_accept, the Server calls connection->open(), which in turn issues async_read etc - all this is processed by one single io_service...

but I'm asking about moment when server is constructed & run n threads for one io_service. only one run() will 'hang' on async_accept. the rest of run() must return... but doesn't. I see all threads (when run "ps -eLf" command). I don't know how it is possible...

But anyway - what if you've got 1000 incoming connections simultaniously? If you'd got 1 thread, it would accept them one by one, processing in the meanwhile read/write operations of the Connection object.


I don't know how it is possible but let leav for while this problem. it works - it is enough for that while(ofcourse I wish understand :) ). I have another question about strand object. first we are parallelising than synchronizing our tasks via strand object. I can't catch this logic. it must be nonefective.

tom



----------------------------------------------------
Nużą Cię utarte scenariusze?
Wymyśl własną grę flashową i wygraj główną nagrodę 5.500 Euro:
http://klik.wp.pl/?adr=http://whosegame.pl/contestcard.php?contest=55&sid=631

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