nus-yam/ex-repair huggingface dataset:
Program: 42451
Project: 42451
Buggy source:
private void setElementList(final ApsProperties config,final JAXBTaskList taskList) throws ApsSystemException {
  final String groups="String_Node_Str" + config.getProperty("String_Node_Str").replace("String_Node_Str","String_Node_Str").replace("String_Node_Str","String_Node_Str");
  final List<JAXBTask> list=new ArrayList<>();
  final List<KieTask> rawList=this.getKieFormManager().getHumanTaskList(groups,null);
  for (  final KieTask task : rawList) {
    list.add(new JAXBTask(task));
  }
  taskList.setList(list);
}

Fixed version (ground truth):
private void setElementList(final ApsProperties config,final JAXBTaskList taskList) throws ApsSystemException {
  final String groups=config.getProperty("String_Node_Str").replace("String_Node_Str","String_Node_Str");
  final List<JAXBTask> list=new ArrayList<>();
  final List<KieTask> rawList=this.getKieFormManager().getHumanTaskList(groups,null);
  for (  final KieTask task : rawList) {
    list.add(new JAXBTask(task));
  }
  taskList.setList(list);
}
Program: 42452
Project: 42452
Buggy source:
public JAXBTask getTask(Properties properties) throws Throwable {
  JAXBTask resTask=null;
  final String idString=properties.getProperty("String_Node_Str");
  final String page=properties.getProperty("String_Node_Str");
  final String pageSize=properties.getProperty("String_Node_Str");
  final String user=properties.getProperty("String_Node_Str");
  HashMap<String,String> opt=new HashMap<>();
  int id;
  try {
    id=Integer.parseInt(idString);
    if (StringUtils.isNotBlank("String_Node_Str")) {
      opt.put("String_Node_Str",page);
    }
    if (StringUtils.isNotBlank("String_Node_Str")) {
      opt.put("String_Node_Str",pageSize);
    }
    if (StringUtils.isNotBlank("String_Node_Str")) {
      opt.put("String_Node_Str",user);
    }
  }
 catch (  NumberFormatException e) {
    throw new ApiException(IApiErrorCodes.API_PARAMETER_VALIDATION_ERROR,"String_Node_Str" + idString + "String_Node_Str",Response.Status.CONFLICT);
  }
  List<KieTask> rawList=this.getKieFormManager().getHumanTaskList("String_Node_Str",opt);
  for (  KieTask task : rawList) {
    if (id == task.getId()) {
      resTask=new JAXBTask(task);
      break;
    }
  }
  if (null == resTask) {
    throw new ApiException(IApiErrorCodes.API_VALIDATION_ERROR,"String_Node_Str" + idString + "String_Node_Str",Response.Status.CONFLICT);
  }
  return resTask;
}

Fixed version (ground truth):
public JAXBTask getTask(Properties properties) throws Throwable {
  JAXBTask resTask=null;
  final String idString=properties.getProperty("String_Node_Str");
  final String page=properties.getProperty("String_Node_Str");
  final String pageSize=properties.getProperty("String_Node_Str");
  final String user=properties.getProperty("String_Node_Str");
  HashMap<String,String> opt=new HashMap<>();
  int id;
  try {
    id=Integer.parseInt(idString);
    if (StringUtils.isNotBlank("String_Node_Str")) {
      opt.put("String_Node_Str",page);
    }
    if (StringUtils.isNotBlank("String_Node_Str")) {
      opt.put("String_Node_Str",pageSize);
    }
    if (StringUtils.isNotBlank("String_Node_Str")) {
      opt.put("String_Node_Str",user);
    }
  }
 catch (  NumberFormatException e) {
    throw new ApiException(IApiErrorCodes.API_PARAMETER_VALIDATION_ERROR,"String_Node_Str" + idString + "String_Node_Str",Response.Status.CONFLICT);
  }
  try {
    List<KieTask> rawList=this.getKieFormManager().getHumanTaskList("String_Node_Str",opt);
    for (    KieTask task : rawList) {
      if (id == task.getId()) {
        resTask=new JAXBTask(task);
        break;
      }
    }
    if (null == resTask) {
      throw new ApiException(IApiErrorCodes.API_VALIDATION_ERROR,"String_Node_Str" + idString + "String_Node_Str",Response.Status.CONFLICT);
    }
  }
 catch (  Exception ex) {
    logger.error("String_Node_Str",ex);
    throw ex;
  }
  return resTask;
}
Program: 42453
Project: 42453
Buggy source:
public KieApiForm getTaskForm(Properties properties) throws Throwable {
  String containerId=properties.getProperty("String_Node_Str");
  String taskIdString=properties.getProperty("String_Node_Str");
  String langCode=properties.getProperty(SystemConstants.API_LANG_CODE_PARAMETER);
  KieApiForm form=null;
  KieProcessFormQueryResult processForm=this.getKieFormManager().getTaskForm(containerId,Long.valueOf(taskIdString));
  if (null == processForm) {
    String msg=String.format("String_Node_Str",containerId,taskIdString);
    throw new ApiException(IApiErrorCodes.API_VALIDATION_ERROR,msg,Response.Status.CONFLICT);
  }
  String processId=processForm.getHolders().get(0).getValue();
  try {
    this.setLabels(processForm,langCode);
    form=KieApiUtil.createForm(processForm,this.getI18nManager(),langCode,this.getFormOverridesMap(containerId,processId,null));
    form.setTaskId(taskIdString);
    form.setContainerId(containerId);
  }
 catch (  Exception e) {
    e.printStackTrace();
  }
  return form;
}

Fixed version (ground truth):
public KieApiForm getTaskForm(Properties properties) throws Throwable {
  String containerId=properties.getProperty("String_Node_Str");
  String taskIdString=properties.getProperty("String_Node_Str");
  String langCode=properties.getProperty(SystemConstants.API_LANG_CODE_PARAMETER);
  KieApiForm form=null;
  KieProcessFormQueryResult processForm=this.getKieFormManager().getTaskForm(containerId,Long.valueOf(taskIdString));
  if (null == processForm) {
    String msg=String.format("String_Node_Str",containerId,taskIdString);
    throw new ApiException(IApiErrorCodes.API_VALIDATION_ERROR,msg,Response.Status.CONFLICT);
  }
  String processId=processForm.getHolders().get(0).getValue();
  try {
    this.setLabels(processForm,langCode);
    form=KieApiUtil.createForm(processForm,this.getI18nManager(),langCode,this.getFormOverridesMap(containerId,processId,null));
    form.setTaskId(taskIdString);
    form.setContainerId(containerId);
    form.setProcessId(processId);
  }
 catch (  Exception e) {
    e.printStackTrace();
  }
  return form;
}
Program: 42454
Project: 42454
Buggy source:
@Override public List<KieTask> getHumanTaskList(String groups,Map<String,String> opt) throws ApsSystemException {
  Map<String,String> headersMap=new HashMap<>();
  List<KieTask> list=new ArrayList<>();
  if (!config.getActive()) {
    return list;
  }
  try {
    Endpoint ep=KieEndpointDictionary.create().get(API_GET_HUMAN_TASK_LIST);
    KieClient client=getCurrentClient();
    headersMap.put(HEADER_KEY_ACCEPT,HEADER_VALUE_JSON);
    KieTaskQueryResult result=(KieTaskQueryResult)new KieRequestBuilder(client).setEndpoint(ep).setHeaders(headersMap).setRequestParams(opt).setDebug(config.getDebug()).doRequest(KieTaskQueryResult.class);
    if (null != result && null != result.getList() && !result.getList().isEmpty()) {
      list=result.getList();
    }
  }
 catch (  Throwable t) {
    throw new ApsSystemException("String_Node_Str",t);
  }
  return list;
}

Fixed version (ground truth):
@Override public List<KieTask> getHumanTaskList(String groups,Map<String,String> opt) throws ApsSystemException {
  logger.info("String_Node_Str",groups,opt);
  Map<String,String> headersMap=new HashMap<>();
  List<KieTask> list=new ArrayList<>();
  if (!config.getActive()) {
    return list;
  }
  try {
    Endpoint ep=KieEndpointDictionary.create().get(API_GET_HUMAN_TASK_LIST);
    KieClient client=getCurrentClient();
    headersMap.put(HEADER_KEY_ACCEPT,HEADER_VALUE_JSON);
    RequestBuilder requestBuilder=new KieRequestBuilder(client).setEndpoint(ep).setHeaders(headersMap).setRequestParams(opt).setDebug(config.getDebug());
    if (groups != null && !"String_Node_Str".equalsIgnoreCase(groups)) {
      Map<String,String> recurringParameters=new HashMap<String,String>();
      recurringParameters.put("String_Node_Str",groups);
      ((KieRequestBuilder)requestBuilder).setRecurringParameters(recurringParameters);
    }
    KieTaskQueryResult result=(KieTaskQueryResult)requestBuilder.doRequest(KieTaskQueryResult.class);
    if (null != result && null != result.getList() && !result.getList().isEmpty()) {
      list=result.getList();
    }
  }
 catch (  Throwable t) {
    throw new ApsSystemException("String_Node_Str",t);
  }
  return list;
}
Program: 42455
Project: 42455
Buggy source:
@Override public List<kieProcess> getProcessDefinitionsList() throws ApsSystemException {
  Map<String,String> headersMap=new HashMap<>();
  List<kieProcess> list=new ArrayList<>();
  if (!config.getActive()) {
    return list;
  }
  try {
    KieClient client=getCurrentClient();
    headersMap.put(HEADER_KEY_ACCEPT,HEADER_VALUE_JSON);
    KieProcessesQueryResult result=(KieProcessesQueryResult)new KieRequestBuilder(client).setEndpoint(KieEndpointDictionary.create().get(API_GET_PROCESS_DEFINITIONS_LIST)).setHeaders(headersMap).setDebug(config.getDebug()).doRequest(KieProcessesQueryResult.class);
    if (null != result && null != result.getProcesses() && !result.getProcesses().isEmpty()) {
      list=result.getProcesses();
    }
  }
 catch (  Throwable t) {
    throw new ApsSystemException("String_Node_Str",t);
  }
  return list;
}

Fixed version (ground truth):
@Override public List<kieProcess> getProcessDefinitionsList() throws ApsSystemException {
  Map<String,String> headersMap=new HashMap<>();
  List<kieProcess> list=new ArrayList<>();
  if (!config.getActive()) {
    return list;
  }
  try {
    KieClient client=getCurrentClient();
    headersMap.put(HEADER_KEY_ACCEPT,HEADER_VALUE_JSON);
    KieProcessesQueryResult result=(KieProcessesQueryResult)new KieRequestBuilder(client).setEndpoint(KieEndpointDictionary.create().get(API_GET_PROCESS_DEFINITIONS_LIST)).setHeaders(headersMap).setDebug(config.getDebug()).doRequest(KieProcessesQueryResult.class);
    if (null != result && null != result.getProcesses() && !result.getProcesses().isEmpty()) {
      list=result.getProcesses();
      for (      kieProcess process : list) {
        process.setKieSourceId(config.getId());
      }
    }
  }
 catch (  Throwable t) {
    throw new ApsSystemException("String_Node_Str",t);
  }
  return list;
}
Program: 42456
Project: 42456
Buggy source:
@Override public KieProcessFormQueryResult getProcessForm(String containerId,String processId) throws ApsSystemException {
  KieProcessFormQueryResult result=null;
  if (!config.getActive() || StringUtils.isBlank(containerId) || StringUtils.isBlank(processId)) {
    return result;
  }
  try {
    Endpoint ep=KieEndpointDictionary.create().get(API_GET_PROCESS_DEFINITION).resolveParams(containerId,processId);
    KieClient client=getCurrentClient();
    result=(KieProcessFormQueryResult)new KieRequestBuilder(client).setEndpoint(ep).setDebug(config.getDebug()).setUnmarshalOptions(false,true).doRequest(KieProcessFormQueryResult.class);
  }
 catch (  Throwable t) {
    throw new ApsSystemException("String_Node_Str",t);
  }
  try {
    List<KieFormOverride> overrides=overrideManager.getFormOverrides(containerId,processId);
    BpmToFormHelper.appendOverridesToForm(result,overrides);
  }
 catch (  Throwable t) {
    logger.error("String_Node_Str",t);
  }
  return result;
}

Fixed version (ground truth):
@Override public KieProcessFormQueryResult getProcessForm(String containerId,String processId) throws ApsSystemException {
  logger.info("String_Node_Str",containerId,processId);
  KieProcessFormQueryResult result=null;
  if (!config.getActive() || StringUtils.isBlank(containerId) || StringUtils.isBlank(processId)) {
    return result;
  }
  try {
    Endpoint ep=KieEndpointDictionary.create().get(API_GET_PROCESS_DEFINITION).resolveParams(containerId,processId);
    KieClient client=getCurrentClient();
    result=(KieProcessFormQueryResult)new KieRequestBuilder(client).setEndpoint(ep).setDebug(config.getDebug()).setUnmarshalOptions(false,true).doRequest(KieProcessFormQueryResult.class);
  }
 catch (  Throwable t) {
    throw new ApsSystemException("String_Node_Str",t);
  }
  try {
    List<KieFormOverride> overrides=overrideManager.getFormOverrides(containerId,processId);
    BpmToFormHelper.appendOverridesToForm(result,overrides);
  }
 catch (  Throwable t) {
    logger.error("String_Node_Str",t);
  }
  return result;
}
Program: 42458
Project: 42458
Buggy source:
@Override public synchronized KieServerConfigDto addConfig(KieServerConfigDto configRequest){
  KieServerConfigDto configDto=null;
  try {
    KieBpmConfig newConfig=this.buildConfig(configDto);
    this.getKieFormManager().addConfig(newConfig);
    this.getKieFormManager().getContainersList();
  }
 catch (  Exception t) {
    logger.error("String_Node_Str",t);
    throw new RestServerError("String_Node_Str",t);
  }
  return configDto;
}

Fixed version (ground truth):
@Override public synchronized KieServerConfigDto addConfig(KieServerConfigDto configRequest){
  KieServerConfigDto configDto=null;
  try {
    KieBpmConfig newConfig=this.buildConfig(configRequest);
    this.getKieFormManager().addConfig(newConfig);
    this.getKieFormManager().getContainersList();
    configDto=this.getKieServerConfigDtoBuilder().convert(newConfig);
  }
 catch (  Exception t) {
    logger.error("String_Node_Str",t);
    throw new RestServerError("String_Node_Str",t);
  }
  return configDto;
}
Program: 42459
Project: 42459
Buggy source:
@Override public KieServerConfigDto updateConfig(KieServerConfigDto configRequest){
  KieServerConfigDto configDto=null;
  try {
    Map<String,KieBpmConfig> map=this.getKieFormManager().getKieServerConfigurations();
    KieBpmConfig config=map.get(configRequest.getId());
    if (null == config) {
      throw new RestRourceNotFoundException(ConfigValidator.ERRCODE_CONFIG_NOT_FOUND,"String_Node_Str",configRequest.getId());
    }
    this.getKieFormManager().setKieServerConfiguration(configRequest.getId());
    this.getKieFormManager().addConfig(config);
    this.getKieFormManager().getContainersList();
  }
 catch (  RestRourceNotFoundException t) {
    throw t;
  }
catch (  Exception t) {
    logger.error("String_Node_Str",t);
    throw new RestServerError("String_Node_Str",t);
  }
  return configDto;
}

Fixed version (ground truth):
@Override public KieServerConfigDto updateConfig(KieServerConfigDto configRequest){
  KieServerConfigDto configDto=null;
  try {
    Map<String,KieBpmConfig> map=this.getKieFormManager().getKieServerConfigurations();
    KieBpmConfig config=map.get(configRequest.getId());
    if (null == config) {
      throw new RestRourceNotFoundException(ConfigValidator.ERRCODE_CONFIG_NOT_FOUND,"String_Node_Str",configRequest.getId());
    }
    KieBpmConfig newConfig=this.buildConfig(configRequest);
    this.getKieFormManager().setKieServerConfiguration(configRequest.getId());
    this.getKieFormManager().addConfig(newConfig);
    this.getKieFormManager().getContainersList();
    configDto=this.getKieServerConfigDtoBuilder().convert(newConfig);
  }
 catch (  RestRourceNotFoundException t) {
    throw t;
  }
catch (  Exception t) {
    logger.error("String_Node_Str",t);
    throw new RestServerError("String_Node_Str",t);
  }
  return configDto;
}
Program: 42460
Project: 42460
Buggy source:
public String view(){
  try {
    String frontEndCaseDataIn=extractWidgetConfig("String_Node_Str");
    this.setFrontEndCaseData(frontEndCaseDataIn);
    if ((!StringUtils.isBlank(this.getKnowledgeSourceId()) || !StringUtils.isBlank(this.getContainerid()) || !StringUtils.isBlank(this.getCasePath())|| !StringUtils.isBlank(this.getChannelPath())) && (this.getChannelPath().equalsIgnoreCase(this.getFrontEndCaseData()))) {
      this.getCaseManager().setKieServerConfiguration(this.getKnowledgeSourceId());
      this.setCaseInstanceDetails(this.getCaseManager().getCaseInstancesDetails(this.getContainerid(),this.getCasePath()).toString());
    }
 else {
      this.setKnowledgeSourceId(this.getCaseManager().loadFirstConfigurations().getId());
      this.setContainerid(this.getCaseManager().getContainersList().get(0).getContainerId());
      this.setCasePath(this.getCaseManager().getCaseInstancesList(this.getContainerid()).get(0));
      this.setCaseInstanceDetails(this.getCaseManager().getCaseInstancesDetails(this.getContainerid(),this.getCasePath()).toString());
    }
  }
 catch (  ApsSystemException t) {
    logger.error("String_Node_Str",t);
    return FAILURE;
  }
  return SUCCESS;
}

Fixed version (ground truth):
public String view(){
  try {
    String frontEndCaseDataIn=extractWidgetConfig("String_Node_Str");
    this.setFrontEndCaseData(frontEndCaseDataIn);
    String channelIn=extractWidgetConfig("String_Node_Str");
    this.setChannel(channelIn);
    if ((!StringUtils.isBlank(this.getKnowledgeSourceId()) || !StringUtils.isBlank(this.getContainerid()) || !StringUtils.isBlank(this.getCasePath())|| !StringUtils.isBlank(this.getChannelPath())) && (this.getChannelPath().equalsIgnoreCase(this.getChannel()))) {
      this.getCaseManager().setKieServerConfiguration(this.getKnowledgeSourceId());
      this.setCaseInstanceDetails(this.getCaseManager().getCaseInstancesDetails(this.getContainerid(),this.getCasePath()).toString());
    }
 else {
      this.setKnowledgeSourceId(this.getCaseManager().loadFirstConfigurations().getId());
      this.setContainerid(this.getCaseManager().getContainersList().get(0).getContainerId());
      this.setCasePath(this.getCaseManager().getCaseInstancesList(this.getContainerid()).get(0));
      this.setCaseInstanceDetails(this.getCaseManager().getCaseInstancesDetails(this.getContainerid(),this.getCasePath()).toString());
      this.setChannelPath(this.getChannel());
    }
  }
 catch (  ApsSystemException t) {
    logger.error("String_Node_Str",t);
    return FAILURE;
  }
  return SUCCESS;
}
Program: 42461
Project: 42461
Buggy source:
public String deleteComment(){
  try {
    String frontEndCaseDataIn=extractWidgetConfig("String_Node_Str");
    this.setFrontEndCaseData(frontEndCaseDataIn);
    if (this.getChannelPath().equalsIgnoreCase(this.getFrontEndCaseData())) {
      this.getCaseManager().setKieServerConfiguration(this.getKnowledgeSourceId());
      this.getCaseManager().deleteCaseComments(this.getContainerid(),this.getCasePath(),this.getCaseCommentId());
      this.setComments(this.getCaseManager().getCaseComments(this.getContainerid(),this.getCasePath()).toString());
    }
  }
 catch (  ApsSystemException t) {
    logger.error("String_Node_Str",t);
    return FAILURE;
  }
  return SUCCESS;
}

Fixed version (ground truth):
public String deleteComment(){
  try {
    String frontEndCaseDataIn=extractWidgetConfig("String_Node_Str");
    this.setFrontEndCaseData(frontEndCaseDataIn);
    String channelIn=extractWidgetConfig("String_Node_Str");
    this.setChannel(channelIn);
    if (this.getChannelPath().equalsIgnoreCase(this.getChannel())) {
      this.getCaseManager().setKieServerConfiguration(this.getKnowledgeSourceId());
      this.getCaseManager().deleteCaseComments(this.getContainerid(),this.getCasePath(),this.getCaseCommentId());
      this.setComments(this.getCaseManager().getCaseComments(this.getContainerid(),this.getCasePath()).toString());
    }
  }
 catch (  ApsSystemException t) {
    logger.error("String_Node_Str",t);
    return FAILURE;
  }
  return SUCCESS;
}
Program: 42462
Project: 42462
Buggy source:
public String updateComment(){
  try {
    String frontEndCaseDataIn=extractWidgetConfig("String_Node_Str");
    this.setFrontEndCaseData(frontEndCaseDataIn);
    if (this.getChannelPath().equalsIgnoreCase(this.getFrontEndCaseData())) {
      this.getCaseManager().setKieServerConfiguration(this.getKnowledgeSourceId());
      this.getCaseManager().updateCaseComments(this.getContainerid(),this.getCasePath(),this.getCaseCommentId(),this.getCommentInput());
      this.setComments(this.getCaseManager().getCaseComments(this.getContainerid(),this.getCasePath()).toString());
    }
  }
 catch (  ApsSystemException t) {
    logger.error("String_Node_Str",t);
    return FAILURE;
  }
  return SUCCESS;
}

Fixed version (ground truth):
public String updateComment(){
  try {
    String frontEndCaseDataIn=extractWidgetConfig("String_Node_Str");
    this.setFrontEndCaseData(frontEndCaseDataIn);
    String channelIn=extractWidgetConfig("String_Node_Str");
    this.setChannel(channelIn);
    if (this.getChannelPath().equalsIgnoreCase(this.getChannel())) {
      this.getCaseManager().setKieServerConfiguration(this.getKnowledgeSourceId());
      this.getCaseManager().updateCaseComments(this.getContainerid(),this.getCasePath(),this.getCaseCommentId(),this.getCommentInput());
      this.setComments(this.getCaseManager().getCaseComments(this.getContainerid(),this.getCasePath()).toString());
    }
  }
 catch (  ApsSystemException t) {
    logger.error("String_Node_Str",t);
    return FAILURE;
  }
  return SUCCESS;
}
Program: 42463
Project: 42463
Buggy source:
public String view(){
  try {
    String frontEndCaseDataIn=extractWidgetConfig("String_Node_Str");
    this.setFrontEndCaseData(frontEndCaseDataIn);
    if ((!StringUtils.isBlank(this.getKnowledgeSourceId()) || !StringUtils.isBlank(this.getContainerid()) || !StringUtils.isBlank(this.getCasePath())|| !StringUtils.isBlank(this.getChannelPath())) && (this.getChannelPath().equalsIgnoreCase(this.getFrontEndCaseData()))) {
      this.getCaseManager().setKieServerConfiguration(this.getKnowledgeSourceId());
      this.setComments(this.getCaseManager().getCaseComments(this.getContainerid(),this.getCasePath()).toString());
    }
 else {
      this.setKnowledgeSourceId(this.getCaseManager().loadFirstConfigurations().getId());
      this.setContainerid(this.getCaseManager().getContainersList().get(0).getContainerId());
      this.setCasePath(this.getCaseManager().getCaseInstancesList(this.getContainerid()).get(0));
      this.setComments(this.getCaseManager().getCaseComments(this.getContainerid(),this.getCasePath()).toString());
      this.setChannelPath(this.getFrontEndCaseData());
    }
  }
 catch (  ApsSystemException t) {
    logger.error("String_Node_Str",t);
    return FAILURE;
  }
  return SUCCESS;
}

Fixed version (ground truth):
public String view(){
  try {
    String frontEndCaseDataIn=extractWidgetConfig("String_Node_Str");
    this.setFrontEndCaseData(frontEndCaseDataIn);
    String channelIn=extractWidgetConfig("String_Node_Str");
    this.setChannel(channelIn);
    if ((!StringUtils.isBlank(this.getKnowledgeSourceId()) || !StringUtils.isBlank(this.getContainerid()) || !StringUtils.isBlank(this.getCasePath())|| !StringUtils.isBlank(this.getChannelPath())) && (this.getChannelPath().equalsIgnoreCase(this.getChannel()))) {
      this.getCaseManager().setKieServerConfiguration(this.getKnowledgeSourceId());
      this.setComments(this.getCaseManager().getCaseComments(this.getContainerid(),this.getCasePath()).toString());
      this.setChannelPath(this.getChannel());
    }
 else {
      this.setKnowledgeSourceId(this.getCaseManager().loadFirstConfigurations().getId());
      this.setContainerid(this.getCaseManager().getContainersList().get(0).getContainerId());
      this.setCasePath(this.getCaseManager().getCaseInstancesList(this.getContainerid()).get(0));
      this.setComments(this.getCaseManager().getCaseComments(this.getContainerid(),this.getCasePath()).toString());
      this.setChannelPath(this.getChannel());
    }
  }
 catch (  ApsSystemException t) {
    logger.error("String_Node_Str",t);
    return FAILURE;
  }
  return SUCCESS;
}
Program: 42464
Project: 42464
Buggy source:
public String postComment(){
  try {
    String frontEndCaseDataIn=extractWidgetConfig("String_Node_Str");
    this.setFrontEndCaseData(frontEndCaseDataIn);
    if (this.getChannelPath().equalsIgnoreCase(this.getFrontEndCaseData())) {
      this.getCaseManager().setKieServerConfiguration(this.getKnowledgeSourceId());
      this.getCaseManager().postCaseComments(this.getContainerid(),this.getCasePath(),this.getCommentInput());
      this.setComments(this.getCaseManager().getCaseComments(this.getContainerid(),this.getCasePath()).toString());
    }
  }
 catch (  ApsSystemException t) {
    logger.error("String_Node_Str",t);
    return FAILURE;
  }
  return SUCCESS;
}

Fixed version (ground truth):
public String postComment(){
  try {
    String frontEndCaseDataIn=extractWidgetConfig("String_Node_Str");
    this.setFrontEndCaseData(frontEndCaseDataIn);
    String channelIn=extractWidgetConfig("String_Node_Str");
    this.setChannel(channelIn);
    if (this.getChannelPath().equalsIgnoreCase(this.getChannel())) {
      this.getCaseManager().setKieServerConfiguration(this.getKnowledgeSourceId());
      this.getCaseManager().postCaseComments(this.getContainerid(),this.getCasePath(),this.getCommentInput());
      this.setComments(this.getCaseManager().getCaseComments(this.getContainerid(),this.getCasePath()).toString());
    }
  }
 catch (  ApsSystemException t) {
    logger.error("String_Node_Str",t);
    return FAILURE;
  }
  return SUCCESS;
}
Program: 42465
Project: 42465
Buggy source:
public String view(){
  try {
    String frontEndCaseDataIn=extractWidgetConfig("String_Node_Str");
    this.setFrontEndCaseData(frontEndCaseDataIn);
    if ((!StringUtils.isBlank(this.getKnowledgeSourceId()) || !StringUtils.isBlank(this.getContainerid()) || !StringUtils.isBlank(this.getCasePath())|| !StringUtils.isBlank(this.getChannelPath())) && (this.getChannelPath().equalsIgnoreCase(this.getFrontEndCaseData()))) {
      this.getCaseManager().setKieServerConfiguration(this.getKnowledgeSourceId());
      this.setCaseInstanceDetails(this.getCaseManager().getCaseInstancesDetails(this.getContainerid(),this.getCasePath()).toString());
    }
 else {
      this.setKnowledgeSourceId(this.getCaseManager().loadFirstConfigurations().getId());
      this.setContainerid(this.getCaseManager().getContainersList().get(0).getContainerId());
      this.setCasePath(this.getCaseManager().getCaseInstancesList(this.getContainerid()).get(0));
      this.setCaseInstanceDetails(this.getCaseManager().getCaseInstancesDetails(this.getContainerid(),this.getCasePath()).toString());
    }
  }
 catch (  ApsSystemException t) {
    logger.error("String_Node_Str",t);
    return FAILURE;
  }
  return SUCCESS;
}

Fixed version (ground truth):
public String view(){
  try {
    String frontEndCaseDataIn=extractWidgetConfig("String_Node_Str");
    this.setFrontEndCaseData(frontEndCaseDataIn);
    String channelIn=extractWidgetConfig("String_Node_Str");
    this.setChannel(channelIn);
    if ((!StringUtils.isBlank(this.getKnowledgeSourceId()) || !StringUtils.isBlank(this.getContainerid()) || !StringUtils.isBlank(this.getCasePath())|| !StringUtils.isBlank(this.getChannelPath())) && (this.getChannelPath().equalsIgnoreCase(this.getChannel()))) {
      this.getCaseManager().setKieServerConfiguration(this.getKnowledgeSourceId());
      this.setCaseInstanceDetails(this.getCaseManager().getCaseInstancesDetails(this.getContainerid(),this.getCasePath()).toString());
    }
 else {
      this.setKnowledgeSourceId(this.getCaseManager().loadFirstConfigurations().getId());
      this.setContainerid(this.getCaseManager().getContainersList().get(0).getContainerId());
      this.setCasePath(this.getCaseManager().getCaseInstancesList(this.getContainerid()).get(0));
      this.setCaseInstanceDetails(this.getCaseManager().getCaseInstancesDetails(this.getContainerid(),this.getCasePath()).toString());
      this.setChannelPath(this.getChannel());
    }
  }
 catch (  ApsSystemException t) {
    logger.error("String_Node_Str",t);
    return FAILURE;
  }
  return SUCCESS;
}
Program: 42466
Project: 42466
Buggy source:
public String updateData(){
  try {
    String frontEndCaseDataIn=extractWidgetConfig("String_Node_Str");
    this.setFrontEndCaseData(frontEndCaseDataIn);
    String channelIn=extractWidgetConfig("String_Node_Str");
    this.setChannel(channelIn);
    System.out.println("String_Node_Str" + this.getChannel());
    if (this.getChannelPath().equalsIgnoreCase(this.getChannel())) {
      this.getCaseManager().setKieServerConfiguration(this.getKnowledgeSourceId());
      System.out.println("String_Node_Str" + this.getChannelPath() + "String_Node_Str"+ this.getContainerid()+ "String_Node_Str"+ this.getCasePath()+ "String_Node_Str"+ this.getData());
      this.getCaseManager().postCaseFile(this.getContainerid(),this.getCasePath(),this.getData());
      this.setCasefile(this.getCaseManager().getCaseFile(this.getContainerid(),this.getCasePath()).toString());
    }
  }
 catch (  ApsSystemException t) {
    logger.error("String_Node_Str",t);
    return FAILURE;
  }
  return SUCCESS;
}

Fixed version (ground truth):
public String updateData(){
  try {
    String frontEndCaseDataIn=extractWidgetConfig("String_Node_Str");
    this.setFrontEndCaseData(frontEndCaseDataIn);
    String channelIn=extractWidgetConfig("String_Node_Str");
    this.setChannel(channelIn);
    if (this.getChannelPath().equalsIgnoreCase(this.getChannel())) {
      this.getCaseManager().setKieServerConfiguration(this.getKnowledgeSourceId());
      this.getCaseManager().postCaseFile(this.getContainerid(),this.getCasePath(),this.getData());
      this.setCasefile(this.getCaseManager().getCaseFile(this.getContainerid(),this.getCasePath()).toString());
    }
  }
 catch (  ApsSystemException t) {
    logger.error("String_Node_Str",t);
    return FAILURE;
  }
  return SUCCESS;
}
Program: 42467
Project: 42467
Buggy source:
public String view(){
  try {
    String frontEndCaseDataIn=extractWidgetConfig("String_Node_Str");
    this.setFrontEndCaseData(frontEndCaseDataIn);
    String channelIn=extractWidgetConfig("String_Node_Str");
    this.setChannel(channelIn);
    System.out.println("String_Node_Str" + this.getChannel());
    if ((!StringUtils.isBlank(this.getKnowledgeSourceId()) || !StringUtils.isBlank(this.getContainerid()) || !StringUtils.isBlank(this.getCasePath())|| !StringUtils.isBlank(this.getChannelPath())) && (this.getChannelPath().equalsIgnoreCase(this.getChannel()))) {
      this.getCaseManager().setKieServerConfiguration(this.getKnowledgeSourceId());
      this.setCasefile(this.getCaseManager().getCaseFile(this.getContainerid(),this.getCasePath()).toString());
    }
 else {
      this.setKnowledgeSourceId(this.getCaseManager().loadFirstConfigurations().getId());
      this.setContainerid(this.getCaseManager().getContainersList().get(0).getContainerId());
      this.setCasePath(this.getCaseManager().getCaseInstancesList(this.getContainerid()).get(0));
      this.setChannelPath(this.getChannel());
      this.setCasefile(this.getCaseManager().getCaseFile(this.getContainerid(),this.getCasePath()).toString());
    }
  }
 catch (  ApsSystemException t) {
    logger.error("String_Node_Str",t);
    return FAILURE;
  }
  return SUCCESS;
}

Fixed version (ground truth):
public String view(){
  try {
    String frontEndCaseDataIn=extractWidgetConfig("String_Node_Str");
    this.setFrontEndCaseData(frontEndCaseDataIn);
    String channelIn=extractWidgetConfig("String_Node_Str");
    this.setChannel(channelIn);
    if ((!StringUtils.isBlank(this.getKnowledgeSourceId()) || !StringUtils.isBlank(this.getContainerid()) || !StringUtils.isBlank(this.getCasePath())|| !StringUtils.isBlank(this.getChannelPath())) && (this.getChannelPath().equalsIgnoreCase(this.getChannel()))) {
      this.getCaseManager().setKieServerConfiguration(this.getKnowledgeSourceId());
      this.setCasefile(this.getCaseManager().getCaseFile(this.getContainerid(),this.getCasePath()).toString());
    }
 else {
      this.setKnowledgeSourceId(this.getCaseManager().loadFirstConfigurations().getId());
      this.setContainerid(this.getCaseManager().getContainersList().get(0).getContainerId());
      this.setCasePath(this.getCaseManager().getCaseInstancesList(this.getContainerid()).get(0));
      this.setChannelPath(this.getChannel());
      this.setCasefile(this.getCaseManager().getCaseFile(this.getContainerid(),this.getCasePath()).toString());
    }
  }
 catch (  ApsSystemException t) {
    logger.error("String_Node_Str",t);
    return FAILURE;
  }
  return SUCCESS;
}
Program: 42468
Project: 42468
Buggy source:
public String deleteData(){
  try {
    String frontEndCaseDataIn=extractWidgetConfig("String_Node_Str");
    this.setFrontEndCaseData(frontEndCaseDataIn);
    String channelIn=extractWidgetConfig("String_Node_Str");
    this.setChannel(channelIn);
    if (this.getChannelPath().equalsIgnoreCase(this.getChannel())) {
      this.getCaseManager().setKieServerConfiguration(this.getKnowledgeSourceId());
      System.out.println("String_Node_Str" + this.getChannelPath() + "String_Node_Str"+ this.getContainerid()+ "String_Node_Str"+ this.getCasePath()+ "String_Node_Str"+ this.getDataId());
      this.getCaseManager().deleteCaseFile(this.getContainerid(),this.getCasePath(),this.getDataId());
      this.setCasefile(this.getCaseManager().getCaseFile(this.getContainerid(),this.getCasePath()).toString());
    }
  }
 catch (  ApsSystemException t) {
    logger.error("String_Node_Str",t);
    return FAILURE;
  }
  return SUCCESS;
}

Fixed version (ground truth):
public String deleteData(){
  try {
    String frontEndCaseDataIn=extractWidgetConfig("String_Node_Str");
    this.setFrontEndCaseData(frontEndCaseDataIn);
    String channelIn=extractWidgetConfig("String_Node_Str");
    this.setChannel(channelIn);
    if (this.getChannelPath().equalsIgnoreCase(this.getChannel())) {
      this.getCaseManager().setKieServerConfiguration(this.getKnowledgeSourceId());
      this.getCaseManager().deleteCaseFile(this.getContainerid(),this.getCasePath(),this.getDataId());
      this.setCasefile(this.getCaseManager().getCaseFile(this.getContainerid(),this.getCasePath()).toString());
    }
  }
 catch (  ApsSystemException t) {
    logger.error("String_Node_Str",t);
    return FAILURE;
  }
  return SUCCESS;
}
Program: 42469
Project: 42469
Buggy source:
public String deleteRole(){
  try {
    String frontEndCaseDataIn=extractWidgetConfig("String_Node_Str");
    this.setFrontEndCaseData(frontEndCaseDataIn);
    if (this.getChannelPath().equalsIgnoreCase(this.getFrontEndCaseData())) {
      this.getCaseManager().setKieServerConfiguration(this.getKnowledgeSourceId());
      System.out.println("String_Node_Str" + this.getChannelPath() + "String_Node_Str"+ this.getContainerid()+ "String_Node_Str"+ this.getCasePath()+ "String_Node_Str"+ this.getCaseRoleName()+ "String_Node_Str"+ this.getUser()+ "String_Node_Str"+ this.getGroup());
      this.getCaseManager().deleteCaseRoles(this.getContainerid(),this.getCasePath(),this.getCaseRoleName(),this.getUser(),this.getGroup());
      this.setRoles(this.getCaseManager().getCaseRoles(this.getContainerid(),this.getCasePath()).toString());
    }
  }
 catch (  ApsSystemException t) {
    logger.error("String_Node_Str",t);
    return FAILURE;
  }
  return SUCCESS;
}

Fixed version (ground truth):
public String deleteRole(){
  try {
    String frontEndCaseDataIn=extractWidgetConfig("String_Node_Str");
    this.setFrontEndCaseData(frontEndCaseDataIn);
    String channelIn=extractWidgetConfig("String_Node_Str");
    this.setChannel(channelIn);
    if (this.getChannelPath().equalsIgnoreCase(this.getChannel())) {
      this.getCaseManager().setKieServerConfiguration(this.getKnowledgeSourceId());
      this.getCaseManager().deleteCaseRoles(this.getContainerid(),this.getCasePath(),this.getCaseRoleName(),this.getUser(),this.getGroup());
      this.setRoles(this.getCaseManager().getCaseRoles(this.getContainerid(),this.getCasePath()).toString());
    }
  }
 catch (  ApsSystemException t) {
    logger.error("String_Node_Str",t);
    return FAILURE;
  }
  return SUCCESS;
}
Program: 42470
Project: 42470
Buggy source:
public String view(){
  try {
    String frontEndCaseDataIn=extractWidgetConfig("String_Node_Str");
    this.setFrontEndCaseData(frontEndCaseDataIn);
    if ((!StringUtils.isBlank(this.getKnowledgeSourceId()) || !StringUtils.isBlank(this.getContainerid()) || !StringUtils.isBlank(this.getCasePath())|| !StringUtils.isBlank(this.getChannelPath())) && (this.getChannelPath().equalsIgnoreCase(this.getFrontEndCaseData()))) {
      this.getCaseManager().setKieServerConfiguration(this.getKnowledgeSourceId());
      this.setRoles(this.getCaseManager().getCaseRoles(this.getContainerid(),this.getCasePath()).toString());
    }
 else {
      this.setKnowledgeSourceId(this.getCaseManager().loadFirstConfigurations().getId());
      this.setContainerid(this.getCaseManager().getContainersList().get(0).getContainerId());
      this.setCasePath(this.getCaseManager().getCaseInstancesList(this.getContainerid()).get(0));
      this.setRoles(this.getCaseManager().getCaseRoles(this.getContainerid(),this.getCasePath()).toString());
      this.setChannelPath(this.getFrontEndCaseData());
    }
  }
 catch (  ApsSystemException t) {
    logger.error("String_Node_Str",t);
    return FAILURE;
  }
  return SUCCESS;
}

Fixed version (ground truth):
public String view(){
  try {
    String frontEndCaseDataIn=extractWidgetConfig("String_Node_Str");
    this.setFrontEndCaseData(frontEndCaseDataIn);
    String channelIn=extractWidgetConfig("String_Node_Str");
    this.setChannel(channelIn);
    if ((!StringUtils.isBlank(this.getKnowledgeSourceId()) || !StringUtils.isBlank(this.getContainerid()) || !StringUtils.isBlank(this.getCasePath())|| !StringUtils.isBlank(this.getChannelPath())) && (this.getChannelPath().equalsIgnoreCase(this.getChannel()))) {
      this.getCaseManager().setKieServerConfiguration(this.getKnowledgeSourceId());
      this.setRoles(this.getCaseManager().getCaseRoles(this.getContainerid(),this.getCasePath()).toString());
    }
 else {
      this.setKnowledgeSourceId(this.getCaseManager().loadFirstConfigurations().getId());
      this.setContainerid(this.getCaseManager().getContainersList().get(0).getContainerId());
      this.setCasePath(this.getCaseManager().getCaseInstancesList(this.getContainerid()).get(0));
      this.setRoles(this.getCaseManager().getCaseRoles(this.getContainerid(),this.getCasePath()).toString());
      this.setChannelPath(this.getChannel());
    }
  }
 catch (  ApsSystemException t) {
    logger.error("String_Node_Str",t);
    return FAILURE;
  }
  return SUCCESS;
}
Program: 42471
Project: 42471
Buggy source:
public String addRole(){
  try {
    String frontEndCaseDataIn=extractWidgetConfig("String_Node_Str");
    this.setFrontEndCaseData(frontEndCaseDataIn);
    if (this.getChannelPath().equalsIgnoreCase(this.getFrontEndCaseData())) {
      this.getCaseManager().setKieServerConfiguration(this.getKnowledgeSourceId());
      System.out.println("String_Node_Str" + this.getChannelPath() + "String_Node_Str"+ this.getContainerid()+ "String_Node_Str"+ this.getCasePath()+ "String_Node_Str"+ this.getCaseRoleName()+ "String_Node_Str"+ this.getUser()+ "String_Node_Str"+ this.getGroup());
      this.getCaseManager().addCaseRoles(this.getContainerid(),this.getCasePath(),this.getCaseRoleName(),this.getUser(),this.getGroup());
      this.setRoles(this.getCaseManager().getCaseRoles(this.getContainerid(),this.getCasePath()).toString());
    }
  }
 catch (  ApsSystemException t) {
    logger.error("String_Node_Str",t);
    return FAILURE;
  }
  return SUCCESS;
}

Fixed version (ground truth):
public String addRole(){
  try {
    String frontEndCaseDataIn=extractWidgetConfig("String_Node_Str");
    this.setFrontEndCaseData(frontEndCaseDataIn);
    String channelIn=extractWidgetConfig("String_Node_Str");
    this.setChannel(channelIn);
    if (this.getChannelPath().equalsIgnoreCase(this.getChannel())) {
      this.getCaseManager().setKieServerConfiguration(this.getKnowledgeSourceId());
      this.getCaseManager().addCaseRoles(this.getContainerid(),this.getCasePath(),this.getCaseRoleName(),this.getUser(),this.getGroup());
      this.setRoles(this.getCaseManager().getCaseRoles(this.getContainerid(),this.getCasePath()).toString());
    }
  }
 catch (  ApsSystemException t) {
    logger.error("String_Node_Str",t);
    return FAILURE;
  }
  return SUCCESS;
}
Program: 42472
Project: 42472
Buggy source:
public String selectCaseInstance(){
  try {
    String frontEndCaseDataIn=extractWidgetConfig("String_Node_Str");
    JSONObject frontEndCaseDataInjs=new JSONObject(frontEndCaseDataIn);
    this.setKnowledgeSourceId(frontEndCaseDataInjs.getString("String_Node_Str"));
    this.setContainerid(frontEndCaseDataInjs.getString("String_Node_Str"));
    this.setChannelPath(frontEndCaseDataInjs.getString("String_Node_Str"));
    this.getCaseManager().setKieServerConfiguration(this.getKnowledgeSourceId());
    this.setCases(this.getCaseManager().getCaseInstancesList(this.getContainerid()));
  }
 catch (  ApsSystemException t) {
    logger.error("String_Node_Str",t);
    return FAILURE;
  }
  return SUCCESS;
}

Fixed version (ground truth):
public String selectCaseInstance(){
  try {
    String frontEndCaseDataIn=extractWidgetConfig("String_Node_Str");
    JSONObject frontEndCaseDataInjs=new JSONObject(frontEndCaseDataIn);
    String channelIn=extractWidgetConfig("String_Node_Str");
    this.setChannel(channelIn);
    this.setKnowledgeSourceId(frontEndCaseDataInjs.getString("String_Node_Str"));
    this.setContainerid(frontEndCaseDataInjs.getString("String_Node_Str"));
    this.setChannelPath(this.getChannel());
    this.getCaseManager().setKieServerConfiguration(this.getKnowledgeSourceId());
    this.setCases(this.getCaseManager().getCaseInstancesList(this.getContainerid()));
  }
 catch (  ApsSystemException t) {
    logger.error("String_Node_Str",t);
    return FAILURE;
  }
  return SUCCESS;
}
Program: 42473
Project: 42473
Buggy source:
public String view(){
  try {
    String frontEndCaseDataIn=extractWidgetConfig("String_Node_Str");
    JSONObject frontEndCaseDataInjs=new JSONObject(frontEndCaseDataIn);
    this.setKnowledgeSourceId(frontEndCaseDataInjs.getString("String_Node_Str"));
    this.setContainerid(frontEndCaseDataInjs.getString("String_Node_Str"));
    this.setChannelPath(frontEndCaseDataInjs.getString("String_Node_Str"));
    this.getCaseManager().setKieServerConfiguration(this.getKnowledgeSourceId());
    this.setCases(this.getCaseManager().getCaseInstancesList(this.getContainerid()));
  }
 catch (  ApsSystemException t) {
    logger.error("String_Node_Str",t);
    return FAILURE;
  }
  return SUCCESS;
}

Fixed version (ground truth):
public String view(){
  try {
    String frontEndCaseDataIn=extractWidgetConfig("String_Node_Str");
    JSONObject frontEndCaseDataInjs=new JSONObject(frontEndCaseDataIn);
    String channelIn=extractWidgetConfig("String_Node_Str");
    this.setChannel(channelIn);
    this.setKnowledgeSourceId(frontEndCaseDataInjs.getString("String_Node_Str"));
    this.setContainerid(frontEndCaseDataInjs.getString("String_Node_Str"));
    this.setChannelPath(this.getChannel());
    this.getCaseManager().setKieServerConfiguration(this.getKnowledgeSourceId());
    this.setCases(this.getCaseManager().getCaseInstancesList(this.getContainerid()));
  }
 catch (  ApsSystemException t) {
    logger.error("String_Node_Str",t);
    return FAILURE;
  }
  return SUCCESS;
}
Program: 42474
Project: 42474
Buggy source:
public String selectCaseInstance(){
  try {
    String containerid=getContainerIDfromfrontEndMilestonesData(this.getFrontEndMilestonesData());
    this.setCases(this.getCaseManager().getCaseInstancesList(containerid));
    String updatedMilestones=this.getCaseManager().getMilestonesList(containerid,this.getCasePath()).toString();
    this.setCaseInstanceMilestones(updatefrontEndMilestonesDataMilestones(this.getFrontEndMilestonesData(),updatedMilestones));
  }
 catch (  ApsSystemException t) {
    logger.error("String_Node_Str",t);
    return FAILURE;
  }
  return SUCCESS;
}

Fixed version (ground truth):
public String selectCaseInstance(){
  try {
    String containerid=getContainerIDfromfrontEndMilestonesData(this.getFrontEndMilestonesData());
    this.getCaseManager().setKieServerConfiguration(getKieIDfromfrontEndMilestonesData(this.getFrontEndMilestonesData()));
    this.setCases(this.getCaseManager().getCaseInstancesList(containerid));
    String updatedMilestones=this.getCaseManager().getMilestonesList(containerid,this.getCasePath()).toString();
    this.setCaseInstanceMilestones(updatefrontEndMilestonesDataMilestones(this.getFrontEndMilestonesData(),updatedMilestones));
  }
 catch (  ApsSystemException t) {
    logger.error("String_Node_Str",t);
    return FAILURE;
  }
  return SUCCESS;
}
Program: 42475
Project: 42475
Buggy source:
public String view(){
  try {
    String frontEndMilestonesDataIn=extractWidgetConfig("String_Node_Str");
    this.setFrontEndMilestonesData(frontEndMilestonesDataIn);
    this.getCaseManager().setKieServerConfiguration(getKieIDfromfrontEndMilestonesData(frontEndMilestonesDataIn));
    this.setCases(this.getCaseManager().getCaseInstancesList(getContainerIDfromfrontEndMilestonesData(frontEndMilestonesDataIn)));
  }
 catch (  ApsSystemException t) {
    logger.error("String_Node_Str",t);
    return FAILURE;
  }
  return SUCCESS;
}

Fixed version (ground truth):
public String view(){
  try {
    String frontEndMilestonesDataIn=extractWidgetConfig("String_Node_Str");
    String containerid=getContainerIDfromfrontEndMilestonesData(frontEndMilestonesDataIn);
    this.setFrontEndMilestonesData(frontEndMilestonesDataIn);
    this.getCaseManager().setKieServerConfiguration(getKieIDfromfrontEndMilestonesData(frontEndMilestonesDataIn));
    this.setCases(this.getCaseManager().getCaseInstancesList(containerid));
    if (!StringUtils.isBlank(this.getCasePath())) {
      String updatedMilestones=this.getCaseManager().getMilestonesList(containerid,this.getCasePath()).toString();
      this.setCaseInstanceMilestones(updatefrontEndMilestonesDataMilestones(frontEndMilestonesDataIn,updatedMilestones));
    }
  }
 catch (  ApsSystemException t) {
    logger.error("String_Node_Str",t);
    return FAILURE;
  }
  return SUCCESS;
}
Program: 42476
Project: 42476
Buggy source:
public JSONArray getMilestonesList(String containerId,String caseID) throws ApsSystemException {
  this.setKieBpmConfig(super.getConfig());
  JSONArray milestonesList=null;
  Map<String,String> headersMap=new HashMap<>();
  Map<String,String> param=new HashMap<>();
  String result;
  JSONObject json;
  if (!this.getKieBpmConfig().getActive() || StringUtils.isBlank(containerId) || StringUtils.isBlank(caseID)) {
    return milestonesList;
  }
  try {
    Endpoint ep=KieEndpointDictionary.create().get(API_GET_MILESTONES_LIST).resolveParams(containerId,caseID);
    headersMap.put(HEADER_KEY_ACCEPT,HEADER_VALUE_JSON);
    param.put(HEADER_MILESTONES_ACHIEVEDONLY_PARM,HEADER_MILESTONES_ACHIEVEDONLY_FALSE);
    KieClient client=super.getCurrentClient();
    result=(String)new KieRequestBuilder(client).setEndpoint(ep).setHeaders(headersMap).setRequestParams(param).setDebug(this.getKieBpmConfig().getDebug()).doRequest();
    if (!result.isEmpty()) {
      json=new JSONObject(result);
      milestonesList=(JSONArray)json.get("String_Node_Str");
      logger.debug("String_Node_Str",result);
    }
 else {
      logger.debug("String_Node_Str");
    }
  }
 catch (  Throwable t) {
    throw new ApsSystemException("String_Node_Str",t);
  }
  return milestonesList;
}

Fixed version (ground truth):
public JSONArray getMilestonesList(String containerId,String caseID) throws ApsSystemException {
  super.setConfig(super.getConfig());
  JSONArray milestonesList=null;
  Map<String,String> headersMap=new HashMap<>();
  Map<String,String> param=new HashMap<>();
  String result;
  JSONObject json;
  if (!super.getConfig().getActive() || StringUtils.isBlank(containerId) || StringUtils.isBlank(caseID)) {
    return milestonesList;
  }
  try {
    Endpoint ep=KieEndpointDictionary.create().get(API_GET_MILESTONES_LIST).resolveParams(containerId,caseID);
    headersMap.put(HEADER_KEY_ACCEPT,HEADER_VALUE_JSON);
    param.put(HEADER_MILESTONES_ACHIEVEDONLY_PARM,HEADER_MILESTONES_ACHIEVEDONLY_FALSE);
    KieClient client=super.getCurrentClient();
    result=(String)new KieRequestBuilder(client).setEndpoint(ep).setHeaders(headersMap).setRequestParams(param).setDebug(super.getConfig().getDebug()).doRequest();
    if (!result.isEmpty()) {
      json=new JSONObject(result);
      milestonesList=(JSONArray)json.get("String_Node_Str");
      logger.debug("String_Node_Str",result);
    }
 else {
      logger.debug("String_Node_Str");
    }
  }
 catch (  Throwable t) {
    throw new ApsSystemException("String_Node_Str",t);
  }
  return milestonesList;
}