Package couchdbkit :: Package wsgi :: Module proxy :: Class CouchdbProxy
[hide private]
[frames] | no frames]

Class CouchdbProxy

source code

object --+
         |
        CouchdbProxy

WSGI application to proxy a couchdb server.

Simple usage to proxy a CouchDB server on default url:

   from couchdbkit.wsgi import CouchdbProxy
   application = CouchdbProxy()
Instance Methods [hide private]
 
__init__(self, uri='http://127.0.0.1:5984', allowed_method=['GET', 'HEAD', 'POST', 'PUT', 'DELETE'], **kwargs)
x.__init__(...) initializes x; see help(type(x)) for signature
source code
 
do_proxy(self, req, environ, start_response)
return proxy response.
source code
 
__call__(self, environ, start_response) source code

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

__init__(self, uri='http://127.0.0.1:5984', allowed_method=['GET', 'HEAD', 'POST', 'PUT', 'DELETE'], **kwargs)
(Constructor)

source code 

x.__init__(...) initializes x; see help(type(x)) for signature

Overrides: object.__init__
(inherited documentation)

do_proxy(self, req, environ, start_response)

source code 

return proxy response. Can be overrided to add authentification and such. It's better to override do_proxy method than the __call__