Re: [PHP-DEV] tick callbacks,not concurrently? From: Andi Gutmans (andi <email protected>)
Date: 09/03/00

At 03:29 PM 9/2/00 -0500, Andrei Zmievski wrote:
>On Sat, 02 Sep 2000, André Langhorst wrote:
> > I wasn´t unable to watch the forking process completely. Execute this
> > script, it shows that
> > a) sequential executing with for() equals tick executing, time-wise, I
> > assume that this is not ok,
> > well maybe I ran into the WTF thing and did not understand what´s going
> > on, I thought these functions
> > were executed concurrently, what is (apparently) not the case. Ok. they
> > must be spawned sequentially,
> > but even replacing usleep with sleep(1) keeps these proportions in time
> > difference.
> > b) referenced variable $b is only increased in every function in for(),
> > that´s ok.
>
>That's right, the functions are _not_ executed concurrently - they are
>not threads.

We should make sure people know what they are used for. They were asked for
by Stig because he wanted to be able to start opening http:// connections
but continue some processing at the same time because opening a connection
takes time. This still hasn't been implemented but it's one of the only
real life examples ticks should be used. If it's not something special like
this you're doing then don't use ticks.

Andi

---
Andi Gutmans <andi <email protected>>
http://www.zend.com/

-- PHP Development Mailing List <http://www.php.net/> To unsubscribe, e-mail: php-dev-unsubscribe <email protected> For additional commands, e-mail: php-dev-help <email protected> To contact the list administrators, e-mail: php-list-admin <email protected>