BaseHTTPServer and class variables
Yin
yin_12180 at yahoo.com
Mon Jan 26 11:25:00 EST 2004
More information about the Python-list mailing list
Mon Jan 26 11:25:00 EST 2004
- Previous message (by thread): BaseHTTPServer and class variables
- Next message (by thread): Guardian: open source is a throwback says Jack Schofield
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Hello. I am using the basehttpserver to implement the HTTP protocol to serve a fairly large lexicon that I have loaded as a dictionary in python. Rather than writing a whole server, I would like to reuse the BaseHTTPserver classes. I am interested in finding a way to serve the dict without loading the whole dict into memory everytime an HTTP request is made. The dict lives in local memory when it is loaded and takes a long time to load. Unfortunately with the basehttpserver.httpserver and basehttpserver.requesthandlerclass, I am not finding it easy to define a method to load the dict initially. Any thoughts are appreciated. Ideally, in a do_GET for the requesthandlerclass, it'd be nice to be able to access the dict as a class variable, but this doesn't work for me. Thanks. Yin
- Previous message (by thread): BaseHTTPServer and class variables
- Next message (by thread): Guardian: open source is a throwback says Jack Schofield
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the Python-list mailing list