[Twisted-Python] Making database-code Twisted-friendly

Thomas Weholt thomas.weholt at gmail.com
Thu Oct 14 11:41:09 EDT 2004


Attached is a database-module I've created and used quite a lot and so
far been very happy with. The problem is that it's not
Twisted-compatible at all. It blocks and I need something light in my
current project to merge a lot of data from one database into another
and I'd like to use this library to do it. Perhpas somebody can have
use for it as well??

My ideal form of working with databases is shown in the README.txt
file. I'd like to be able to something similar using Twisted in the
lower layers, not blocking.

In short: What I'm looking for is comments on the concept and code in
general, but more importantly a simple example on how to write similar
code in a Twisted-friendly manner so it doesn't block, or if you're so
inclined, feel free to add a Twisted-compatible Connection-object that
doesn't block and return data in the same manner as the implemented
objects do :-).

NB! If my attachment causes problems I'm terribly sorry, but my
current webserver is unavailable at the moment so I have no other
place to post the code ( except making an entire new project at
sourceforge, which seemed like overkill ).

Best regards,
-------------- next part --------------
A non-text attachment was scrubbed...
Name: hs.zip
Type: application/zip
Size: 16827 bytes
Desc: not available
Url : http://twistedmatrix.com/pipermail/twisted-python/attachments/20041014/f43b0cd7/attachment.zip 

More information about the Twisted-Python mailing list