lua-users home
lua-l archive

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



FYI There is a good library Boost ASIO for async socket operations already, supports Linux, Windows, etc. Uses I/O completion ports on WIN32 and epoll on Linux.
The next version will have general File I/O. 





> Date: Fri, 29 Feb 2008 12:17:10 -0500
> From: diego@tecgraf.puc-rio.br
> To: lua@bazar2.conectiva.com.br
> Subject: Re: LuaSocket 3.0? (was Re: A proposal for faster userdata type checking)
>
> Hi,
>
> > The main requirement to have an effective lis scheduler is
> > having _one_ single call to wait for _any_ kind of long
> > operations.
> >
> > Is LusSocket mechanism flexible enough to handle local
> > sockets and file I/O?
>
> Local sockets, definitely. File I/O I don't see why not. I
> wonder if the OS implements non-blocking I/O on regular
> files. I have heard on this list that this is usually not
> the case. It will be fun to test.
>
> > Other blocking operations (like DB or libraries) could be
> > handled by a separate process, reporting via sockets.
> > Somewhat tedious, but very doable.
>
> The idea is to provide a way for users and other libraries
> to post into the completion queue. And these functions can
> be made thread safe. As for IPC, I haven't thought about how
> to make it simpler yet.
>
> Kind regards,
> Diego



Shed those extra pounds with MSN and The Biggest Loser! Learn more.