[Pkg-ceph-commits] [ceph] 01/01: rgw: Fixes for creation times for buckets (LP: #1587261):
James Downing Page
jamespage at moszumanska.debian.org
Thu Nov 10 09:44:25 UTC 2016
This is an automated email from the git hooks/post-receive script.
jamespage pushed a commit to branch ubuntu/xenial
in repository ceph.
commit 83b64f4818be9e78a5b6f6f8892ff4247a3b4631
Author: James Page <james.page at ubuntu.com>
Date: Fri Oct 28 16:47:51 2016 +0200
rgw: Fixes for creation times for buckets (LP: #1587261):
* rgw: Fixes for creation times for buckets (LP: #1587261):
- d/p/rgw_rados-creation_time.patch: Backport fix from upstream master.
Fix logic error that leads to creation time being 0 instead of current
time when creating buckets.
---
debian/changelog | 9 ++++++++
debian/patches/rgw_rados-creation_time.patch | 34 ++++++++++++++++++++++++++++
debian/patches/series | 1 +
3 files changed, 44 insertions(+)
diff --git a/debian/changelog b/debian/changelog
index 10654ac..071c410 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,12 @@
+ceph (10.2.3-0ubuntu0.16.04.2) xenial; urgency=medium
+
+ * rgw: Fixes for creation times for buckets (LP: #1587261):
+ - d/p/rgw_rados-creation_time.patch: Backport fix from upstream master.
+ Fix logic error that leads to creation time being 0 instead of current
+ time when creating buckets.
+
+ -- Frode Nordahl <frode.nordahl at canonical.com> Fri, 28 Oct 2016 13:50:40 +0200
+
ceph (10.2.3-0ubuntu0.16.04.1) xenial; urgency=medium
* New upstream stable release (LP: #1628809).
diff --git a/debian/patches/rgw_rados-creation_time.patch b/debian/patches/rgw_rados-creation_time.patch
new file mode 100644
index 0000000..ccc8e0e
--- /dev/null
+++ b/debian/patches/rgw_rados-creation_time.patch
@@ -0,0 +1,34 @@
+From: weiqiaomiao <wei.qiaomiao at zte.com.cn>
+Subject: [PATCH] rgw: for the create_bucket api, if the input creation_time is
+ zero, we should set it to 'now"
+Forwarded: yes
+Origin: upstream, https://github.com/ceph/ceph/commit/16c1a7d03abc8042f92b9f62ae7e228d19f74b2e
+Bug: http://tracker.ceph.com/issues/16597
+Bug-Ubuntu: https://bugs.launchpad.net/bugs/1587261
+
+Fixes: http://tracker.ceph.com/issues/16597
+
+Signed-off-by: weiqiaomiao <wei.qiaomiao at zte.com.cn>
+---
+ src/rgw/rgw_rados.cc | 7 ++++---
+ 1 file changed, 4 insertions(+), 3 deletions(-)
+
+diff --git a/src/rgw/rgw_rados.cc b/src/rgw/rgw_rados.cc
+index d356fb8..8e0f0fd 100644
+--- a/src/rgw/rgw_rados.cc
++++ b/src/rgw/rgw_rados.cc
+@@ -5156,10 +5156,11 @@ int RGWRados::create_bucket(RGWUserInfo& owner, rgw_bucket& bucket,
+ info.num_shards = bucket_index_max_shards;
+ info.bucket_index_shard_hash_type = RGWBucketInfo::MOD;
+ info.requester_pays = false;
+- if (real_clock::is_zero(creation_time))
+- creation_time = ceph::real_clock::now(cct);
+- else
++ if (real_clock::is_zero(creation_time)) {
++ info.creation_time = ceph::real_clock::now(cct);
++ } else {
+ info.creation_time = creation_time;
++ }
+ ret = put_linked_bucket_info(info, exclusive, ceph::real_time(), pep_objv, &attrs, true);
+ if (ret == -EEXIST) {
+ /* we need to reread the info and return it, caller will have a use for it */
diff --git a/debian/patches/series b/debian/patches/series
index fefdee5..baca071 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -18,3 +18,4 @@ skip-setup.py-makefiles.patch
disable-openssl-linking.patch
osd-limit-omap-data-in-push-op.patch
32bit-ftbfs.patch
+rgw_rados-creation_time.patch
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-ceph/ceph.git
More information about the Pkg-ceph-commits
mailing list