public class SortedReducer extends AbstractReducer
| Modifier and Type | Class and Description |
|---|---|
static interface |
Reducer.RowComparator
Rows comparator.
|
| Modifier and Type | Field and Description |
|---|---|
protected Comparator<org.gridgain.internal.h2.result.SearchRow> |
firstRowCmp |
protected Comparator<org.gridgain.internal.h2.result.SearchRow> |
lastRowCmp |
fetched, memTracker, srcNodes| Constructor and Description |
|---|
SortedReducer(GridKernalContext ctx,
Reducer.RowComparator rowComparator)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
protected void |
addPage0(ReduceResultPage page) |
protected static int |
binarySearchRow(List<org.gridgain.internal.h2.result.Row> rows,
org.gridgain.internal.h2.result.SearchRow searchRow,
Comparator<org.gridgain.internal.h2.result.SearchRow> cmp,
boolean checkLast) |
protected void |
checkBounds(org.gridgain.internal.h2.result.Row lastEvictedRow,
org.gridgain.internal.h2.result.SearchRow first,
org.gridgain.internal.h2.result.SearchRow last) |
boolean |
fetchedAll() |
protected org.gridgain.internal.h2.index.Cursor |
findAllFetched(List<org.gridgain.internal.h2.result.Row> fetched,
org.gridgain.internal.h2.result.SearchRow first,
org.gridgain.internal.h2.result.SearchRow last) |
protected org.gridgain.internal.h2.index.Cursor |
findInStream(@Nullable org.gridgain.internal.h2.result.SearchRow first,
@Nullable org.gridgain.internal.h2.result.SearchRow last) |
void |
setSources(Map<ClusterNode,BitSet> nodesToSegments)
Set source nodes.
|
addPage, createDummyLastPage, fail, find, hasSource, memoryTracker, memoryTracker, onBlockEvict, onFailure, pollNextIterator, setPageSize, sourcesprotected final Comparator<org.gridgain.internal.h2.result.SearchRow> firstRowCmp
protected final Comparator<org.gridgain.internal.h2.result.SearchRow> lastRowCmp
public SortedReducer(GridKernalContext ctx, Reducer.RowComparator rowComparator)
ctx - Kernal context.rowComparator - Row comparator.public void setSources(Map<ClusterNode,BitSet> nodesToSegments)
setSources in class AbstractReducernodesToSegments - Mapping of nodes to expected count of segments to scan.public boolean fetchedAll()
protected org.gridgain.internal.h2.index.Cursor findInStream(@Nullable
@Nullable org.gridgain.internal.h2.result.SearchRow first,
@Nullable
@Nullable org.gridgain.internal.h2.result.SearchRow last)
findInStream in class AbstractReducerfirst - Row.last - Row.protected org.gridgain.internal.h2.index.Cursor findAllFetched(List<org.gridgain.internal.h2.result.Row> fetched, org.gridgain.internal.h2.result.SearchRow first, org.gridgain.internal.h2.result.SearchRow last)
findAllFetched in class AbstractReducerfetched - Fetched data.first - Row.last - Row.protected void checkBounds(org.gridgain.internal.h2.result.Row lastEvictedRow,
org.gridgain.internal.h2.result.SearchRow first,
org.gridgain.internal.h2.result.SearchRow last)
checkBounds in class AbstractReducerlastEvictedRow - Last evicted fetched row.first - Lower bound.last - Upper bound.protected void addPage0(ReduceResultPage page)
addPage0 in class AbstractReducerpage - Page.protected static int binarySearchRow(List<org.gridgain.internal.h2.result.Row> rows, org.gridgain.internal.h2.result.SearchRow searchRow, Comparator<org.gridgain.internal.h2.result.SearchRow> cmp, boolean checkLast)
rows - Sorted rows list.searchRow - Search row.cmp - Comparator.checkLast - If we need to optimistically check the last row right away.
Follow @ApacheIgnite
Ignite Database and Caching Platform : ver. 8.9.23-p1 Release Date : November 19 2025