On Mon, 2008-03-03 at 20:05 +1300, Lee Begg wrote: > On Mon, 03 Mar 2008, nash wrote: > > The documentation to do that in mysql & postgresql is part of the > > standard examples. Essentially when you connect you ask for the FD, > > then use the async call all the time. > > I had a look through the MySQL docs, and found the mutliple query/multiple > results methods, but no file descriptor. Do you have a URL for the > example/documentation?
No I don't actually. I just checked the code that did it, and it uses a thread and the threaded api, which is ugly. The comments in that code indicate the author thinks it sucks too, and suggests to use a real database... I'll have another look later, and see if I can find the magic. > A URL for async PostgreSQL would be useful too. PostgreSQL is easy: http://www.postgresql.org/docs/8.1/static/libpq-async.html PQsocket is the magic one, then just select/poll (or use ecore_fd_handler_add ;-) > > > And performance wise, it's the way to do it... much quicker. > > That's what I thought. I would take quite a bit to rearrange the processing > in > tpserver-cpp to make it work, but hopefully it is useful. Catch is, will the extra cost of keeping messages in order kill the gain? Regards, nash _______________________________________________ tp-devel mailing list [email protected] http://www.thousandparsec.net/tp/mailman.php/listinfo/tp-devel
