[pkg-eucalyptus-commits] [SCM] managing cloud instances for Eucalyptus branch, master, updated. 3.0.0-alpha3-257-g1da8e3a

Garrett Holmstrom gholms at fedoraproject.org
Sun Jun 16 02:30:06 UTC 2013


The following commit has been merged in the master branch:
commit f5e8691992d4217b110bb291be5ce87172b1b231
Author: Garrett Holmstrom <gholms at fedoraproject.org>
Date:   Sat Feb 16 14:56:14 2013 -0800

    Make page structures opaque to requestbuilder

diff --git a/euca2ools/commands/walrus/listbucket.py b/euca2ools/commands/walrus/listbucket.py
index 708545b..4a5b498 100644
--- a/euca2ools/commands/walrus/listbucket.py
+++ b/euca2ools/commands/walrus/listbucket.py
@@ -53,14 +53,16 @@ class ListBucket(WalrusRequest, TabifyingCommand):
 
     def main(self):
         self.method = 'GET'
-        return PaginatedResponse(self, self.args['paths'], ('Contents',))
+        pages = [(path, {}) for path in self.args['paths']]
+        return PaginatedResponse(self, pages, ('Contents',))
 
-    def get_page_markers(self, response):
+    def get_next_page(self, response):
         if response.get('IsTruncated') == 'true':
-            return {'marker': response['Contents'][-1]['Key']}
+            return (self.path, {'marker': response['Contents'][-1]['Key']})
 
-    def prepare_for_page(self, next_path, markers):
-        bucket, __, prefix = next_path.partition('/')
+    def prepare_for_page(self, page):
+        bucket, __, prefix = page[0].partition('/')
+        markers = page[1]
         self.path = bucket
         if prefix:
             self.params['prefix'] = prefix

-- 
managing cloud instances for Eucalyptus



More information about the pkg-eucalyptus-commits mailing list