[ https://issues.apache.org/jira/browse/HAWQ-109?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14980294#comment-14980294 ]
ASF GitHub Bot commented on HAWQ-109: ------------------------------------- Github user hornn commented on a diff in the pull request: https://github.com/apache/incubator-hawq/pull/59#discussion_r43374066 --- Diff: tools/bin/hawq --- @@ -51,71 +57,69 @@ def main(): print START_HELP sys.exit(1) cmd = "%s; hawq_ctl %s %s" % (source_hawq_env, hawq_command, sub_args) - local_ssh(cmd) + result = local_ssh(cmd) elif hawq_command == "stop": if second_arg not in cluster_type_list: print STOP_HELP sys.exit(1) cmd = "%s; hawq_ctl %s %s" % (source_hawq_env, hawq_command, sub_args) - local_ssh(cmd) + result = local_ssh(cmd) elif hawq_command == "init": if second_arg not in cluster_init_list: print INIT_HELP sys.exit(1) cmd = "%s; hawq_ctl %s %s" % (source_hawq_env, hawq_command, sub_args) - local_ssh(cmd) + result = local_ssh(cmd) elif hawq_command == "restart": if second_arg not in cluster_type_list: print START_HELP sys.exit(1) cmd = "%s; hawq_ctl stop %s" % (source_hawq_env, sub_args) - local_ssh(cmd) + result = local_ssh(cmd) --- End diff -- In restart, if stop fails I think start should not be performed. I can open a separate JIRA if you think it's not relevant to this one. > Fix exit code of hawq command line tools > ---------------------------------------- > > Key: HAWQ-109 > URL: https://issues.apache.org/jira/browse/HAWQ-109 > Project: Apache HAWQ > Issue Type: Bug > Components: Command Line Tools > Reporter: Radar Lei > Assignee: Radar Lei > > If hawq command fails to perform a specific operation, we should ensure that > the return code is non-zero. -- This message was sent by Atlassian JIRA (v6.3.4#6332)