<div class="gmail_quote">On Tue, Mar 2, 2010 at 1:19 PM, Fred C <span dir="ltr">&lt;<a href="mailto:fred@bsdhost.net">fred@bsdhost.net</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<br>
Hello,<br>
<br>
I am totally new with Twisted and this the first code I have ever written using that package. One of my main problem was to figure out how to fit things together and I am not even sure I understand everything I am doing here.<br>

<br>
Anyway, for a project I have to write a proxy that figure out where is located a resource by requesting a database. then figure out if the resource is accessible and them open a proxy connection to download that resource.<br>

<br>
I was wandering if there is someone in that mailing list who can review that code and tell me how I can improve things. I know I am not accessing the database the right way but I can&#39;t figure out how to work with the Callbacks.<br>

<br>
Any help or advice will be very much appreciated. The code is available here: <a href="http://pastebin.com/BGcqzh4Y" target="_blank">http://pastebin.com/BGcqzh4Y</a><br>
<br>
-fred-<br>
<font color="#888888"></font><br></blockquote></div><br>I don&#39;t really use Twisted for web work, so I don&#39;t have much of a comment on that, but for database access you probably want to use `twisted.enterprise.adbapi`.<br>
<br>Kevin Horn<br>