@Override public void close() { if (!closed) { super.close(); if (null != executorService) { executorService.shutdownNow(); } for (CarbonIterator inputIterator : inputIterators) { inputIterator.close(); } } }
@Override public void close() { if (!closed) { super.close(); for (CarbonIterator inputIterator : inputIterators) { inputIterator.close(); } } }
@Override public void close() { if (!closed) { super.close(); for (CarbonIterator inputIterator : inputIterators) { inputIterator.close(); } } }
private boolean internalHasNext() { if (firstTime) { firstTime = false; currentIterator.initialize(); } boolean hasNext = currentIterator.hasNext(); // If iterator is finished then check for next iterator. if (!hasNext) { currentIterator.close(); // Check next iterator is available in the list. if (counter < inputIterators.size()) { // Get the next iterator from the list. currentIterator = inputIterators.get(counter++); // Initialize the new iterator currentIterator.initialize(); hasNext = internalHasNext(); } } return hasNext; }
private boolean internalHasNext() { if (firstTime) { firstTime = false; currentIterator.initialize(); } boolean hasNext = currentIterator.hasNext(); // If iterator is finished then check for next iterator. if (!hasNext) { currentIterator.close(); // Check next iterator is available in the list. if (counter < inputIterators.size()) { // Get the next iterator from the list. currentIterator = inputIterators.get(counter++); // Initialize the new iterator currentIterator.initialize(); hasNext = internalHasNext(); } } return hasNext; }
queryIterator.close(); } catch (Throwable e) { exceptionOccurred = e;
@Override public void close() throws IOException { logStatistics(rowCount, queryModel.getStatisticsRecorder()); // clear dictionary cache Map<String, Dictionary> columnToDictionaryMapping = queryModel.getColumnToDictionaryMapping(); if (null != columnToDictionaryMapping) { for (Map.Entry<String, Dictionary> entry : columnToDictionaryMapping.entrySet()) { CarbonUtil.clearDictionaryCache(entry.getValue()); } } if (!skipClearDataMapAtClose) { // Clear the datamap cache DataMapStoreManager.getInstance().clearDataMaps( queryModel.getTable().getAbsoluteTableIdentifier()); } // close read support readSupport.close(); carbonIterator.close(); try { queryExecutor.finish(); } catch (QueryExecutionException e) { throw new IOException(e); } }
blockletRowCount++; inputIterators.close();