add demo README
[multitaskhttpd.git] / README
1 So far, this includes a basic HTTP server based on SimpleHTTPServer:
2 python httpd.py -d
3
4 and a JSONRPC test application:
5 python jsonapp.py
6
7 The latter is where it gets interesting. Session cookies are automatically
8 used to create application instances which are persistent in memory
9 (TODO: drop them after an application-specified timeout of course...)
10
11 As this is an entirely single-process application, it's perfectly possible
12 to keep large complex data structures around that would otherwise be
13 impossible to serialise (such as data structures from c-based python modules,
14 or persistent database connection objects).
15
16 One of the reasons why this code has been put together is so that GNUmed
17 can keep per-user persistent database connections open, where the user
18 credentials are *different* on a per-user basis. GNUmed uses postgresql
19 "roles" for security purposes, and thus a "global database connection"
20 which is the "norm" for most web-based database frameworks, is completely
21 useless.
22