]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
rados: use new notify API
authorSage Weil <sage@redhat.com>
Thu, 13 Nov 2014 22:11:45 +0000 (14:11 -0800)
committerSage Weil <sage@redhat.com>
Thu, 4 Dec 2014 18:33:28 +0000 (10:33 -0800)
Signed-off-by: Sage Weil <sage@redhat.com>
src/tools/rados/rados.cc

index 374e12949754add0868954597c4ce1629c75eee2..f404156910ed0c08c5a37bf7e830f05f53f0d264 100644 (file)
@@ -2379,11 +2379,13 @@ static int rados_tool_common(const std::map < std::string, std::string > &opts,
       usage_exit();
     string oid(nargs[1]);
     string msg(nargs[2]);
-    bufferlist bl;
+    bufferlist bl, replybl;
     ::encode(msg, bl);
-    ret = io_ctx.notify(oid, 0, bl);
+    ret = io_ctx.notify(oid, bl, 10000, &replybl);
     if (ret != 0)
       cerr << "error calling notify: " << ret << std::endl;
+    if (replybl.length())
+      replybl.hexdump(cout);
   } else if (strcmp(nargs[0], "set-alloc-hint") == 0) {
     if (!pool_name || nargs.size() < 4)
       usage_exit();