[z3-checkins] r38087 - z3/deliverance/branches/cache_aware/deliverance

ltucker at codespeak.net ltucker at codespeak.net
Wed Feb 7 19:10:36 CET 2007


Author: ltucker
Date: Wed Feb  7 19:10:33 2007
New Revision: 38087

Modified:
   z3/deliverance/branches/cache_aware/deliverance/wsgimiddleware.py
Log:
just comments

Modified: z3/deliverance/branches/cache_aware/deliverance/wsgimiddleware.py
==============================================================================
--- z3/deliverance/branches/cache_aware/deliverance/wsgimiddleware.py	(original)
+++ z3/deliverance/branches/cache_aware/deliverance/wsgimiddleware.py	Wed Feb  7 19:10:33 2007
@@ -286,11 +286,11 @@
         
     def any_modified(self, environ, resources, etag_map): 
         """
-        returns a tuple containing a boolean and map of uris to HTTP response headers.  
-        the first value represents whether any resource in resources has been 
-        modified based on the checks contained in environ.  The uris in the list 
-        resources are associated with their respective response headers in the 
-        second element of the tuple. 
+        returns a boolean indicating whether any of the uris in the resources 
+        list have been modified. if an entry for the uri exists in the map
+        etag_map, the value will be used to check the resource using an 
+        if-none-match http header. if an if-not-modified check is desired, 
+        it should be present in environ. 
         """
 
         moddate = None
@@ -349,6 +349,10 @@
             
 
     def get_fetcher(self, environ, uri): 
+        """
+        retrieve an object which is appropriate for fetching the 
+        uri specified. 
+        """
         internalBaseURL = environ.get(DELIVERANCE_BASE_URL,None)
         uri = urlparse.urljoin(internalBaseURL, uri)        
 
@@ -384,6 +388,9 @@
         if etag is set to an etag for the resource, the If-None-Match HTTP header 
           is used to check for modification 
 
+        the resulting (status, headers, body) tuple for the request is stored in 
+        environ[DELIVERANCE_CACHE][uri]. 
+
         """
 
         fetcher = self.get_fetcher(environ, uri)


More information about the z3-checkins mailing list