You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@phoenix.apache.org by "virajjasani (via GitHub)" <gi...@apache.org> on 2023/10/25 04:06:13 UTC

[PR] PHOENIX-7004 Validate if the result returned by phoenix query is within scan start/end key range [phoenix]

virajjasani opened a new pull request, #1724:
URL: https://github.com/apache/phoenix/pull/1724

   (no comment)


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@phoenix.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] PHOENIX-7004 Validate if the result returned by phoenix query is within scan start/end key range [phoenix]

Posted by "shahrs87 (via GitHub)" <gi...@apache.org>.
shahrs87 commented on PR #1724:
URL: https://github.com/apache/phoenix/pull/1724#issuecomment-1781853506

   @virajjasani  Thinking what changed from this PR https://github.com/apache/phoenix/pull/1697 ? 


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@phoenix.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] Test PR [phoenix]

Posted by "virajjasani (via GitHub)" <gi...@apache.org>.
virajjasani closed pull request #1724: Test PR
URL: https://github.com/apache/phoenix/pull/1724


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@phoenix.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] PHOENIX-7004 Validate if the result returned by phoenix query is within scan start/end key range [phoenix]

Posted by "virajjasani (via GitHub)" <gi...@apache.org>.
virajjasani commented on PR #1724:
URL: https://github.com/apache/phoenix/pull/1724#issuecomment-1783362587

   > @virajjasani Thinking what changed from this PR #1697 ?
   
   this is the main diff:
   
   ```
       public static void verifyKeyInScanRange(ImmutableBytesWritable ptr,
                                               Scan scan,
                                               Tuple tuple)
               throws ResultSetOutOfScanRangeException {
           if ((tuple.size() == 1 && tuple.getValue(SINGLE_COLUMN_FAMILY, SINGLE_COLUMN) != null)
                   || (tuple.size() == 1 && tuple.getValue(OFFSET_FAMILY, OFFSET_COLUMN) != null)
                   || isDummy(tuple)) {
               return;
           }
           if (isLocalIndex(scan)) {
               verifyScanRanges(ptr, scan, scan.getAttribute(SCAN_START_ROW_SUFFIX),
                       scan.getAttribute(SCAN_STOP_ROW_SUFFIX));
           } else {
               try {
                   verifyScanRanges(ptr, scan, scan.getStartRow(), scan.getStopRow());
               } catch (ResultSetOutOfScanRangeException e) {
                   // required for Salt Buckets scan boundary changes
                   verifyScanRanges(ptr, scan, scan.getAttribute(SCAN_ACTUAL_START_ROW),
                           scan.getStopRow());
               }
           }
       }
   ```
   
   Basically, we need to take care of these cases:
   
   - Aggregate scan results
   - Offset based results
   - Dummy cell
   - Local index scan boundary changes
   - Salt table scan boundary changes
   
   But anyways, fixing group by aggregator cases is required at server side for data integrity issues. I just wanted to exercise on how many cases we need to handle here. I am sure local index and salt table scan boundary changes might also need some careful considerations at server side.
   
   FYI @Divneet18, you can incorporate the changes and write a test with coproc that can return incorrect result so that we can test scan boundaries negative results.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@phoenix.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] PHOENIX-7004 Validate if the result returned by phoenix query is within scan start/end key range [phoenix]

Posted by "kadirozde (via GitHub)" <gi...@apache.org>.
kadirozde commented on PR #1724:
URL: https://github.com/apache/phoenix/pull/1724#issuecomment-1781846788

   Can we add some negative testing? You can add a test coproc that returns a result outside the scan range.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@phoenix.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org