RecordIdentifier id = reader.createKey(); OrcStruct struct = reader.createValue(); while (reader.next(id, struct)) { assertEquals("id " + record, record, id.getRowId()); assertEquals("bucket " + record, 0, id.getBucketProperty()); id = reader.createKey(); struct = reader.createValue(); while (reader.next(id, struct)) { assertEquals("id " + record, record, id.getRowId()); assertEquals("bucket " + record, 0, id.getBucketProperty());
@Override public boolean next(NullWritable nullWritable, VectorizedRowBatch vectorizedRowBatch ) throws IOException { vectorizedRowBatch.reset(); buffer.reset(); if (!innerReader.next(key, value)) { return false; } if (partitionValues != null) { rbCtx.addPartitionColsToBatch(vectorizedRowBatch, partitionValues); } try { VectorizedBatchUtil.acidAddRowToBatch(value, (StructObjectInspector) objectInspector, vectorizedRowBatch.size++, vectorizedRowBatch, rbCtx, buffer); while (vectorizedRowBatch.size < vectorizedRowBatch.selected.length && innerReader.next(key, value)) { VectorizedBatchUtil.acidAddRowToBatch(value, (StructObjectInspector) objectInspector, vectorizedRowBatch.size++, vectorizedRowBatch, rbCtx, buffer); } } catch (Exception e) { throw new IOException("error iterating", e); } return true; }
while (reader.next(id, struct)) { record += 1;
@Override public boolean next(NullWritable nullWritable, VectorizedRowBatch vectorizedRowBatch ) throws IOException { vectorizedRowBatch.reset(); buffer.reset(); if (!innerReader.next(key, value)) { return false; } try { rowBatchCtx.addPartitionColsToBatch(vectorizedRowBatch); } catch (HiveException e) { throw new IOException("Problem adding partition column", e); } try { VectorizedBatchUtil.acidAddRowToBatch(value, (StructObjectInspector) objectInspector, vectorizedRowBatch.size++, vectorizedRowBatch, rowBatchCtx, buffer); while (vectorizedRowBatch.size < vectorizedRowBatch.selected.length && innerReader.next(key, value)) { VectorizedBatchUtil.acidAddRowToBatch(value, (StructObjectInspector) objectInspector, vectorizedRowBatch.size++, vectorizedRowBatch, rowBatchCtx, buffer); } } catch (HiveException he) { throw new IOException("error iterating", he); } return true; }
@Override public boolean next(NullWritable nullWritable, OrcStruct orcStruct) throws IOException { return inner.next(id, orcStruct); }
@Override public boolean next(NullWritable nullWritable, OrcStruct orcStruct) throws IOException { return inner.next(id, orcStruct); }
@Override public boolean next(NullWritable nullWritable, OrcStruct orcStruct) throws IOException { return inner.next(id, orcStruct); }