Interface Reducer

    • Nested Class Summary

      Nested Classes 
      Modifier and Type Interface Description
      static interface  Reducer.RowComparator
      Rows comparator.
    • Method Detail

      • hasSource

        boolean hasSource​(UUID nodeId)
        Check if node with given nodeId is data source node for the index.
        Parameters:
        nodeId - Node ID.
        Returns:
        true If this index needs data from the given source node, false otherwise.
      • setSources

        void setSources​(Map<ClusterNode,​BitSet> nodesToSegmentsCnt)
        Set source nodes.
        Parameters:
        nodesToSegmentsCnt - Mapping of nodes to expected count of segments to scan.
      • sources

        Set<UUID> sources()
        Returns:
        Return source nodes for this merge index.
      • addPage

        void addPage​(ReduceResultPage page)
        Offer result page for reduce.
        Parameters:
        page - Page.
      • setPageSize

        void setPageSize​(int pageSize)
        Parameters:
        pageSize - Page size.
      • fetchedAll

        boolean fetchedAll()
        Check if all rows has been fetched from all sources.
        Returns:
        true If all rows has been fetched, false otherwise.
      • find

        org.h2.index.Cursor find​(@Nullable
                                 @Nullable org.h2.result.SearchRow first,
                                 @Nullable
                                 @Nullable org.h2.result.SearchRow last)
        Find a rows and create a cursor to iterate over the result.
        Parameters:
        first - Lower bound.
        last - Upper bound.
        Returns:
        Cursor instance.
      • onFailure

        void onFailure​(UUID nodeId,
                       javax.cache.CacheException e)
        Fail cursor callback.
        Parameters:
        nodeId - Node ID.
        e - Exception.