lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


--- Ketmar Dark <ketmar@ic.km.ua> wrote:
> yae are completely right. but one can write another
> `servers' with, for
> example, unix sockets to do time-consuming tasks.
> then run this servers
> and get multiple requests w/o slowdown. it's a
> unix-way: do one thing,
> but do it good. %-)
> 
Yes, I am doing it this way too. But without unix
domain socket, it can get complicated too(how to avoid
port number collison) and there is no such thing on
Windows. Currently, I am doing it in a kind of reverse
way, the master thread spawn a helper process passing
it a tcp/ip socket where the helper connects back and
tell the master what port to use for future request.

However it still cannot solve the problem. Again using
my SQL as an example. Because it is unpredictable, may
be 9/10 times, I get immediate result within that
single thread. Using the seperate task way, there
would be yet another layer of data passing which would
hit make the performance much worse(if I have a large
result set) 9/10 times.


       
____________________________________________________________________________________
Got a little couch potato? 
Check out fun summer activities for kids.
http://search.yahoo.com/search?fr=oni_on_mail&p=summer+activities+for+kids&cs=bz