Re: [PHP] Performance of while(true) loop

2009-09-10 Thread Jim Lucas
APseudoUtopia wrote: > Hey list, > > I have a php cli script that listens on a UDP socket and, when data is > sent to the socket, the script inserts it into a database. I'm using > the real BSD socket functions, not fsock. > > The script runs socket_create(), then socket_bind(). Then it starts a

Re: [PHP] Performance of while(true) loop

2009-09-09 Thread Ben Dunlap
I have a php cli script that listens on a UDP socket and, when data is [8<] >> So I think the the MSG_WAITALL is causing it to block until incoming >> data connection is closed (it never reaches the 512 byte mark before [8<] > your "clients" are not maintaining an open connection to the socket

Re: [PHP] Performance of while(true) loop

2009-09-09 Thread Eddie Drapkin
On Wed, Sep 9, 2009 at 10:53 PM, APseudoUtopia wrote: > On Wed, Sep 9, 2009 at 10:39 PM, Eddie Drapkin wrote: >> On Wed, Sep 9, 2009 at 10:32 PM, APseudoUtopia >> wrote: >>> Hey list, >>> >>> I have a php cli script that listens on a UDP socket and, when data is >>> sent to the socket, the scrip

Re: [PHP] Performance of while(true) loop

2009-09-09 Thread APseudoUtopia
On Wed, Sep 9, 2009 at 10:39 PM, Eddie Drapkin wrote: > On Wed, Sep 9, 2009 at 10:32 PM, APseudoUtopia > wrote: >> Hey list, >> >> I have a php cli script that listens on a UDP socket and, when data is >> sent to the socket, the script inserts it into a database. I'm using >> the real BSD socket

Re: [PHP] Performance of while(true) loop

2009-09-09 Thread Eddie Drapkin
On Wed, Sep 9, 2009 at 10:32 PM, APseudoUtopia wrote: > Hey list, > > I have a php cli script that listens on a UDP socket and, when data is > sent to the socket, the script inserts it into a database. I'm using > the real BSD socket functions, not fsock. > > The script runs socket_create(), then