summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--swift/1.4.8/plugins/utils.py23
1 files changed, 12 insertions, 11 deletions
diff --git a/swift/1.4.8/plugins/utils.py b/swift/1.4.8/plugins/utils.py
index 72b2f38..ef5f9d6 100644
--- a/swift/1.4.8/plugins/utils.py
+++ b/swift/1.4.8/plugins/utils.py
@@ -176,17 +176,6 @@ def do_rename(old_path, new_path):
raise
return True
-def _add_timestamp(metadata_i):
- # At this point we have a simple key/value dictionary, turn it into
- # key/(value,timestamp) pairs.
- timestamp = 0
- metadata = {}
- for key, value_i in metadata_i.iteritems():
- if not isinstance(value_i, tuple):
- metadata[key] = (value_i, timestamp)
- else:
- metadata[key] = value_i
- return metadata
def read_metadata(path):
"""
@@ -587,6 +576,18 @@ def get_object_metadata(obj_path):
return metadata
+def _add_timestamp(metadata_i):
+ # At this point we have a simple key/value dictionary, turn it into
+ # key/(value,timestamp) pairs.
+ timestamp = 0
+ metadata = {}
+ for key, value_i in metadata_i.iteritems():
+ if not isinstance(value_i, tuple):
+ metadata[key] = (value_i, timestamp)
+ else:
+ metadata[key] = value_i
+ return metadata
+
def get_container_metadata(cont_path, memcache=None):
objects = []
object_count = 0