use of org.apache.hyracks.comm.channels.DatasetNetworkInputChannel in project asterixdb by apache.
the class HyracksDatasetReader method nextPartition.
private boolean nextPartition() throws HyracksDataException {
++lastReadPartition;
try {
DatasetDirectoryRecord record = getRecord(lastReadPartition);
while (record.getEmpty() && (++lastReadPartition) < knownRecords.length) {
record = getRecord(lastReadPartition);
}
if (lastReadPartition == knownRecords.length) {
return false;
}
resultChannel = new DatasetNetworkInputChannel(netManager, getSocketAddress(record), jobId, resultSetId, lastReadPartition, NUM_READ_BUFFERS);
lastMonitor = getMonitor(lastReadPartition);
resultChannel.registerMonitor(lastMonitor);
resultChannel.open(datasetClientCtx);
return true;
} catch (Exception e) {
throw HyracksDataException.create(e);
}
}
Aggregations