Program: 13306
Project: 13306
Buggy source:
/** 
 * {@inheritDoc}
 */
@Override public Map<String,Object> query(ServerContext context,String fullId,Map<String,String> params) throws ResourceException {
  String queryId=params.get("String_Node_Str");
  boolean formatted=true;
  String[] split=AuditServiceImpl.splitFirstLevel(fullId);
  String type=split[0];
  try {
    if (params.get("String_Node_Str") != null && !AuditServiceImpl.getBoolValue(params.get("String_Node_Str"))) {
      formatted=false;
    }
    List<Map<String,Object>> reconEntryList=getEntryList(type);
    if (reconEntryList == null) {
      throw new NotFoundException(type + "String_Node_Str");
    }
    String reconId=params.get("String_Node_Str");
    if (AuditServiceImpl.QUERY_BY_RECON_ID.equals(queryId) && type.equals(AuditServiceImpl.TYPE_RECON)) {
      return AuditServiceImpl.getReconResults(reconEntryList,reconId,formatted);
    }
 else     if (AuditServiceImpl.QUERY_BY_MAPPING.equals(queryId) && type.equals(AuditServiceImpl.TYPE_RECON)) {
      return getReconQueryResults(reconEntryList,reconId,"String_Node_Str",params.get("String_Node_Str"),formatted);
    }
 else     if (AuditServiceImpl.QUERY_BY_RECON_ID_AND_SITUATION.equals(queryId) && type.equals(AuditServiceImpl.TYPE_RECON)) {
      return getReconQueryResults(reconEntryList,reconId,"String_Node_Str",params.get("String_Node_Str"),formatted);
    }
 else     if (AuditServiceImpl.QUERY_BY_RECON_ID_AND_TYPE.equals(queryId) && type.equals(AuditServiceImpl.TYPE_RECON)) {
      return getReconQueryResults(reconEntryList,reconId,"String_Node_Str",params.get("String_Node_Str"),formatted);
    }
 else     if (AuditServiceImpl.QUERY_BY_ACTIVITY_PARENT_ACTION.equals(queryId) && type.equals(AuditServiceImpl.TYPE_ACTIVITY)) {
      String actionId=params.get("String_Node_Str");
      List<Map<String,Object>> rawEntryList=new ArrayList<Map<String,Object>>();
      for (      Map<String,Object> entry : reconEntryList) {
        if (entry.get("String_Node_Str").equals(actionId)) {
          rawEntryList.add(entry);
        }
      }
      return AuditServiceImpl.getActivityResults(rawEntryList,formatted);
    }
 else {
      throw new BadRequestException("String_Node_Str" + queryId + "String_Node_Str"+ type);
    }
  }
 catch (  Exception e) {
    e.printStackTrace();
    throw new BadRequestException(e);
  }
}

Fixed version (ground truth):
/** 
 * {@inheritDoc}
 */
@Override public Map<String,Object> query(ServerContext context,String fullId,Map<String,String> params) throws ResourceException {
  String queryId=params.get("String_Node_Str");
  boolean formatted=true;
  String[] split=AuditServiceImpl.splitFirstLevel(fullId);
  String type=split[0];
  try {
    if (params.get("String_Node_Str") != null && !AuditServiceImpl.getBoolValue(params.get("String_Node_Str"))) {
      formatted=false;
    }
    List<Map<String,Object>> reconEntryList=getEntryList(type);
    if (reconEntryList == null) {
      throw new NotFoundException(type + "String_Node_Str");
    }
    String reconId=params.get("String_Node_Str");
    if (AuditServiceImpl.QUERY_BY_RECON_ID.equals(queryId) && type.equals(AuditServiceImpl.TYPE_RECON)) {
      return AuditServiceImpl.getReconResults(reconEntryList,formatted);
    }
 else     if (AuditServiceImpl.QUERY_BY_MAPPING.equals(queryId) && type.equals(AuditServiceImpl.TYPE_RECON)) {
      return getReconQueryResults(reconEntryList,reconId,"String_Node_Str",params.get("String_Node_Str"),formatted);
    }
 else     if (AuditServiceImpl.QUERY_BY_RECON_ID_AND_SITUATION.equals(queryId) && type.equals(AuditServiceImpl.TYPE_RECON)) {
      return getReconQueryResults(reconEntryList,reconId,"String_Node_Str",params.get("String_Node_Str"),formatted);
    }
 else     if (AuditServiceImpl.QUERY_BY_RECON_ID_AND_TYPE.equals(queryId) && type.equals(AuditServiceImpl.TYPE_RECON)) {
      return getReconQueryResults(reconEntryList,reconId,"String_Node_Str",params.get("String_Node_Str"),formatted);
    }
 else     if (AuditServiceImpl.QUERY_BY_ACTIVITY_PARENT_ACTION.equals(queryId) && type.equals(AuditServiceImpl.TYPE_ACTIVITY)) {
      String actionId=params.get("String_Node_Str");
      List<Map<String,Object>> rawEntryList=new ArrayList<Map<String,Object>>();
      for (      Map<String,Object> entry : reconEntryList) {
        if (entry.get("String_Node_Str").equals(actionId)) {
          rawEntryList.add(entry);
        }
      }
      return AuditServiceImpl.getActivityResults(rawEntryList,formatted);
    }
 else {
      throw new BadRequestException("String_Node_Str" + queryId + "String_Node_Str"+ type);
    }
  }
 catch (  Exception e) {
    e.printStackTrace();
    throw new BadRequestException(e);
  }
}