diff options
author | Avra Sengupta <asengupt@redhat.com> | 2013-10-09 22:13:34 +0530 |
---|---|---|
committer | shishir gowda <sgowda@redhat.com> | 2013-11-15 12:37:58 +0530 |
commit | 8c89a5ffc9d1a9aa6a52a915cdd988c40aececb7 (patch) | |
tree | a5629248a8c8f78637370920c26445310c283fe3 /xlators/mgmt/glusterd/src/glusterd-snapshot.c | |
parent | 99a7b58a2983788a3bb36662d2b83c2da3b6472c (diff) |
glusterd/locks: Adding multiple volume locks supports
Also linking snap create command to mgmt_v3
Change-Id: If2ed29be072e10d0b0bd271d53e48eeaa6501ed7
Signed-off-by: Avra Sengupta <asengupt@redhat.com>
Diffstat (limited to 'xlators/mgmt/glusterd/src/glusterd-snapshot.c')
-rw-r--r-- | xlators/mgmt/glusterd/src/glusterd-snapshot.c | 14 |
1 files changed, 3 insertions, 11 deletions
diff --git a/xlators/mgmt/glusterd/src/glusterd-snapshot.c b/xlators/mgmt/glusterd/src/glusterd-snapshot.c index 0b84a5075..896fbe03b 100644 --- a/xlators/mgmt/glusterd/src/glusterd-snapshot.c +++ b/xlators/mgmt/glusterd/src/glusterd-snapshot.c @@ -32,6 +32,7 @@ #include "glusterd-store.h" #include "run.h" #include "glusterd-volgen.h" +#include "glusterd-mgmt.h" #include "syscall.h" #include "cli1-xdr.h" @@ -345,7 +346,6 @@ glusterd_handle_snapshot_fn (rpcsvc_request_t *req) dict_t *dict = NULL; gf_cli_req cli_req = {{0},}; glusterd_op_t cli_op = GD_OP_SNAP; - char operation[256] = {0,}; int type = 0; glusterd_conf_t *priv = NULL; char *host_uuid = NULL; @@ -406,20 +406,12 @@ glusterd_handle_snapshot_fn (rpcsvc_request_t *req) switch (type) { case GF_SNAP_OPTION_TYPE_CREATE: - strncpy (operation, "create", sizeof (operation)); + ret = glusterd_mgmt_v3_initiate_all_phases (req, cli_op, dict); break; } - //ret = glusterd_op_begin_synctask (req, cli_op, dict); - out: - /* Temporary Will be removed by the glusterd syncop framework */ - ret = glusterd_op_send_cli_response (cli_op, ret, 0, req, - dict, err_str); - -/* Commenting out the code coz the syncop framework - should take care of this. if (ret) { if (err_str[0] == '\0') snprintf (err_str, sizeof (err_str), @@ -427,7 +419,7 @@ out: ret = glusterd_op_send_cli_response (cli_op, ret, 0, req, dict, err_str); } -*/ + return ret; } |