private void loadFile(String path) throws IOException {
        SimpleRow.Builder rowBuilder = SimpleRow.Builder.createByColumnSchemas(Arrays.asList(columnSchemas));
        try (BufferedReader reader = new BufferedReader(new InputStreamReader(new FileInputStream(path), "UTF-8"))) {
            String line;
            while (StringUtils.isNotEmpty(line = reader.readLine()) && !interrupted) {
                String[] vals = line.split(spliter);
                try {
                    for (int colId = 0; colId < schema.schema.columns.size(); colId++) {
                        int valIndex = valIndexes[colId];
                        rowBuilder.appendStringFormVal(getValue(vals, valIndex));
                    }
                } catch (NumberFormatException e) {
                    System.out.printf("error csv line: [%s]", line);
                    e.printStackTrace();
                }
                segmentGen.add(rowBuilder.buildAndReset());
                rowCount++;
            }
        }
    }
TODO handle the case when row number is larger then {@link StorageSegment#MAX_ROW_COUNT}.
indexr-server/src/main/java/io/indexr/tool/CSVSegmentLoader.java