[Twisted-web] Need help getting started...

Andrea Soong girloncrack at yahoo.com
Wed Jun 8 01:33:36 MDT 2005


Hello, 
 
I'm taking a class in which we're supposed to be implementing a pseudo-proxy server that does some text parsing on web pages before passing them back to the client.  The proxy is supposed to be accessed via the URL and port that the server is running on, using an .rpy file.
 
I've looked through all of the available Twisted documentation, but just can't seem to get a handle on how to get started.  It's mostly setup questions - what code should go in which files?  How do I run it?  How do I test it?  There are a lot of code examples available, but very little information on how they interact and call each other.  It doesn't help that I am not too familiar with the OO-style API documentation.
 
I know that I need to be creating a subclass of HTTPClient, and creating a resource in the .rpy file.  I'm guessing that the .rpy file should create an instance of the HTTPClient subclass and use it to retrieve the requested URL (we have to get it line by line), but I don't understand how to create the instance.
 
A single good example that creates a web proxy server which simply retrieves the data line by line and displays it to the screen, plus the shell commands needed to run/test would be extremely helpful.  I am completely confused as to how the web server and .rpy file would interact.
 
I hope someone has the time and know-how to help me out.
THANKS


		
---------------------------------
Discover Yahoo!
 Stay in touch with email, IM, photo sharing & more. Check it out!
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://twistedmatrix.com/pipermail/twisted-web/attachments/20050608/982fd4bf/attachment.htm


More information about the Twisted-web mailing list