Github user isper3at commented on a diff in the pull request:

    https://github.com/apache/incubator-rya/pull/198#discussion_r132231558
  
    --- Diff: 
extras/rya.pcj.fluo/pcj.fluo.app/src/main/java/org/apache/rya/indexing/pcj/fluo/app/JoinResultUpdater.java
 ---
    @@ -160,8 +183,55 @@ public void updateJoinResults(
         public static enum Side {
             LEFT, RIGHT;
         }
    +    
    +    
    +    /**
    +     * Fetches batch to be processed by scanning over the Span specified 
by the
    +     * {@link JoinBatchInformation}. The number of results is less than or 
equal
    +     * to the batch size specified by the JoinBatchInformation.
    +     * 
    +     * @param tx - Fluo transaction in which batch operation is performed
    +     * @param siblingSpan - span of sibling to retrieve elements to join 
with
    +     * @param bsSet- set that batch results are added to
    +     * @return Set - containing results of sibling scan.
    +     * @throws Exception 
    +     */
    +    private Optional<RowColumn> fillSiblingBatch(TransactionBase tx, Span 
siblingSpan, Column siblingColumn, Set<VisibilityBindingSet> bsSet, int 
batchSize) throws Exception {
    +
    +        RowScanner rs = 
tx.scanner().over(siblingSpan).fetch(siblingColumn).byRow().build();
    +        Iterator<ColumnScanner> colScannerIter = rs.iterator();
    +
    +        boolean batchLimitMet = false;
    +        Bytes row = siblingSpan.getStart().getRow();
    +        while (colScannerIter.hasNext() && !batchLimitMet) {
    +            ColumnScanner colScanner = colScannerIter.next();
    +            row = colScanner.getRow();
    +            Iterator<ColumnValue> iter = colScanner.iterator();
    +            while (iter.hasNext()) {
    --- End diff --
    
    should this also check batchLimitMet?
    the flag can't be set to true on the first pass, so you can just do the 
size check after adding the first bindingSet, then you don't need a break.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

Reply via email to