Program: 48329
Project: 48329
Buggy source:
@CliCommand(value="String_Node_Str",help="String_Node_Str") public void addCluster(@CliOption(key={"String_Node_Str"},mandatory=true,help="String_Node_Str") final String name,@CliOption(key={"String_Node_Str"},mandatory=false,specifiedDefaultValue="String_Node_Str",unspecifiedDefaultValue="String_Node_Str",help="String_Node_Str") final boolean nodeGroup,@CliOption(key={"String_Node_Str"},mandatory=true,help="String_Node_Str") final String specFilePath,@CliOption(key={"String_Node_Str"},mandatory=false,specifiedDefaultValue="String_Node_Str",unspecifiedDefaultValue="String_Node_Str",help="String_Node_Str") final boolean resume){
  try {
    if (resume) {
      resumeCreateCluster(name);
      CommandsUtils.printCmdSuccess(Constants.OUTPUT_OBJECT_CLUSTER,Constants.OUTPUT_OP_ADD + Constants.OUTPUT_OP_RESULT_SUCCEEDED);
      return;
    }
    if (!nodeGroup) {
      CommandsUtils.printCmdFailure(Constants.OUTPUT_OBJECT_CLUSTER,Constants.OUTPUT_OP_ADD,Constants.OUTPUT_OP_RESULT_FAIL,Constants.PARAM_NOT_CONTAIN_SPECFILE);
      return;
    }
    if (specFilePath == null) {
      CommandsUtils.printCmdFailure(Constants.OUTPUT_OBJECT_CLUSTER,Constants.OUTPUT_OP_ADD,Constants.OUTPUT_OP_RESULT_FAIL,Constants.PARAM_NOT_CONTAIN_SPECFILE);
      return;
    }
    ClusterRead cluster=restClient.get(name,false);
    if (cluster == null) {
      CommandsUtils.printCmdFailure(Constants.OUTPUT_OBJECT_CLUSTER,Constants.OUTPUT_OP_ADD,Constants.OUTPUT_OP_RESULT_FAIL,"String_Node_Str" + name + "String_Node_Str");
      return;
    }
    NodeGroupAdd nodeGroupAdd=new NodeGroupAdd();
    NodeGroupAdd nodeGroupAddSpec=CommandsUtils.getObjectByJsonString(NodeGroupAdd.class,CommandsUtils.dataFromFile(specFilePath));
    nodeGroupAdd.setSpecFile(true);
    nodeGroupAdd.setNodeGroups(nodeGroupAddSpec.getNodeGroups());
    if (name.indexOf("String_Node_Str") != -1) {
      CommandsUtils.printCmdFailure(Constants.OUTPUT_OBJECT_CLUSTER,Constants.OUTPUT_OP_ADD,Constants.OUTPUT_OP_RESULT_FAIL,Constants.PARAM_NODEGROUP + Constants.PARAM_NOT_CONTAIN_HORIZONTAL_LINE);
      return;
    }
 else     if (name.indexOf("String_Node_Str") != -1) {
      CommandsUtils.printCmdFailure(Constants.OUTPUT_OBJECT_CLUSTER,Constants.OUTPUT_OP_ADD,Constants.OUTPUT_OP_RESULT_FAIL,Constants.PARAM_NODEGROUP + Constants.PARAM_NOT_CONTAIN_BLANK_SPACE);
      return;
    }
    restClient.addNodeGroups(name,nodeGroupAdd);
    CommandsUtils.printCmdSuccess(Constants.OUTPUT_OBJECT_CLUSTER,Constants.OUTPUT_OP_ADD + Constants.OUTPUT_OP_RESULT_SUCCEEDED);
  }
 catch (  Exception e) {
    CommandsUtils.printCmdFailure(Constants.OUTPUT_OBJECT_CLUSTER,Constants.OUTPUT_OP_ADD,Constants.OUTPUT_OP_RESULT_FAIL,e.getMessage());
    return;
  }
}

Fixed version (ground truth):
@CliCommand(value="String_Node_Str",help="String_Node_Str") public void addCluster(@CliOption(key={"String_Node_Str"},mandatory=true,help="String_Node_Str") final String name,@CliOption(key={"String_Node_Str"},mandatory=true,specifiedDefaultValue="String_Node_Str",unspecifiedDefaultValue="String_Node_Str",help="String_Node_Str") final boolean nodeGroup,@CliOption(key={"String_Node_Str"},mandatory=true,help="String_Node_Str") final String specFilePath,@CliOption(key={"String_Node_Str"},mandatory=false,specifiedDefaultValue="String_Node_Str",unspecifiedDefaultValue="String_Node_Str",help="String_Node_Str") final boolean resume){
  try {
    if (resume) {
      resumeCreateCluster(name);
      return;
    }
    if (!nodeGroup) {
      CommandsUtils.printCmdFailure(Constants.OUTPUT_OBJECT_CLUSTER,Constants.OUTPUT_OP_ADD,Constants.OUTPUT_OP_RESULT_FAIL,Constants.PARAM_NOT_CONTAIN_SPECFILE);
      return;
    }
    if (specFilePath == null) {
      CommandsUtils.printCmdFailure(Constants.OUTPUT_OBJECT_CLUSTER,Constants.OUTPUT_OP_ADD,Constants.OUTPUT_OP_RESULT_FAIL,Constants.PARAM_NOT_CONTAIN_SPECFILE);
      return;
    }
    ClusterRead cluster=restClient.get(name,false);
    if (cluster == null) {
      CommandsUtils.printCmdFailure(Constants.OUTPUT_OBJECT_CLUSTER,Constants.OUTPUT_OP_ADD,Constants.OUTPUT_OP_RESULT_FAIL,"String_Node_Str" + name + "String_Node_Str");
      return;
    }
    NodeGroupAdd nodeGroupAdd=new NodeGroupAdd();
    NodeGroupAdd nodeGroupAddSpec=CommandsUtils.getObjectByJsonString(NodeGroupAdd.class,CommandsUtils.dataFromFile(specFilePath));
    nodeGroupAdd.setSpecFile(true);
    nodeGroupAdd.setNodeGroups(nodeGroupAddSpec.getNodeGroups());
    if (name.indexOf("String_Node_Str") != -1) {
      CommandsUtils.printCmdFailure(Constants.OUTPUT_OBJECT_CLUSTER,Constants.OUTPUT_OP_ADD,Constants.OUTPUT_OP_RESULT_FAIL,Constants.PARAM_NODEGROUP + Constants.PARAM_NOT_CONTAIN_HORIZONTAL_LINE);
      return;
    }
 else     if (name.indexOf("String_Node_Str") != -1) {
      CommandsUtils.printCmdFailure(Constants.OUTPUT_OBJECT_CLUSTER,Constants.OUTPUT_OP_ADD,Constants.OUTPUT_OP_RESULT_FAIL,Constants.PARAM_NODEGROUP + Constants.PARAM_NOT_CONTAIN_BLANK_SPACE);
      return;
    }
    restClient.addNodeGroups(name,nodeGroupAdd);
    CommandsUtils.printCmdSuccess(Constants.OUTPUT_OBJECT_CLUSTER,Constants.OUTPUT_OP_RESULT_ADD);
  }
 catch (  Exception e) {
    CommandsUtils.printCmdFailure(Constants.OUTPUT_OBJECT_CLUSTER,Constants.OUTPUT_OP_ADD,Constants.OUTPUT_OP_RESULT_FAIL,e.getMessage());
    return;
  }
}