Index: tools/telemetry/telemetry/util/cloud_storage.py |
diff --git a/tools/telemetry/telemetry/util/cloud_storage.py b/tools/telemetry/telemetry/util/cloud_storage.py |
index 0e1ddc3f44ef8991eb36ea2820038fac7243d4b1..079b4ef4865f860fb57f415f230a8185f0d41861 100644 |
--- a/tools/telemetry/telemetry/util/cloud_storage.py |
+++ b/tools/telemetry/telemetry/util/cloud_storage.py |
@@ -5,6 +5,7 @@ |
"""Wrappers for gsutil, for basic interaction with Google Cloud Storage.""" |
import contextlib |
+import collections |
import cStringIO |
import hashlib |
import logging |
@@ -23,11 +24,18 @@ PARTNER_BUCKET = 'chrome-partner-telemetry' |
INTERNAL_BUCKET = 'chrome-telemetry' |
-BUCKET_ALIASES = { |
- 'public': PUBLIC_BUCKET, |
- 'partner': PARTNER_BUCKET, |
- 'internal': INTERNAL_BUCKET, |
-} |
+# Uses ordered dict to make sure that bucket's key-value items are ordered from |
+# the most open to the most restrictive. |
+BUCKET_ALIASES = collections.OrderedDict(( |
+ ('public', PUBLIC_BUCKET), |
+ ('partner', PARTNER_BUCKET), |
+ ('internal', INTERNAL_BUCKET), |
+)) |
+ |
+ |
+BUCKET_ALIASES['public'] = PUBLIC_BUCKET |
+BUCKET_ALIASES['partner'] = PARTNER_BUCKET |
+BUCKET_ALIASES['internal'] = INTERNAL_BUCKET |
_GSUTIL_URL = 'http://storage.googleapis.com/pub/gsutil.tar.gz' |