Program: 33548
Project: 33548
Buggy source:
@Test public void insertFloatTest() throws ConnectorException {
  ClusterName clusterName=getClusterName();
  TableMetadataBuilder tableMetadataBuilder=new TableMetadataBuilder(CATALOG,TABLE);
  TableMetadata tableMetadata=tableMetadataBuilder.addColumn(FLOAT_COLUMN,ColumnType.FLOAT).addColumn(STRING_COLUMN,ColumnType.VARCHAR).build(false);
  sConnector.getMetadataEngine().createTable(getClusterName(),tableMetadata);
  LogicalWorkFlowCreator logicalWorkFlowCreator=new LogicalWorkFlowCreator(CATALOG,TABLE,clusterName);
  LinkedList<LogicalWorkFlowCreator.ConnectorField> selectColumns=new LinkedList<>();
  selectColumns.add(logicalWorkFlowCreator.createConnectorField(FLOAT_COLUMN,FLOAT_COLUMN,ColumnType.FLOAT));
  selectColumns.add(logicalWorkFlowCreator.createConnectorField(STRING_COLUMN,STRING_COLUMN,ColumnType.VARCHAR));
  LogicalWorkflow logicalWorkFlow=logicalWorkFlowCreator.addColumnName(FLOAT_COLUMN,STRING_COLUMN).addWindow(WindowType.NUM_ROWS,1).addSelect(selectColumns).getLogicalWorkflow();
  ResultHandlerTest resultSet=new ResultHandlerTest();
  StreamingRead reader=new StreamingRead(sConnector,logicalWorkFlow,resultSet);
  String queryId=String.valueOf(Math.abs(random.nextLong()));
  reader.setQueryId(queryId);
  reader.start();
  waitSeconds(15);
  StreamingInserter streamingInserter=new StreamingInserter(sConnector,clusterName,tableMetadata,new RowToInsertDefault());
  streamingInserter.numOfElement(10).elementPerSecond(5);
  streamingInserter.start();
  streamingInserter.addTypeToInsert(ColumnType.FLOAT).addTypeToInsert(ColumnType.VARCHAR);
  waitSeconds(10);
  streamingInserter.end();
  endReader(reader);
  ResultSet resSet=resultSet.getResultSet(queryId);
  List<ColumnMetadata> columnMetadata=resSet.getColumnMetadata();
  assertEquals(FLOAT_COLUMN,columnMetadata.get(0).getName().getName());
  List<Float> numsRecovered=new ArrayList<Float>(10);
  for (  Row recoveredRow : resSet.getRows()) {
    if (recoveredRow.getCell(STRING_COLUMN).getValue().equals("String_Node_Str")) {
      numsRecovered.add((Float)recoveredRow.getCell(FLOAT_COLUMN).getValue());
    }
  }
  assertEquals(10,numsRecovered.size());
  for (int i=0; i < 10; i++) {
    assertTrue(numsRecovered.contains(new Float(i + 0.5)));
  }
  assertTrue(columnMetadata.size() == 2);
  assertEquals(ColumnType.FLOAT,columnMetadata.get(0).getColumnType());
  assertTrue(resSet.getRows().get(0).getCell(FLOAT_COLUMN).getValue() instanceof Float);
}

Fixed version (ground truth):
@Test public void insertFloatTest() throws ConnectorException {
  ClusterName clusterName=getClusterName();
  TableMetadataBuilder tableMetadataBuilder=new TableMetadataBuilder(CATALOG,TABLE,clusterName.getName());
  TableMetadata tableMetadata=tableMetadataBuilder.addColumn(FLOAT_COLUMN,ColumnType.FLOAT).addColumn(STRING_COLUMN,ColumnType.VARCHAR).build(false);
  sConnector.getMetadataEngine().createTable(getClusterName(),tableMetadata);
  LogicalWorkFlowCreator logicalWorkFlowCreator=new LogicalWorkFlowCreator(CATALOG,TABLE,clusterName);
  LinkedList<LogicalWorkFlowCreator.ConnectorField> selectColumns=new LinkedList<>();
  selectColumns.add(logicalWorkFlowCreator.createConnectorField(FLOAT_COLUMN,FLOAT_COLUMN,ColumnType.FLOAT));
  selectColumns.add(logicalWorkFlowCreator.createConnectorField(STRING_COLUMN,STRING_COLUMN,ColumnType.VARCHAR));
  LogicalWorkflow logicalWorkFlow=logicalWorkFlowCreator.addColumnName(FLOAT_COLUMN,STRING_COLUMN).addWindow(WindowType.NUM_ROWS,1).addSelect(selectColumns).getLogicalWorkflow();
  ResultHandlerTest resultSet=new ResultHandlerTest();
  StreamingRead reader=new StreamingRead(sConnector,logicalWorkFlow,resultSet);
  String queryId=String.valueOf(Math.abs(random.nextLong()));
  reader.setQueryId(queryId);
  reader.start();
  waitSeconds(15);
  StreamingInserter streamingInserter=new StreamingInserter(sConnector,clusterName,tableMetadata,new RowToInsertDefault());
  streamingInserter.numOfElement(10).elementPerSecond(5);
  streamingInserter.start();
  streamingInserter.addTypeToInsert(ColumnType.FLOAT).addTypeToInsert(ColumnType.VARCHAR);
  waitSeconds(10);
  streamingInserter.end();
  endReader(reader);
  ResultSet resSet=resultSet.getResultSet(queryId);
  List<ColumnMetadata> columnMetadata=resSet.getColumnMetadata();
  assertEquals(FLOAT_COLUMN,columnMetadata.get(0).getName().getName());
  List<Float> numsRecovered=new ArrayList<Float>(10);
  for (  Row recoveredRow : resSet.getRows()) {
    if (recoveredRow.getCell(STRING_COLUMN).getValue().equals("String_Node_Str")) {
      numsRecovered.add((Float)recoveredRow.getCell(FLOAT_COLUMN).getValue());
    }
  }
  assertEquals(10,numsRecovered.size());
  for (int i=0; i < 10; i++) {
    assertTrue(numsRecovered.contains(new Float(i + 0.5)));
  }
  assertTrue(columnMetadata.size() == 2);
  assertEquals(ColumnType.FLOAT,columnMetadata.get(0).getColumnType());
  assertTrue(resSet.getRows().get(0).getCell(FLOAT_COLUMN).getValue() instanceof Float);
}