summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGary Lowell <gary.lowell@inktank.com>2013-09-04 01:37:41 -0700
committerGary Lowell <gary.lowell@inktank.com>2013-09-04 01:37:41 -0700
commitd9187a73c3e1f21f0be894e983feb4a7d495b729 (patch)
treee76c0b00e7e965c0e2c543c0f3f3f49791a72c55
parent2b2f296ed84169cd872d2ced3714f9a180994903 (diff)
parentb4cf0f2574be701d9efeb88c45ffd3c2004dce2c (diff)
downloadceph-d9187a73c3e1f21f0be894e983feb4a7d495b729.tar.gz
Merge branch 'next'
-rw-r--r--configure.ac2
-rw-r--r--debian/changelog6
-rw-r--r--src/rgw/rgw_rados.cc26
-rw-r--r--src/rgw/rgw_rados.h2
4 files changed, 27 insertions, 9 deletions
diff --git a/configure.ac b/configure.ac
index 38b6782a46a..cfe9e841e17 100644
--- a/configure.ac
+++ b/configure.ac
@@ -8,7 +8,7 @@ AC_PREREQ(2.59)
# VERSION define is not used by the code. It gets a version string
# from 'git describe'; see src/ceph_ver.[ch]
-AC_INIT([ceph], [0.67], [ceph-devel@vger.kernel.org])
+AC_INIT([ceph], [0.68], [ceph-devel@vger.kernel.org])
# Create release string. Used with VERSION for RPMs.
RPM_RELEASE=0
diff --git a/debian/changelog b/debian/changelog
index 3203f4271b1..874f85b1500 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,9 @@
+ceph (0.68-1) precise; urgency=low
+
+ * New upstream release
+
+ -- Gary Lowell <gary.lowell@inktank.com> Tue, 03 Sep 2013 16:10:11 -0700
+
ceph (0.67-1) precise; urgency=low
* New upstream release
diff --git a/src/rgw/rgw_rados.cc b/src/rgw/rgw_rados.cc
index 03cc1ebfdb3..05db9bff782 100644
--- a/src/rgw/rgw_rados.cc
+++ b/src/rgw/rgw_rados.cc
@@ -875,14 +875,6 @@ int RGWRados::init_complete()
{
int ret;
- if (need_watch_notify()) {
- ret = init_watch();
- if (ret < 0) {
- lderr(cct) << "ERROR: failed to initialize watch" << dendl;
- return ret;
- }
- }
-
ret = region.init(cct, this);
if (ret < 0)
return ret;
@@ -920,6 +912,14 @@ int RGWRados::init_complete()
}
}
+ if (need_watch_notify()) {
+ ret = init_watch();
+ if (ret < 0) {
+ lderr(cct) << "ERROR: failed to initialize watch" << dendl;
+ return ret;
+ }
+ }
+
map<string, RGWZone>::iterator ziter;
for (ziter = region.zones.begin(); ziter != region.zones.end(); ++ziter) {
const string& name = ziter->first;
@@ -1109,6 +1109,8 @@ int RGWRados::init_watch()
return r;
}
+ watch_initialized = true;
+
return 0;
}
@@ -4903,6 +4905,14 @@ int RGWRados::append_async(rgw_obj& obj, size_t size, bufferlist& bl)
int RGWRados::distribute(const string& key, bufferlist& bl)
{
+ /*
+ * we were called before watch was initialized. This can only happen if we're updating some system
+ * config object (e.g., zone info) during init. Don't try to distribute the cache info for these
+ * objects, they're currently only read on startup anyway.
+ */
+ if (!watch_initialized)
+ return 0;
+
string notify_oid;
pick_control_oid(key, notify_oid);
diff --git a/src/rgw/rgw_rados.h b/src/rgw/rgw_rados.h
index e6ab244afa9..0da6f4669bf 100644
--- a/src/rgw/rgw_rados.h
+++ b/src/rgw/rgw_rados.h
@@ -801,6 +801,7 @@ class RGWRados
uint64_t *watch_handles;
librados::IoCtx root_pool_ctx; // .rgw
librados::IoCtx control_pool_ctx; // .rgw.control
+ bool watch_initialized;
Mutex bucket_id_lock;
uint64_t max_bucket_id;
@@ -864,6 +865,7 @@ public:
RGWRados() : lock("rados_timer_lock"), timer(NULL),
gc(NULL), use_gc_thread(false),
num_watchers(0), watchers(NULL), watch_handles(NULL),
+ watch_initialized(false),
bucket_id_lock("rados_bucket_id"), max_bucket_id(0),
cct(NULL), rados(NULL),
pools_initialized(false),