From a29ab15988f46fbe98151c37676185de970fb187 Mon Sep 17 00:00:00 2001 From: Amar Tumballi Date: Sun, 13 Nov 2011 00:18:32 +0530 Subject: glusterd/cli: rpc cleanup no more backward compatibility between glusterd <-> glusterd Change-Id: Ibfcca1c7e315a90b2639c4cba8da19b11875051a BUG: 3158 Reviewed-on: http://review.gluster.com/610 Tested-by: Gluster Build System Reviewed-by: Shishir Gowda Reviewed-by: Krishnan Parthasarathi Reviewed-by: Vijay Bellur --- cli/src/cli-cmd-volume.c | 130 ----------------------------------------------- 1 file changed, 130 deletions(-) (limited to 'cli/src/cli-cmd-volume.c') diff --git a/cli/src/cli-cmd-volume.c b/cli/src/cli-cmd-volume.c index 8d3ff557..18d17b45 100644 --- a/cli/src/cli-cmd-volume.c +++ b/cli/src/cli-cmd-volume.c @@ -1151,50 +1151,6 @@ cli_cmd_volume_set_transport_cbk (struct cli_state *state, return 0; } -int -cli_cmd_log_filename_cbk (struct cli_state *state, struct cli_cmd_word *word, - const char **words, int wordcount) -{ - int ret = -1; - rpc_clnt_procedure_t *proc = NULL; - call_frame_t *frame = NULL; - dict_t *options = NULL; - int sent = 0; - int parse_error = 0; - - if (!((wordcount == 5) || (wordcount == 6))) { - cli_usage_out (word->pattern); - parse_error = 1; - goto out; - } - - proc = &cli_rpc_prog->proctable[GLUSTER_CLI_LOG_FILENAME]; - - frame = create_frame (THIS, THIS->ctx->pool); - if (!frame) - goto out; - - ret = cli_cmd_log_filename_parse (words, wordcount, &options); - if (ret) - goto out; - - if (proc->fn) { - ret = proc->fn (frame, THIS, options); - } - -out: - if (options) - dict_destroy (options); - - if (ret) { - cli_cmd_sent_status_get (&sent); - if ((sent == 0) && (parse_error == 0)) - cli_out ("Volume log filename failed"); - } - - return ret; -} - int cli_cmd_volume_top_cbk (struct cli_state *state, struct cli_cmd_word *word, const char **words, int wordcount) @@ -1239,49 +1195,6 @@ out: } -int -cli_cmd_log_locate_cbk (struct cli_state *state, struct cli_cmd_word *word, - const char **words, int wordcount) -{ - int ret = -1; - rpc_clnt_procedure_t *proc = NULL; - call_frame_t *frame = NULL; - dict_t *options = NULL; - int sent = 0; - int parse_error = 0; - - if (!((wordcount == 4) || (wordcount == 5))) { - cli_usage_out (word->pattern); - parse_error = 1; - goto out; - } - - proc = &cli_rpc_prog->proctable[GLUSTER_CLI_LOG_LOCATE]; - - frame = create_frame (THIS, THIS->ctx->pool); - if (!frame) - goto out; - - ret = cli_cmd_log_locate_parse (words, wordcount, &options); - if (ret) - goto out; - - if (proc->fn) { - ret = proc->fn (frame, THIS, options); - } - -out: - if (options) - dict_destroy (options); - - if (ret) { - cli_cmd_sent_status_get (&sent); - if ((sent == 0) && (parse_error == 0)) - cli_out ("getting log file location information failed"); - } - - return ret; -} int cli_cmd_log_rotate_cbk (struct cli_state *state, struct cli_cmd_word *word, @@ -1429,37 +1342,6 @@ out: return ret; } -int -cli_cmd_log_level_cbk (struct cli_state *state, struct cli_cmd_word *word, - const char **words, int wordcount) -{ - int ret = -1; - rpc_clnt_procedure_t *proc = NULL; - call_frame_t *frame = NULL; - dict_t *dict = NULL; - - if (wordcount != 6) { - cli_usage_out (word->pattern); - goto out; - } - - proc = &cli_rpc_prog->proctable[GLUSTER_CLI_LOG_LEVEL]; - - frame = create_frame (THIS, THIS->ctx->pool); - if (!frame) - goto out; - - ret = cli_cmd_log_level_parse (words, wordcount, &dict); - if (ret) - goto out; - - if (proc->fn) - ret = proc->fn (frame, THIS, dict); - - out: - return ret; -} - int cli_cmd_volume_status_cbk (struct cli_state *state, struct cli_cmd_word *word, @@ -1695,14 +1577,6 @@ struct cli_cmd volume_cmds[] = { cli_cmd_volume_help_cbk, "display help for the volume command"}, - { "volume log filename [BRICK] ", - cli_cmd_log_filename_cbk, - "set the log file for corresponding volume/brick"}, - - { "volume log locate [BRICK]", - cli_cmd_log_locate_cbk, - "locate the log file for corresponding volume/brick"}, - { "volume log rotate [BRICK]", cli_cmd_log_rotate_cbk, "rotate the log file for corresponding volume/brick"}, @@ -1736,10 +1610,6 @@ struct cli_cmd volume_cmds[] = { cli_cmd_volume_top_cbk, "volume top operations"}, - {"volume log level ", - cli_cmd_log_level_cbk, - "log level for translator"}, - { "volume status ", cli_cmd_volume_status_cbk, "display status of specified volume"}, -- cgit