Re: [PR] Add list of collaborators to asf.yaml [pinot]

2024-06-10 Thread via GitHub


yashmayya commented on PR #13346:
URL: https://github.com/apache/pinot/pull/13346#issuecomment-2159769737

   Thanks Jackie! Mentioning the newly added collaborators here as an FYI - 
@sullis, @shenyu0127, @tibrewalpratik17, @abhioncbr, @zhtaoxiang, 
@shounakmk219, @itschrispeck, @soumitra-st, @swaminathanmanish, @yashmayya. 


-- 
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: commits-unsubscr...@pinot.apache.org

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


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



Re: [PR] Optimize snapshot flow to only snapshot segments which have updates [pinot]

2024-06-10 Thread via GitHub


klsince commented on code in PR #13285:
URL: https://github.com/apache/pinot/pull/13285#discussion_r1634137440


##
pinot-core/src/main/java/org/apache/pinot/core/data/manager/realtime/RealtimeSegmentDataManager.java:
##
@@ -703,9 +703,20 @@ public void run() {
 //   persisted.
 // Take upsert snapshot before starting consuming events
 if (_partitionUpsertMetadataManager != null) {
-  _partitionUpsertMetadataManager.takeSnapshot();
-  // If upsertTTL is enabled, we will remove expired primary keys from 
upsertMetadata after taking snapshot.
-  _partitionUpsertMetadataManager.removeExpiredPrimaryKeys();
+  if (_tableConfig.getUpsertMetadataTTL() > 0) {
+// If upsertMetadataTTL is enabled, we will remove expired primary 
keys from upsertMetadata
+// AFTER taking a snapshot. Taking the snapshot first is crucial 
to ensure we capture the final
+// state of a particular key before it exits the TTL window.

Review Comment:
   I see, that makes sense. Based on the metadata TTL related code, it seems 
like taking snapshot after removing metadata out of the TTL wouldn’t affect 
data/query correctness but incurred some extra overhead if server restarted 
before taking new snapshot as it had to add metadata (already out of TTL) back 
to Map, however those metadata would be removed again. 
   
   IIUC, maybe update the comment a bit that this is mainly to avoid such 
overhead upon unexpected server restart, but not affecting correctness. 
   



-- 
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: commits-unsubscr...@pinot.apache.org

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


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



Re: [PR] fix race condition in `ScalingThreadPoolExecutor` [pinot]

2024-06-10 Thread via GitHub


codecov-commenter commented on PR #13360:
URL: https://github.com/apache/pinot/pull/13360#issuecomment-2159718614

   ## 
[Codecov](https://app.codecov.io/gh/apache/pinot/pull/13360?dropdown=coverage=pr=h1_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 Report
   Attention: Patch coverage is `0%` with `10 lines` in your changes missing 
coverage. Please review.
   > Project coverage is 0.00%. Comparing base 
[(`59551e4`)](https://app.codecov.io/gh/apache/pinot/commit/59551e45224f1535c4863fd577622b37366ccc97?dropdown=coverage=desc_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 to head 
[(`98eb469`)](https://app.codecov.io/gh/apache/pinot/commit/98eb46996f85598df92283088456109e7af76f8e?dropdown=coverage=desc_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache).
   > Report is 599 commits behind head on master.
   
   | 
[Files](https://app.codecov.io/gh/apache/pinot/pull/13360?dropdown=coverage=pr=tree_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | Patch % | Lines |
   |---|---|---|
   | 
[.../pinot/common/utils/ScalingThreadPoolExecutor.java](https://app.codecov.io/gh/apache/pinot/pull/13360?src=pr=tree=pinot-common%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fpinot%2Fcommon%2Futils%2FScalingThreadPoolExecutor.java_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache#diff-cGlub3QtY29tbW9uL3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9waW5vdC9jb21tb24vdXRpbHMvU2NhbGluZ1RocmVhZFBvb2xFeGVjdXRvci5qYXZh)
 | 0.00% | [10 Missing :warning: 
](https://app.codecov.io/gh/apache/pinot/pull/13360?src=pr=tree_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 |
   
   Additional details and impacted files
   
   
   ```diff
   @@  Coverage Diff  @@
   ## master   #13360   +/-   ##
   =
   - Coverage 61.75%0.00%   -61.76% 
   =
 Files  2436 2472   +36 
 Lines133233   136271 +3038 
 Branches  2063621166  +530 
   =
   - Hits  822740-82274 
   - Misses44911   136271+91360 
   + Partials   60480 -6048 
   ```
   
   | 
[Flag](https://app.codecov.io/gh/apache/pinot/pull/13360/flags?src=pr=flags_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | Coverage Δ | |
   |---|---|---|
   | 
[custom-integration1](https://app.codecov.io/gh/apache/pinot/pull/13360/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `?` | |
   | 
[integration](https://app.codecov.io/gh/apache/pinot/pull/13360/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `0.00% <0.00%> (-0.01%)` | :arrow_down: |
   | 
[integration1](https://app.codecov.io/gh/apache/pinot/pull/13360/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `?` | |
   | 
[integration2](https://app.codecov.io/gh/apache/pinot/pull/13360/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `0.00% <0.00%> (ø)` | |
   | 
[java-11](https://app.codecov.io/gh/apache/pinot/pull/13360/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `?` | |
   | 
[java-21](https://app.codecov.io/gh/apache/pinot/pull/13360/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `0.00% <0.00%> (-61.63%)` | :arrow_down: |
   | 
[skip-bytebuffers-false](https://app.codecov.io/gh/apache/pinot/pull/13360/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `0.00% <0.00%> (-61.75%)` | :arrow_down: |
   | 
[skip-bytebuffers-true](https://app.codecov.io/gh/apache/pinot/pull/13360/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `?` | |
   | 
[temurin](https://app.codecov.io/gh/apache/pinot/pull/13360/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `0.00% <0.00%> (-61.76%)` | :arrow_down: |
   | 
[unittests](https://app.codecov.io/gh/apache/pinot/pull/13360/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `?` | |
   | 
[unittests1](https://app.codecov.io/gh/apache/pinot/pull/13360/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `?` | |
   | 
[unittests2](https://app.codecov.io/gh/apache/pinot/pull/13360/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `?` | |
   
   Flags with carried forward coverage won't be shown. [Click 

(pinot) branch master updated (ad5ca349ab -> d09cd0cec7)

2024-06-10 Thread xbli
This is an automated email from the ASF dual-hosted git repository.

xbli pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/pinot.git


from ad5ca349ab Add list of collaborators to asf.yaml (#13346)
 add d09cd0cec7 move shouldReplaceOnComparisonTie to base class to be more 
reusable (#13353)

No new revisions were added by this update.

Summary of changes:
 .../upsert/BasePartitionUpsertMetadataManager.java | 42 +
 ...oncurrentMapPartitionUpsertMetadataManager.java | 43 --
 2 files changed, 42 insertions(+), 43 deletions(-)


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



Re: [PR] move shouldReplaceOnComparisonTie to base class to be more reusable [pinot]

2024-06-10 Thread via GitHub


klsince merged PR #13353:
URL: https://github.com/apache/pinot/pull/13353


-- 
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: commits-unsubscr...@pinot.apache.org

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


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



Re: [PR] extend CompactedPinotSegmentRecordReader so that it can skip deleteRecord [pinot]

2024-06-10 Thread via GitHub


klsince commented on code in PR #13352:
URL: https://github.com/apache/pinot/pull/13352#discussion_r1634119955


##
pinot-segment-local/src/main/java/org/apache/pinot/segment/local/segment/readers/CompactedPinotSegmentRecordReader.java:
##
@@ -36,19 +37,25 @@
 public class CompactedPinotSegmentRecordReader implements RecordReader {
   private final PinotSegmentRecordReader _pinotSegmentRecordReader;
   private final RoaringBitmap _validDocIdsBitmap;
-
+  private final String _deleteRecordColumn;
+  // Reusable generic row to store the next row to return
+  private final GenericRow _nextRow = new GenericRow();
   // Valid doc ids iterator
   private PeekableIntIterator _validDocIdsIterator;
-  // Reusable generic row to store the next row to return
-  private GenericRow _nextRow = new GenericRow();
   // Flag to mark whether we need to fetch another row
   private boolean _nextRowReturned = true;
 
   public CompactedPinotSegmentRecordReader(File indexDir, RoaringBitmap 
validDocIds) {
+this(indexDir, validDocIds, null);
+  }
+
+  public CompactedPinotSegmentRecordReader(File indexDir, RoaringBitmap 
validDocIds,
+  @Nullable String deleteRecordColumn) {

Review Comment:
   As it’s not safe to skip deleteRecord, so I would rather avoid it for less 
confusion. 



-- 
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: commits-unsubscr...@pinot.apache.org

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


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



[PR] fix race condition in `ScalingThreadPoolExecutor` [pinot]

2024-06-10 Thread via GitHub


itschrispeck opened a new pull request, #13360:
URL: https://github.com/apache/pinot/pull/13360

   I introduced `ScalingThreadPoolExecutor` previously to provide an 
autoscaling thread pool, used to prevent interrupts from corrupting the 
realtime Lucene index. 
   
   There is a race condition as the logic relied on `_executor.getPoolSize()` 
and `_executor.getActiveCount()`. This PR changes the implementation slightly 
to track idle threads via overriding the [two methods that may be used by 
ThreadPoolExecutor.getTask()](https://github.com/openjdk/jdk21/blob/890adb6410dab4606a4f26a942aed02fb2f55387/src/java.base/share/classes/java/util/concurrent/ThreadPoolExecutor.java#L1069-L1070),
 which is always executed by an idle thread to pick up the next task. 
   
   In theory this could cause sporadic timeouts for searches against the 
realtime Lucene index, though it is hard to reproduce. I came across this bug 
trying to use `ScalingThreadPoolExecutor` for another feature.
   
   For testing, unit tests should cover this logic. The race condition is 
easily reproducible when the added unit test is used against the old 
implementation. 
   
   suggested tag: `bugfix`
   


-- 
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: commits-unsubscr...@pinot.apache.org

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


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



Re: [PR] Refactored compatibility-verifier module [pinot]

2024-06-10 Thread via GitHub


codecov-commenter commented on PR #13359:
URL: https://github.com/apache/pinot/pull/13359#issuecomment-2159664376

   ## 
[Codecov](https://app.codecov.io/gh/apache/pinot/pull/13359?dropdown=coverage=pr=h1_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 Report
   All modified and coverable lines are covered by tests :white_check_mark:
   > Project coverage is 0.00%. Comparing base 
[(`59551e4`)](https://app.codecov.io/gh/apache/pinot/commit/59551e45224f1535c4863fd577622b37366ccc97?dropdown=coverage=desc_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 to head 
[(`dc63323`)](https://app.codecov.io/gh/apache/pinot/commit/dc633238aecdad741e85be9053fd92676f62cf3e?dropdown=coverage=desc_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache).
   > Report is 598 commits behind head on master.
   
   
   Additional details and impacted files
   
   
   ```diff
   @@  Coverage Diff  @@
   ## master   #13359   +/-   ##
   =
   - Coverage 61.75%0.00%   -61.76% 
   =
 Files  2436 2472   +36 
 Lines133233   136266 +3033 
 Branches  2063621166  +530 
   =
   - Hits  822740-82274 
   - Misses44911   136266+91355 
   + Partials   60480 -6048 
   ```
   
   | 
[Flag](https://app.codecov.io/gh/apache/pinot/pull/13359/flags?src=pr=flags_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | Coverage Δ | |
   |---|---|---|
   | 
[custom-integration1](https://app.codecov.io/gh/apache/pinot/pull/13359/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `?` | |
   | 
[integration](https://app.codecov.io/gh/apache/pinot/pull/13359/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `0.00% <ø> (-0.01%)` | :arrow_down: |
   | 
[integration1](https://app.codecov.io/gh/apache/pinot/pull/13359/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `?` | |
   | 
[integration2](https://app.codecov.io/gh/apache/pinot/pull/13359/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `0.00% <ø> (ø)` | |
   | 
[java-11](https://app.codecov.io/gh/apache/pinot/pull/13359/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `?` | |
   | 
[java-21](https://app.codecov.io/gh/apache/pinot/pull/13359/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `0.00% <ø> (-61.63%)` | :arrow_down: |
   | 
[skip-bytebuffers-false](https://app.codecov.io/gh/apache/pinot/pull/13359/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `0.00% <ø> (-61.75%)` | :arrow_down: |
   | 
[skip-bytebuffers-true](https://app.codecov.io/gh/apache/pinot/pull/13359/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `?` | |
   | 
[temurin](https://app.codecov.io/gh/apache/pinot/pull/13359/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `0.00% <ø> (-61.76%)` | :arrow_down: |
   | 
[unittests](https://app.codecov.io/gh/apache/pinot/pull/13359/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `?` | |
   | 
[unittests1](https://app.codecov.io/gh/apache/pinot/pull/13359/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `?` | |
   | 
[unittests2](https://app.codecov.io/gh/apache/pinot/pull/13359/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `?` | |
   
   Flags with carried forward coverage won't be shown. [Click 
here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache#carryforward-flags-in-the-pull-request-comment)
 to find out more.
   
   
   
   
   [:umbrella: View full report in Codecov by 
Sentry](https://app.codecov.io/gh/apache/pinot/pull/13359?dropdown=coverage=pr=continue_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache).
   
   :loudspeaker: Have feedback on the report? [Share it 
here](https://about.codecov.io/codecov-pr-comment-feedback/?utm_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache).
   


-- 
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: commits-unsubscr...@pinot.apache.org

For 

[PR] Refactored compatibility-verifier module [pinot]

2024-06-10 Thread via GitHub


abhioncbr opened a new pull request, #13359:
URL: https://github.com/apache/pinot/pull/13359

   **Labels:**
   - `refactor`
   - `cleanup`
   
   **Description:**
   TODO
   


-- 
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: commits-unsubscr...@pinot.apache.org

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


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



Re: [PR] Fix NPE in ArrayAgg extractFinalResult functions [pinot]

2024-06-10 Thread via GitHub


codecov-commenter commented on PR #13358:
URL: https://github.com/apache/pinot/pull/13358#issuecomment-2159628408

   ## 
[Codecov](https://app.codecov.io/gh/apache/pinot/pull/13358?dropdown=coverage=pr=h1_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 Report
   Attention: Patch coverage is `0%` with `12 lines` in your changes missing 
coverage. Please review.
   > Project coverage is 0.00%. Comparing base 
[(`59551e4`)](https://app.codecov.io/gh/apache/pinot/commit/59551e45224f1535c4863fd577622b37366ccc97?dropdown=coverage=desc_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 to head 
[(`daebe27`)](https://app.codecov.io/gh/apache/pinot/commit/daebe27cac32a112035f5523e8a7c924bec36e0a?dropdown=coverage=desc_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache).
   > Report is 598 commits behind head on master.
   
   | 
[Files](https://app.codecov.io/gh/apache/pinot/pull/13358?dropdown=coverage=pr=tree_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | Patch % | Lines |
   |---|---|---|
   | 
[...ion/function/array/BaseArrayAggDoubleFunction.java](https://app.codecov.io/gh/apache/pinot/pull/13358?src=pr=tree=pinot-core%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fpinot%2Fcore%2Fquery%2Faggregation%2Ffunction%2Farray%2FBaseArrayAggDoubleFunction.java_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache#diff-cGlub3QtY29yZS9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvcGlub3QvY29yZS9xdWVyeS9hZ2dyZWdhdGlvbi9mdW5jdGlvbi9hcnJheS9CYXNlQXJyYXlBZ2dEb3VibGVGdW5jdGlvbi5qYXZh)
 | 0.00% | [2 Missing :warning: 
](https://app.codecov.io/gh/apache/pinot/pull/13358?src=pr=tree_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 |
   | 
[...tion/function/array/BaseArrayAggFloatFunction.java](https://app.codecov.io/gh/apache/pinot/pull/13358?src=pr=tree=pinot-core%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fpinot%2Fcore%2Fquery%2Faggregation%2Ffunction%2Farray%2FBaseArrayAggFloatFunction.java_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache#diff-cGlub3QtY29yZS9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvcGlub3QvY29yZS9xdWVyeS9hZ2dyZWdhdGlvbi9mdW5jdGlvbi9hcnJheS9CYXNlQXJyYXlBZ2dGbG9hdEZ1bmN0aW9uLmphdmE=)
 | 0.00% | [2 Missing :warning: 
](https://app.codecov.io/gh/apache/pinot/pull/13358?src=pr=tree_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 |
   | 
[...gation/function/array/BaseArrayAggIntFunction.java](https://app.codecov.io/gh/apache/pinot/pull/13358?src=pr=tree=pinot-core%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fpinot%2Fcore%2Fquery%2Faggregation%2Ffunction%2Farray%2FBaseArrayAggIntFunction.java_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache#diff-cGlub3QtY29yZS9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvcGlub3QvY29yZS9xdWVyeS9hZ2dyZWdhdGlvbi9mdW5jdGlvbi9hcnJheS9CYXNlQXJyYXlBZ2dJbnRGdW5jdGlvbi5qYXZh)
 | 0.00% | [2 Missing :warning: 
](https://app.codecov.io/gh/apache/pinot/pull/13358?src=pr=tree_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 |
   | 
[...ation/function/array/BaseArrayAggLongFunction.java](https://app.codecov.io/gh/apache/pinot/pull/13358?src=pr=tree=pinot-core%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fpinot%2Fcore%2Fquery%2Faggregation%2Ffunction%2Farray%2FBaseArrayAggLongFunction.java_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache#diff-cGlub3QtY29yZS9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvcGlub3QvY29yZS9xdWVyeS9hZ2dyZWdhdGlvbi9mdW5jdGlvbi9hcnJheS9CYXNlQXJyYXlBZ2dMb25nRnVuY3Rpb24uamF2YQ==)
 | 0.00% | [2 Missing :warning: 
](https://app.codecov.io/gh/apache/pinot/pull/13358?src=pr=tree_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 |
   | 
[...ion/function/array/BaseArrayAggStringFunction.java](https://app.codecov.io/gh/apache/pinot/pull/13358?src=pr=tree=pinot-core%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fpinot%2Fcore%2Fquery%2Faggregation%2Ffunction%2Farray%2FBaseArrayAggStringFunction.java_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache#diff-cGlub3QtY29yZS9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvcGlub3QvY29yZS9xdWVyeS9hZ2dyZWdhdGlvbi9mdW5jdGlvbi9hcnJheS9CYXNlQXJyYXlBZ2dTdHJpbmdGdW5jdGlvbi5qYXZh)
 | 0.00% | [2 Missing :warning: 
](https://app.codecov.io/gh/apache/pinot/pull/13358?src=pr=tree_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 |
   | 
[...ry/aggregation/function/array/ListAggFunction.java](https://app.codecov.io/gh/apache/pinot/pull/13358?src=pr=tree=pinot-core%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fpinot%2Fcore%2Fquery%2Faggregation%2Ffunction%2Farray%2FListAggFunction.java_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache#diff-cGlub3QtY29yZS9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvcGlub3QvY29yZS9xdWVyeS9hZ2dyZWdhdGlvbi9mdW5jdGlvbi9hcnJheS9MaXN0QWdnRnVuY3Rpb24uamF2YQ==)
 | 0.00% | [2 Missing :warning: 

Re: [PR] update RewriterConstants [pinot]

2024-06-10 Thread via GitHub


codecov-commenter commented on PR #13357:
URL: https://github.com/apache/pinot/pull/13357#issuecomment-2159597608

   ## 
[Codecov](https://app.codecov.io/gh/apache/pinot/pull/13357?dropdown=coverage=pr=h1_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 Report
   Attention: Patch coverage is `0%` with `4 lines` in your changes missing 
coverage. Please review.
   > Project coverage is 0.00%. Comparing base 
[(`59551e4`)](https://app.codecov.io/gh/apache/pinot/commit/59551e45224f1535c4863fd577622b37366ccc97?dropdown=coverage=desc_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 to head 
[(`08bbe70`)](https://app.codecov.io/gh/apache/pinot/commit/08bbe70d2c1d0db0639e149d7fbc9fd7b65e4e8c?dropdown=coverage=desc_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache).
   > Report is 598 commits behind head on master.
   
   | 
[Files](https://app.codecov.io/gh/apache/pinot/pull/13357?dropdown=coverage=pr=tree_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | Patch % | Lines |
   |---|---|---|
   | 
[...che/pinot/segment/spi/AggregationFunctionType.java](https://app.codecov.io/gh/apache/pinot/pull/13357?src=pr=tree=pinot-segment-spi%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fpinot%2Fsegment%2Fspi%2FAggregationFunctionType.java_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache#diff-cGlub3Qtc2VnbWVudC1zcGkvc3JjL21haW4vamF2YS9vcmcvYXBhY2hlL3Bpbm90L3NlZ21lbnQvc3BpL0FnZ3JlZ2F0aW9uRnVuY3Rpb25UeXBlLmphdmE=)
 | 0.00% | [4 Missing :warning: 
](https://app.codecov.io/gh/apache/pinot/pull/13357?src=pr=tree_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 |
   
   Additional details and impacted files
   
   
   ```diff
   @@  Coverage Diff  @@
   ## master   #13357   +/-   ##
   =
   - Coverage 61.75%0.00%   -61.76% 
   =
 Files  2436 2472   +36 
 Lines133233   136268 +3035 
 Branches  2063621166  +530 
   =
   - Hits  822740-82274 
   - Misses44911   136268+91357 
   + Partials   60480 -6048 
   ```
   
   | 
[Flag](https://app.codecov.io/gh/apache/pinot/pull/13357/flags?src=pr=flags_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | Coverage Δ | |
   |---|---|---|
   | 
[custom-integration1](https://app.codecov.io/gh/apache/pinot/pull/13357/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `?` | |
   | 
[integration](https://app.codecov.io/gh/apache/pinot/pull/13357/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `0.00% <0.00%> (-0.01%)` | :arrow_down: |
   | 
[integration1](https://app.codecov.io/gh/apache/pinot/pull/13357/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `?` | |
   | 
[integration2](https://app.codecov.io/gh/apache/pinot/pull/13357/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `0.00% <0.00%> (ø)` | |
   | 
[java-11](https://app.codecov.io/gh/apache/pinot/pull/13357/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `0.00% <0.00%> (-61.71%)` | :arrow_down: |
   | 
[java-21](https://app.codecov.io/gh/apache/pinot/pull/13357/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `0.00% <0.00%> (-61.63%)` | :arrow_down: |
   | 
[skip-bytebuffers-false](https://app.codecov.io/gh/apache/pinot/pull/13357/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `0.00% <0.00%> (-61.75%)` | :arrow_down: |
   | 
[skip-bytebuffers-true](https://app.codecov.io/gh/apache/pinot/pull/13357/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `0.00% <0.00%> (-27.73%)` | :arrow_down: |
   | 
[temurin](https://app.codecov.io/gh/apache/pinot/pull/13357/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `0.00% <0.00%> (-61.76%)` | :arrow_down: |
   | 
[unittests](https://app.codecov.io/gh/apache/pinot/pull/13357/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `?` | |
   | 
[unittests1](https://app.codecov.io/gh/apache/pinot/pull/13357/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `?` | |
   | 
[unittests2](https://app.codecov.io/gh/apache/pinot/pull/13357/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `?` | |
   
  

Re: [PR] Exclude dimensions from star-tree index stored type check [pinot]

2024-06-10 Thread via GitHub


Jackie-Jiang commented on code in PR #13355:
URL: https://github.com/apache/pinot/pull/13355#discussion_r1634027291


##
pinot-segment-local/src/test/java/org/apache/pinot/segment/local/startree/v2/builder/StarTreeIndexSeparatorTest.java:
##
@@ -18,85 +18,63 @@
  */
 package org.apache.pinot.segment.local.startree.v2.builder;
 
-import com.google.common.collect.Lists;
 import java.io.File;
-import java.io.IOException;
 import java.net.URL;
 import java.util.Arrays;
+import java.util.HashSet;
 import java.util.List;
-import java.util.Objects;
-import org.apache.commons.configuration2.PropertiesConfiguration;
-import org.apache.commons.configuration2.ex.ConfigurationException;
+import java.util.Set;
 import org.apache.commons.io.FileUtils;
-import org.apache.pinot.segment.spi.V1Constants;
+import org.apache.pinot.segment.spi.index.metadata.SegmentMetadataImpl;
 import org.apache.pinot.segment.spi.index.startree.StarTreeV2Constants;
 import org.apache.pinot.spi.config.table.StarTreeIndexConfig;
-import org.apache.pinot.spi.env.CommonsConfigurationUtils;
+import org.testng.annotations.AfterClass;
 import org.testng.annotations.BeforeClass;
 import org.testng.annotations.Test;
 
 import static 
org.apache.pinot.segment.spi.V1Constants.Indexes.RAW_SV_FORWARD_INDEX_FILE_EXTENSION;
 import static 
org.apache.pinot.segment.spi.V1Constants.Indexes.UNSORTED_SV_FORWARD_INDEX_FILE_EXTENSION;
 import static 
org.apache.pinot.segment.spi.index.startree.StarTreeV2Constants.STAR_TREE_INDEX_FILE_NAME;
-import static org.testng.AssertJUnit.assertEquals;
-import static org.testng.AssertJUnit.assertNotNull;
+import static org.testng.Assert.assertNotNull;
 import static org.testng.AssertJUnit.assertTrue;
 
 
 public class StarTreeIndexSeparatorTest {
-
   private static final String SEGMENT_PATH = "data/startree/segment";
-  private static final String TOTAL_DOCS_KEY = "startree.v2.0.total.docs";
-
-  private StarTreeIndexSeparator _separator;
-  private PropertiesConfiguration _metadataProperties;
-  private final StarTreeV2BuilderConfig _builderConfig = 
StarTreeV2BuilderConfig.fromIndexConfig(
-  new StarTreeIndexConfig(
-  Lists.newArrayList("AirlineID", "Origin", "Dest"),
-  Lists.newArrayList(),
-  Lists.newArrayList("count__*", "max__ArrDelay"),
-  null,
-  10));
+  private final StarTreeV2BuilderConfig BUILDER_CONFIG = 
StarTreeV2BuilderConfig.fromIndexConfig(
+  new StarTreeIndexConfig(List.of("AirlineID", "Origin", "Dest"), 
List.of(), List.of("count__*", "max__ArrDelay"),

Review Comment:
   Good suggestion. Updated `BaseStarTreeV2Test` to capture that



-- 
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: commits-unsubscr...@pinot.apache.org

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


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



Re: [PR] Exclude dimensions from star-tree index stored type check [pinot]

2024-06-10 Thread via GitHub


Jackie-Jiang commented on code in PR #13355:
URL: https://github.com/apache/pinot/pull/13355#discussion_r1634019815


##
pinot-segment-local/src/main/java/org/apache/pinot/segment/local/segment/store/SegmentLocalFSDirectory.java:
##
@@ -268,7 +267,7 @@ private synchronized void loadData()
   default:
 break;
 }
-if 
(CollectionUtils.isNotEmpty(_segmentMetadata.getStarTreeV2MetadataList())) {
+if (_segmentMetadata.getStarTreeV2MetadataList() != null) {

Review Comment:
   It cannot be empty, only null or non-empty. I modified this place to make it 
consistent with other callers



-- 
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: commits-unsubscr...@pinot.apache.org

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


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



Re: [PR] Exclude dimensions from star-tree index stored type check [pinot]

2024-06-10 Thread via GitHub


Jackie-Jiang commented on code in PR #13355:
URL: https://github.com/apache/pinot/pull/13355#discussion_r1634019517


##
pinot-segment-local/src/main/java/org/apache/pinot/segment/local/segment/store/StarTreeIndexReader.java:
##
@@ -67,17 +66,11 @@ public class StarTreeIndexReader implements Closeable {
*/
   public StarTreeIndexReader(File segmentDirectory, SegmentMetadataImpl 
segmentMetadata, ReadMode readMode)
   throws IOException, ConfigurationException {
-Preconditions.checkNotNull(segmentDirectory);

Review Comment:
   Yes. It is internal class, thus we can control all the caller behavior. We 
usually annotate argument that can be null with `@Nullable`, and skip the null 
check for performance reason



-- 
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: commits-unsubscr...@pinot.apache.org

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


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



Re: [I] Allowing empty segments with no offset advancing [pinot]

2024-06-10 Thread via GitHub


Jackie-Jiang commented on issue #12703:
URL: https://github.com/apache/pinot/issues/12703#issuecomment-2159568541

   > Is this as straight-forward as removing these lines?
   
   I think so.
   
   The drawback is that we might end up with a lot of segments that are all 
empty, but I guess we can make retention manager keep cleaning up empty 
segments (it might already do) as long as they are not the last completed 
segment.


-- 
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: commits-unsubscr...@pinot.apache.org

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


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



Re: [PR] extend CompactedPinotSegmentRecordReader so that it can skip deleteRecord [pinot]

2024-06-10 Thread via GitHub


tibrewalpratik17 commented on code in PR #13352:
URL: https://github.com/apache/pinot/pull/13352#discussion_r1634014707


##
pinot-segment-local/src/main/java/org/apache/pinot/segment/local/segment/readers/CompactedPinotSegmentRecordReader.java:
##
@@ -36,19 +37,25 @@
 public class CompactedPinotSegmentRecordReader implements RecordReader {
   private final PinotSegmentRecordReader _pinotSegmentRecordReader;
   private final RoaringBitmap _validDocIdsBitmap;
-
+  private final String _deleteRecordColumn;
+  // Reusable generic row to store the next row to return
+  private final GenericRow _nextRow = new GenericRow();
   // Valid doc ids iterator
   private PeekableIntIterator _validDocIdsIterator;
-  // Reusable generic row to store the next row to return
-  private GenericRow _nextRow = new GenericRow();
   // Flag to mark whether we need to fetch another row
   private boolean _nextRowReturned = true;
 
   public CompactedPinotSegmentRecordReader(File indexDir, RoaringBitmap 
validDocIds) {
+this(indexDir, validDocIds, null);
+  }
+
+  public CompactedPinotSegmentRecordReader(File indexDir, RoaringBitmap 
validDocIds,
+  @Nullable String deleteRecordColumn) {

Review Comment:
   @klsince you can make it an Upsert Compaction task-level config as well if 
you want to use this flag flexibly in your cluster. By default, we can disable 
it. 



-- 
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: commits-unsubscr...@pinot.apache.org

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


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



Re: [PR] Fix [Type]ArrayList elements() method usage [pinot]

2024-06-10 Thread via GitHub


xiangfu0 commented on code in PR #13354:
URL: https://github.com/apache/pinot/pull/13354#discussion_r1634013898


##
pinot-common/src/main/java/org/apache/pinot/common/utils/DataSchema.java:
##
@@ -523,7 +523,7 @@ private static int[] toIntArray(Object value) {
 return (int[]) value;
   } else if (value instanceof IntArrayList) {
 // For ArrayAggregationFunction
-return ((IntArrayList) value).elements();
+return ((IntArrayList) value).toIntArray();

Review Comment:
   done.



-- 
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: commits-unsubscr...@pinot.apache.org

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


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



Re: [PR] New buffers [pinot]

2024-06-10 Thread via GitHub


Jackie-Jiang commented on code in PR #13304:
URL: https://github.com/apache/pinot/pull/13304#discussion_r1634007122


##
pinot-segment-spi/src/main/java/org/apache/pinot/segment/spi/memory/DataBuffer.java:
##
@@ -0,0 +1,292 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.pinot.segment.spi.memory;
+
+import java.io.Closeable;
+import java.io.File;
+import java.io.IOException;
+import java.nio.ByteBuffer;
+import java.nio.ByteOrder;
+import java.util.List;
+import java.util.Objects;
+import org.roaringbitmap.buffer.ImmutableRoaringBitmap;
+
+
+public interface DataBuffer extends Closeable {
+
+  default byte getByte(int offset) {
+return getByte((long) offset);
+  }
+
+  byte getByte(long offset);
+
+  default void putByte(int offset, byte value) {
+putByte((long) offset, value);
+  }
+
+  void putByte(long offset, byte value);
+
+  default char getChar(int offset) {
+return getChar((long) offset);
+  }
+
+  char getChar(long offset);
+
+  default void putChar(int offset, char value) {
+putChar((long) offset, value);
+  }
+
+  void putChar(long offset, char value);
+
+  default short getShort(int offset) {
+return getShort((long) offset);
+  }
+
+  short getShort(long offset);
+
+  default void putShort(int offset, short value) {
+putShort((long) offset, value);
+  }
+
+  void putShort(long offset, short value);
+
+  default int getInt(int offset) {
+return getInt((long) offset);
+  }
+
+  int getInt(long offset);
+
+  default void putInt(int offset, int value) {
+putInt((long) offset, value);
+  }
+
+  void putInt(long offset, int value);
+
+  default long getLong(int offset) {
+return getLong((long) offset);
+  }
+
+  long getLong(long offset);
+
+  default void putLong(int offset, long value) {
+putLong((long) offset, value);
+  }
+
+  void putLong(long offset, long value);
+
+  default float getFloat(int offset) {
+return getFloat((long) offset);
+  }
+
+  float getFloat(long offset);
+
+  default void putFloat(int offset, float value) {
+putFloat((long) offset, value);
+  }
+
+  void putFloat(long offset, float value);
+
+  default double getDouble(int offset) {
+return getDouble((long) offset);
+  }
+
+  double getDouble(long offset);
+
+  default void putDouble(int offset, double value) {
+putDouble((long) offset, value);
+  }
+
+  void putDouble(long offset, double value);
+
+  /**
+   * Given an array of bytes, copies the content of this object into the array 
of bytes.
+   * The first byte to be copied is the one that could be read with {@code 
this.getByte(offset)}
+   */
+  void copyTo(long offset, byte[] buffer, int destOffset, int size);
+
+  /**
+   * Given an array of bytes, copies the content of this object into the array 
of bytes.
+   * The first byte to be copied is the one that could be read with {@code 
this.getByte(offset)}
+   */
+  default void copyTo(long offset, byte[] buffer) {
+copyTo(offset, buffer, 0, buffer.length);
+  }
+
+  /**
+   * Note: It is the responsibility of the caller to make sure arguments are 
checked before the methods are called.
+   * While some rudimentary checks are performed on the input, the checks are 
best effort and when performance is an
+   * overriding priority, as when methods of this class are optimized by the 
runtime compiler, some or all checks
+   * (if any) may be elided. Hence, the caller must not rely on the checks and 
corresponding exceptions!
+   */
+  void copyTo(long offset, DataBuffer buffer, long destOffset, long size);
+
+  default void copyTo(long offset, ByteBuffer buffer, int destOffset, int 
size) {
+PinotByteBuffer wrap = PinotByteBuffer.wrap(buffer);
+copyTo(offset, wrap, destOffset, size);
+  }
+
+  /**
+   * Given an array of bytes, writes the content in the specified position.
+   */
+  void readFrom(long offset, byte[] buffer, int srcOffset, int size);
+
+  default void readFrom(long offset, byte[] buffer) {
+readFrom(offset, buffer, 0, buffer.length);
+  }
+
+  void readFrom(long offset, ByteBuffer buffer);
+
+  void readFrom(long offset, File file, long srcOffset, long size)
+  throws IOException;
+
+  long size();
+
+  ByteOrder order();
+
+ 

Re: [PR] Exclude dimensions from star-tree index stored type check [pinot]

2024-06-10 Thread via GitHub


codecov-commenter commented on PR #13355:
URL: https://github.com/apache/pinot/pull/13355#issuecomment-2159556815

   ## 
[Codecov](https://app.codecov.io/gh/apache/pinot/pull/13355?dropdown=coverage=pr=h1_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 Report
   Attention: Patch coverage is `0%` with `33 lines` in your changes missing 
coverage. Please review.
   > Project coverage is 0.00%. Comparing base 
[(`59551e4`)](https://app.codecov.io/gh/apache/pinot/commit/59551e45224f1535c4863fd577622b37366ccc97?dropdown=coverage=desc_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 to head 
[(`e4f6219`)](https://app.codecov.io/gh/apache/pinot/commit/e4f6219b1f2defdb2458e58ba848c249311cbb6f?dropdown=coverage=desc_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache).
   > Report is 598 commits behind head on master.
   
   | 
[Files](https://app.codecov.io/gh/apache/pinot/pull/13355?dropdown=coverage=pr=tree_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | Patch % | Lines |
   |---|---|---|
   | 
[...local/startree/v2/store/StarTreeIndexMapUtils.java](https://app.codecov.io/gh/apache/pinot/pull/13355?src=pr=tree=pinot-segment-local%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fpinot%2Fsegment%2Flocal%2Fstartree%2Fv2%2Fstore%2FStarTreeIndexMapUtils.java_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache#diff-cGlub3Qtc2VnbWVudC1sb2NhbC9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvcGlub3Qvc2VnbWVudC9sb2NhbC9zdGFydHJlZS92Mi9zdG9yZS9TdGFyVHJlZUluZGV4TWFwVXRpbHMuamF2YQ==)
 | 0.00% | [11 Missing :warning: 
](https://app.codecov.io/gh/apache/pinot/pull/13355?src=pr=tree_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 |
   | 
[...al/startree/v2/builder/StarTreeIndexSeparator.java](https://app.codecov.io/gh/apache/pinot/pull/13355?src=pr=tree=pinot-segment-local%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fpinot%2Fsegment%2Flocal%2Fstartree%2Fv2%2Fbuilder%2FStarTreeIndexSeparator.java_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache#diff-cGlub3Qtc2VnbWVudC1sb2NhbC9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvcGlub3Qvc2VnbWVudC9sb2NhbC9zdGFydHJlZS92Mi9idWlsZGVyL1N0YXJUcmVlSW5kZXhTZXBhcmF0b3IuamF2YQ==)
 | 0.00% | [10 Missing :warning: 
](https://app.codecov.io/gh/apache/pinot/pull/13355?src=pr=tree_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 |
   | 
[...ocal/startree/v2/builder/MultipleTreesBuilder.java](https://app.codecov.io/gh/apache/pinot/pull/13355?src=pr=tree=pinot-segment-local%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fpinot%2Fsegment%2Flocal%2Fstartree%2Fv2%2Fbuilder%2FMultipleTreesBuilder.java_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache#diff-cGlub3Qtc2VnbWVudC1sb2NhbC9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvcGlub3Qvc2VnbWVudC9sb2NhbC9zdGFydHJlZS92Mi9idWlsZGVyL011bHRpcGxlVHJlZXNCdWlsZGVyLmphdmE=)
 | 0.00% | [6 Missing :warning: 
](https://app.codecov.io/gh/apache/pinot/pull/13355?src=pr=tree_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 |
   | 
[...gment/local/segment/store/StarTreeIndexReader.java](https://app.codecov.io/gh/apache/pinot/pull/13355?src=pr=tree=pinot-segment-local%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fpinot%2Fsegment%2Flocal%2Fsegment%2Fstore%2FStarTreeIndexReader.java_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache#diff-cGlub3Qtc2VnbWVudC1sb2NhbC9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvcGlub3Qvc2VnbWVudC9sb2NhbC9zZWdtZW50L3N0b3JlL1N0YXJUcmVlSW5kZXhSZWFkZXIuamF2YQ==)
 | 0.00% | [5 Missing :warning: 
](https://app.codecov.io/gh/apache/pinot/pull/13355?src=pr=tree_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 |
   | 
[...t/local/segment/store/SegmentLocalFSDirectory.java](https://app.codecov.io/gh/apache/pinot/pull/13355?src=pr=tree=pinot-segment-local%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fpinot%2Fsegment%2Flocal%2Fsegment%2Fstore%2FSegmentLocalFSDirectory.java_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache#diff-cGlub3Qtc2VnbWVudC1sb2NhbC9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvcGlub3Qvc2VnbWVudC9sb2NhbC9zZWdtZW50L3N0b3JlL1NlZ21lbnRMb2NhbEZTRGlyZWN0b3J5LmphdmE=)
 | 0.00% | [1 Missing :warning: 
](https://app.codecov.io/gh/apache/pinot/pull/13355?src=pr=tree_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 |
   
   Additional details and impacted files
   
   
   ```diff
   @@  Coverage Diff  @@
   ## master   #13355   +/-   ##
   =
   - Coverage 61.75%0.00%   -61.76% 
   =
 Files  2436 2472   +36 
 Lines133233   136259 +3026 
 Branches  2063621167  +531 
   =
   - Hits  

[PR] update RewriterConstants [pinot]

2024-06-10 Thread via GitHub


jasperjiaguo opened a new pull request, #13357:
URL: https://github.com/apache/pinot/pull/13357

   Instructions:
   1. The PR has to be tagged with at least one of the following labels (*):
  1. `feature`
  2. `bugfix`
  3. `performance`
  4. `ui`
  5. `backward-incompat`
  6. `release-notes` (**)
   2. Remove these instructions before publishing the PR.

   (*) Other labels to consider:
   - `testing`
   - `dependencies`
   - `docker`
   - `kubernetes`
   - `observability`
   - `security`
   - `code-style`
   - `extension-point`
   - `refactor`
   - `cleanup`
   
   (**) Use `release-notes` label for scenarios like:
   - New configuration options
   - Deprecation of configurations
   - Signature changes to public methods/interfaces
   - New plugins added or old plugins removed
   


-- 
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: commits-unsubscr...@pinot.apache.org

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


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



Re: [PR] Exclude dimensions from star-tree index stored type check [pinot]

2024-06-10 Thread via GitHub


jadami10 commented on code in PR #13355:
URL: https://github.com/apache/pinot/pull/13355#discussion_r1634000831


##
pinot-segment-local/src/main/java/org/apache/pinot/segment/local/segment/store/SegmentLocalFSDirectory.java:
##
@@ -268,7 +267,7 @@ private synchronized void loadData()
   default:
 break;
 }
-if 
(CollectionUtils.isNotEmpty(_segmentMetadata.getStarTreeV2MetadataList())) {
+if (_segmentMetadata.getStarTreeV2MetadataList() != null) {

Review Comment:
   looks like you've updated it to just handle an empty list instead?



##
pinot-segment-local/src/main/java/org/apache/pinot/segment/local/segment/store/StarTreeIndexReader.java:
##
@@ -67,17 +66,11 @@ public class StarTreeIndexReader implements Closeable {
*/
   public StarTreeIndexReader(File segmentDirectory, SegmentMetadataImpl 
segmentMetadata, ReadMode readMode)
   throws IOException, ConfigurationException {
-Preconditions.checkNotNull(segmentDirectory);

Review Comment:
   what's the reason for removing all these? It's guaranteed elsewhere?



##
pinot-segment-local/src/test/java/org/apache/pinot/segment/local/startree/v2/builder/StarTreeIndexSeparatorTest.java:
##
@@ -18,85 +18,63 @@
  */
 package org.apache.pinot.segment.local.startree.v2.builder;
 
-import com.google.common.collect.Lists;
 import java.io.File;
-import java.io.IOException;
 import java.net.URL;
 import java.util.Arrays;
+import java.util.HashSet;
 import java.util.List;
-import java.util.Objects;
-import org.apache.commons.configuration2.PropertiesConfiguration;
-import org.apache.commons.configuration2.ex.ConfigurationException;
+import java.util.Set;
 import org.apache.commons.io.FileUtils;
-import org.apache.pinot.segment.spi.V1Constants;
+import org.apache.pinot.segment.spi.index.metadata.SegmentMetadataImpl;
 import org.apache.pinot.segment.spi.index.startree.StarTreeV2Constants;
 import org.apache.pinot.spi.config.table.StarTreeIndexConfig;
-import org.apache.pinot.spi.env.CommonsConfigurationUtils;
+import org.testng.annotations.AfterClass;
 import org.testng.annotations.BeforeClass;
 import org.testng.annotations.Test;
 
 import static 
org.apache.pinot.segment.spi.V1Constants.Indexes.RAW_SV_FORWARD_INDEX_FILE_EXTENSION;
 import static 
org.apache.pinot.segment.spi.V1Constants.Indexes.UNSORTED_SV_FORWARD_INDEX_FILE_EXTENSION;
 import static 
org.apache.pinot.segment.spi.index.startree.StarTreeV2Constants.STAR_TREE_INDEX_FILE_NAME;
-import static org.testng.AssertJUnit.assertEquals;
-import static org.testng.AssertJUnit.assertNotNull;
+import static org.testng.Assert.assertNotNull;
 import static org.testng.AssertJUnit.assertTrue;
 
 
 public class StarTreeIndexSeparatorTest {
-
   private static final String SEGMENT_PATH = "data/startree/segment";
-  private static final String TOTAL_DOCS_KEY = "startree.v2.0.total.docs";
-
-  private StarTreeIndexSeparator _separator;
-  private PropertiesConfiguration _metadataProperties;
-  private final StarTreeV2BuilderConfig _builderConfig = 
StarTreeV2BuilderConfig.fromIndexConfig(
-  new StarTreeIndexConfig(
-  Lists.newArrayList("AirlineID", "Origin", "Dest"),
-  Lists.newArrayList(),
-  Lists.newArrayList("count__*", "max__ArrDelay"),
-  null,
-  10));
+  private final StarTreeV2BuilderConfig BUILDER_CONFIG = 
StarTreeV2BuilderConfig.fromIndexConfig(
+  new StarTreeIndexConfig(List.of("AirlineID", "Origin", "Dest"), 
List.of(), List.of("count__*", "max__ArrDelay"),

Review Comment:
   should one of the dimensions specifically have the `__` format?



-- 
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: commits-unsubscr...@pinot.apache.org

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


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



(pinot) branch dependabot/npm_and_yarn/pinot-controller/src/main/resources/multi-8616326b9a deleted (was b18d139681)

2024-06-10 Thread github-bot
This is an automated email from the ASF dual-hosted git repository.

github-bot pushed a change to branch 
dependabot/npm_and_yarn/pinot-controller/src/main/resources/multi-8616326b9a
in repository https://gitbox.apache.org/repos/asf/pinot.git


 was b18d139681 Bump braces, webpack, webpack-cli and webpack-dev-server

The revisions that were on this branch are still contained in
other references; therefore, this change does not discard any commits
from the repository.


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



Re: [PR] Bump braces, webpack, webpack-cli and webpack-dev-server in /pinot-controller/src/main/resources [pinot]

2024-06-10 Thread via GitHub


Jackie-Jiang closed pull request #13356: Bump braces, webpack, webpack-cli and 
webpack-dev-server in /pinot-controller/src/main/resources
URL: https://github.com/apache/pinot/pull/13356


-- 
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: commits-unsubscr...@pinot.apache.org

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


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



Re: [PR] Bump braces, webpack, webpack-cli and webpack-dev-server in /pinot-controller/src/main/resources [pinot]

2024-06-10 Thread via GitHub


dependabot[bot] commented on PR #13356:
URL: https://github.com/apache/pinot/pull/13356#issuecomment-2159537462

   OK, I won't notify you again about this release, but will get in touch when 
a new version is available. You can also ignore all major, minor, or patch 
releases for a dependency by adding an [`ignore` 
condition](https://docs.github.com/en/code-security/supply-chain-security/configuration-options-for-dependency-updates#ignore)
 with the desired `update_types` to your config file.
   
   If you change your mind, just re-open this PR and I'll resolve any conflicts 
on it.


-- 
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: commits-unsubscr...@pinot.apache.org

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


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



Re: [I] Server crashing with OOM error [pinot]

2024-06-10 Thread via GitHub


Jackie-Jiang commented on issue #13335:
URL: https://github.com/apache/pinot/issues/13335#issuecomment-2159535985

   A thread dump can help capture the hotspot objects. This is also a good 
candidate question in the slack troubleshooting channel


-- 
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: commits-unsubscr...@pinot.apache.org

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


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



(pinot) branch master updated (393f130715 -> ad5ca349ab)

2024-06-10 Thread jackie
This is an automated email from the ASF dual-hosted git repository.

jackie pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/pinot.git


from 393f130715 Clean Google Dependencies (#13297)
 add ad5ca349ab Add list of collaborators to asf.yaml (#13346)

No new revisions were added by this update.

Summary of changes:
 .asf.yaml | 11 +++
 1 file changed, 11 insertions(+)


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



Re: [PR] Add list of collaborators to asf.yaml [pinot]

2024-06-10 Thread via GitHub


Jackie-Jiang merged PR #13346:
URL: https://github.com/apache/pinot/pull/13346


-- 
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: commits-unsubscr...@pinot.apache.org

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


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



(pinot) branch dependabot/npm_and_yarn/pinot-controller/src/main/resources/multi-8616326b9a created (now b18d139681)

2024-06-10 Thread github-bot
This is an automated email from the ASF dual-hosted git repository.

github-bot pushed a change to branch 
dependabot/npm_and_yarn/pinot-controller/src/main/resources/multi-8616326b9a
in repository https://gitbox.apache.org/repos/asf/pinot.git


  at b18d139681 Bump braces, webpack, webpack-cli and webpack-dev-server

No new revisions were added by this update.


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



[PR] Bump braces, webpack, webpack-cli and webpack-dev-server in /pinot-controller/src/main/resources [pinot]

2024-06-10 Thread via GitHub


dependabot[bot] opened a new pull request, #13356:
URL: https://github.com/apache/pinot/pull/13356

   Bumps [braces](https://github.com/micromatch/braces) to 3.0.3 and updates 
ancestor dependencies [braces](https://github.com/micromatch/braces), 
[webpack](https://github.com/webpack/webpack), 
[webpack-cli](https://github.com/webpack/webpack-cli) and 
[webpack-dev-server](https://github.com/webpack/webpack-dev-server). These 
dependencies need to be updated together.
   
   Updates `braces` from 3.0.2 to 3.0.3
   
   Commits
   
   https://github.com/micromatch/braces/commit/74b2db2938fad48a2ea54a9c8bf27a37a62c350d;>74b2db2
 3.0.3
   https://github.com/micromatch/braces/commit/88f1429a0f47e1dd3813de35211fc97ffda27f9e;>88f1429
 update eslint. lint, fix unit tests.
   https://github.com/micromatch/braces/commit/415d660c3002d1ab7e63dbf490c9851da80596ff;>415d660
 Snyk js braces 6838727 (https://redirect.github.com/micromatch/braces/issues/40;>#40)
   https://github.com/micromatch/braces/commit/190510f79db1adf21d92798b0bb6fccc1f72c9d6;>190510f
 fix tests, skip 1 test in test/braces.expand
   https://github.com/micromatch/braces/commit/716eb9f12d820b145a831ad678618731927e8856;>716eb9f
 readme bump
   https://github.com/micromatch/braces/commit/a5851e57f45c3431a94d83fc565754bc10f5bbc3;>a5851e5
 Merge pull request https://redirect.github.com/micromatch/braces/issues/37;>#37 from 
coderaiser/fix/vulnerability
   https://github.com/micromatch/braces/commit/2092bd1fb108d2c59bd62e243b70ad98db961538;>2092bd1
 feature: braces: add maxSymbols (https://github.com/micromatch/braces/issues/;>https://github.com/micromatch/braces/issues/...
   https://github.com/micromatch/braces/commit/9f5b4cf47329351bcb64287223ffb6ecc9a5e6d3;>9f5b4cf
 fix: vulnerability (https://security.snyk.io/vuln/SNYK-JS-BRACES-6838727;>https://security.snyk.io/vuln/SNYK-JS-BRACES-6838727)
   https://github.com/micromatch/braces/commit/98414f9f1fabe021736e26836d8306d5de747e0d;>98414f9
 remove funding file
   https://github.com/micromatch/braces/commit/665ab5d561c017a38ba7aafd92cc6655b91d8c14;>665ab5d
 update keepEscaping doc (https://redirect.github.com/micromatch/braces/issues/27;>#27)
   Additional commits viewable in https://github.com/micromatch/braces/compare/3.0.2...3.0.3;>compare 
view
   
   
   
   
   Updates `webpack` from 4.29.6 to 5.91.0
   
   Release notes
   Sourced from https://github.com/webpack/webpack/releases;>webpack's 
releases.
   
   v5.91.0
   Bug Fixes
   
   Deserializer for ignored modules doesn't crash
   Allow the unsafeCache option to be a proxy object
   Normalize the snapshot.unmanagedPaths option
   Fixed fs types
   Fixed resolve's plugins types
   Fixed wrongly calculate postOrderIndex
   Fixed watching types
   Output import attrbiutes/import assertions for external JS imports
   Throw an error when DllPlugin needs to generate multiple manifest files, 
but the path is the same
   [CSS] Output layer/supports/media 
for external CSS imports
   
   New Features
   
   Allow to customize the stage of BannerPlugin
   [CSS] Support CSS exports convention
   [CSS] support CSS local ident name
   [CSS] Support __webpack_nonce__ for CSS chunks
   [CSS] Support fetchPriority for CSS chunks
   [CSS] Allow to use LZW to compress css head meta (enabled in the 
production mode by default)
   [CSS] Support prefetch/preload for CSS chunks
   
   v5.90.3
   Bug Fixes
   
   don't mangle when destructuring a reexport
   types for Stats.toJson() and 
Stats.toString()
   many internal types
   [CSS] clean up export css local vars
   
   Perf
   
   simplify and optimize chunk graph creation
   
   v5.90.2
   Bug Fixes
   
   use Math.imul in fnv1a32 to avoid loss of 
precision, directly hash UTF16 values
   the setStatus() of the HMR module should not return an 
array, which may cause infinite recursion
   __webpack_exports_info__.xxx.canMangle shouldn't always 
same as default
   mangle export with destructuring
   use new runtime to reconsider skipped connections 
activeState
   make dynamic import optional in try/catch
   improve auto publicPath detection
   
   Dependencies  Maintenance
   
   improve CI setup and include Node.js@21
   
   
   
   ... (truncated)
   
   
   Commits
   
   https://github.com/webpack/webpack/commit/60daca54105f89eee45e118fd0bbc820730724ee;>60daca5
 chore(release): 5.91.0
   https://github.com/webpack/webpack/commit/8dad9ce177a2e7153a272d8e9e177e85fe68d74e;>8dad9ce
 chore(deps-dev): bump @​babel/preset-react from 7.23.3 to 
7.24.1
   https://github.com/webpack/webpack/commit/a3229f9d6963853cff014ac60f34a0d1dc553497;>a3229f9
 chore(deps-dev): bump @​babel/core from 7.24.0 to 7.24.1
   https://github.com/webpack/webpack/commit/40c2e44ff249df16d5178a658c1b62b7f8bbae88;>40c2e44
 chore(deps-dev): bump @​types/node from 20.11.29 to 20.11.30
   https://github.com/webpack/webpack/commit/a04faba9d0e69057bbceb6b03c783bfe931e910f;>a04faba
 chore(deps-dev): bump memfs from 4.7.7 to 4.8.0
   

Re: [PR] Clean Google Dependencies [pinot]

2024-06-10 Thread via GitHub


Jackie-Jiang merged PR #13297:
URL: https://github.com/apache/pinot/pull/13297


-- 
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: commits-unsubscr...@pinot.apache.org

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


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



Re: [I] Google library dependency management [pinot]

2024-06-10 Thread via GitHub


Jackie-Jiang closed issue #13077: Google library dependency management
URL: https://github.com/apache/pinot/issues/13077


-- 
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: commits-unsubscr...@pinot.apache.org

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


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



(pinot) branch master updated: Clean Google Dependencies (#13297)

2024-06-10 Thread jackie
This is an automated email from the ASF dual-hosted git repository.

jackie pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/pinot.git


The following commit(s) were added to refs/heads/master by this push:
 new 393f130715 Clean Google Dependencies (#13297)
393f130715 is described below

commit 393f130715680f4719899069d3513627629bfcca
Author: Abhishek Sharma 
AuthorDate: Mon Jun 10 20:07:32 2024 -0400

Clean Google Dependencies (#13297)
---
 pinot-clients/pinot-java-client/pom.xml |  4 ---
 pinot-clients/pinot-jdbc-client/pom.xml |  4 ---
 pinot-common/pom.xml|  4 ---
 pinot-spi/pom.xml   |  4 ---
 pom.xml | 56 -
 5 files changed, 34 insertions(+), 38 deletions(-)

diff --git a/pinot-clients/pinot-java-client/pom.xml 
b/pinot-clients/pinot-java-client/pom.xml
index 6004a9ee39..e4e21ff3a8 100644
--- a/pinot-clients/pinot-java-client/pom.xml
+++ b/pinot-clients/pinot-java-client/pom.xml
@@ -70,10 +70,6 @@
   org.slf4j
   slf4j-api
 
-
-  com.google.code.findbugs
-  jsr305
-
 
   org.mockito
   mockito-core
diff --git a/pinot-clients/pinot-jdbc-client/pom.xml 
b/pinot-clients/pinot-jdbc-client/pom.xml
index 6ffc2fa19a..35ca068d18 100644
--- a/pinot-clients/pinot-jdbc-client/pom.xml
+++ b/pinot-clients/pinot-jdbc-client/pom.xml
@@ -76,10 +76,6 @@
   org.slf4j
   slf4j-api
 
-
-  com.google.code.findbugs
-  jsr305
-
   
   
 
diff --git a/pinot-common/pom.xml b/pinot-common/pom.xml
index 0a3ad400cc..cc18dca7b9 100644
--- a/pinot-common/pom.xml
+++ b/pinot-common/pom.xml
@@ -268,10 +268,6 @@
   net.sf.jopt-simple
   jopt-simple
 
-
-  com.google.code.findbugs
-  jsr305
-
 
   com.fasterxml.jackson.core
   jackson-annotations
diff --git a/pinot-spi/pom.xml b/pinot-spi/pom.xml
index 02fe3b6e07..883e086c57 100644
--- a/pinot-spi/pom.xml
+++ b/pinot-spi/pom.xml
@@ -98,10 +98,6 @@
   com.google.guava
   guava
 
-
-  com.google.code.findbugs
-  jsr305
-
 
   org.apache.logging.log4j
   log4j-slf4j2-impl
diff --git a/pom.xml b/pom.xml
index 930627b667..d742c36b6b 100644
--- a/pom.xml
+++ b/pom.xml
@@ -223,13 +223,13 @@
 5.2.4
 
 
+3.25.3
+1.62.2
 26.40.0
-1.23.0
-2.10.1
-33.1.0-jre
-1.44.1
-3.25.2
-1.61.1
+1.1.1
+2.28.0
+3.0.0
+3.0.2
 
 
 2.12.19
@@ -832,6 +832,23 @@
   
 
   
+  
+  
+com.google.protobuf
+protobuf-bom
+${protobuf.version}
+pom
+import
+  
+  
+  
+io.grpc
+grpc-bom
+${grpc.version}
+pom
+import
+  
+  
   
 com.google.cloud
 libraries-bom
@@ -839,34 +856,29 @@
 pom
 import
   
-  
   
-com.google.apis
-google-api-services-storage
-v1-rev20240524-2.0.0
+com.google.auto.service
+auto-service
+${google.auto-service.version}
+true 
   
   
   
 com.google.errorprone
 error_prone_annotations
-2.28.0
+${google.errorprone.version}
   
-  
+  
   
-com.google.auto.service
-auto-service
-1.1.1
-true 
+com.google.j2objc
+j2objc-annotations
+${google.j2objc.version}
   
+  
   
 com.google.code.findbugs
 jsr305
-3.0.2
-  
-  
-com.google.j2objc
-j2objc-annotations
-3.0.0
+${google.jsr305.version}
   
 
   


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



Re: [PR] Fix [Type]ArrayList elements() method usage [pinot]

2024-06-10 Thread via GitHub


Jackie-Jiang commented on code in PR #13354:
URL: https://github.com/apache/pinot/pull/13354#discussion_r1633994691


##
pinot-common/src/main/java/org/apache/pinot/common/utils/DataSchema.java:
##
@@ -523,7 +523,7 @@ private static int[] toIntArray(Object value) {
 return (int[]) value;
   } else if (value instanceof IntArrayList) {
 // For ArrayAggregationFunction
-return ((IntArrayList) value).elements();
+return ((IntArrayList) value).toIntArray();

Review Comment:
   Add a length check?



##
pinot-query-runtime/src/main/java/org/apache/pinot/query/runtime/operator/utils/TypeUtils.java:
##
@@ -80,18 +88,23 @@ public static Object convert(Object value, ColumnDataType 
storedType) {
   case DOUBLE_ARRAY:
 if (value instanceof DoubleArrayList) {
   // For HistogramAggregationFunction and ArrayAggregationFunction
-  return ((DoubleArrayList) value).elements();
+  DoubleArrayList doubleArrayList = (DoubleArrayList) value;
+  double[] doubleArrayListElements = doubleArrayList.elements();
+  return doubleArrayListElements.length == doubleArrayList.size() ? 
doubleArrayListElements
+  : doubleArrayList.toDoubleArray();
 } else {
   return value;
 }
   case STRING_ARRAY:
 if (value instanceof ObjectArrayList) {
   // For ArrayAggregationFunction
-  return ((ObjectArrayList) value).toArray(new String[0]);
+  ObjectArrayList stringArrayList = (ObjectArrayList) 
value;
+  String[] elements = stringArrayList.elements();
+  return elements.length == stringArrayList.size() ? elements : 
stringArrayList.toArray(new String[0]);
 } else {
   return value;
 }
-  // TODO: Add more conversions
+// TODO: Add more conversions

Review Comment:
   (nit) Revert



-- 
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: commits-unsubscr...@pinot.apache.org

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


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



[PR] Exclude dimensions from star-tree index stored type check [pinot]

2024-06-10 Thread via GitHub


Jackie-Jiang opened a new pull request, #13355:
URL: https://github.com/apache/pinot/pull/13355

   Related to #12164 and #12554
   
   Do not check stored type for dimensions to avoid mismatching columns with 
'__' in column name


-- 
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: commits-unsubscr...@pinot.apache.org

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


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



Re: [PR] move shouldReplaceOnComparisonTie to base class to be more reusable [pinot]

2024-06-10 Thread via GitHub


codecov-commenter commented on PR #13353:
URL: https://github.com/apache/pinot/pull/13353#issuecomment-2159496652

   ## 
[Codecov](https://app.codecov.io/gh/apache/pinot/pull/13353?dropdown=coverage=pr=h1_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 Report
   Attention: Patch coverage is `0%` with `12 lines` in your changes missing 
coverage. Please review.
   > Project coverage is 0.00%. Comparing base 
[(`59551e4`)](https://app.codecov.io/gh/apache/pinot/commit/59551e45224f1535c4863fd577622b37366ccc97?dropdown=coverage=desc_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 to head 
[(`581062a`)](https://app.codecov.io/gh/apache/pinot/commit/581062ab856aafcbbef08b283d4c5f99730a675a?dropdown=coverage=desc_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache).
   > Report is 596 commits behind head on master.
   
   | 
[Files](https://app.codecov.io/gh/apache/pinot/pull/13353?dropdown=coverage=pr=tree_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | Patch % | Lines |
   |---|---|---|
   | 
[...cal/upsert/BasePartitionUpsertMetadataManager.java](https://app.codecov.io/gh/apache/pinot/pull/13353?src=pr=tree=pinot-segment-local%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fpinot%2Fsegment%2Flocal%2Fupsert%2FBasePartitionUpsertMetadataManager.java_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache#diff-cGlub3Qtc2VnbWVudC1sb2NhbC9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvcGlub3Qvc2VnbWVudC9sb2NhbC91cHNlcnQvQmFzZVBhcnRpdGlvblVwc2VydE1ldGFkYXRhTWFuYWdlci5qYXZh)
 | 0.00% | [12 Missing :warning: 
](https://app.codecov.io/gh/apache/pinot/pull/13353?src=pr=tree_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 |
   
   Additional details and impacted files
   
   
   ```diff
   @@  Coverage Diff  @@
   ## master   #13353   +/-   ##
   =
   - Coverage 61.75%0.00%   -61.76% 
   =
 Files  2436 2472   +36 
 Lines133233   136261 +3028 
 Branches  2063621165  +529 
   =
   - Hits  822740-82274 
   - Misses44911   136261+91350 
   + Partials   60480 -6048 
   ```
   
   | 
[Flag](https://app.codecov.io/gh/apache/pinot/pull/13353/flags?src=pr=flags_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | Coverage Δ | |
   |---|---|---|
   | 
[custom-integration1](https://app.codecov.io/gh/apache/pinot/pull/13353/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `?` | |
   | 
[integration](https://app.codecov.io/gh/apache/pinot/pull/13353/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `0.00% <0.00%> (-0.01%)` | :arrow_down: |
   | 
[integration1](https://app.codecov.io/gh/apache/pinot/pull/13353/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `?` | |
   | 
[integration2](https://app.codecov.io/gh/apache/pinot/pull/13353/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `0.00% <0.00%> (ø)` | |
   | 
[java-11](https://app.codecov.io/gh/apache/pinot/pull/13353/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `?` | |
   | 
[java-21](https://app.codecov.io/gh/apache/pinot/pull/13353/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `0.00% <0.00%> (-61.63%)` | :arrow_down: |
   | 
[skip-bytebuffers-false](https://app.codecov.io/gh/apache/pinot/pull/13353/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `0.00% <0.00%> (-61.75%)` | :arrow_down: |
   | 
[skip-bytebuffers-true](https://app.codecov.io/gh/apache/pinot/pull/13353/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `?` | |
   | 
[temurin](https://app.codecov.io/gh/apache/pinot/pull/13353/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `0.00% <0.00%> (-61.76%)` | :arrow_down: |
   | 
[unittests](https://app.codecov.io/gh/apache/pinot/pull/13353/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `?` | |
   | 
[unittests1](https://app.codecov.io/gh/apache/pinot/pull/13353/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `?` | |
   | 
[unittests2](https://app.codecov.io/gh/apache/pinot/pull/13353/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `?` | |
   
   Flags with 

Re: [PR] Fix [Type]ArrayList elements() method usage [pinot]

2024-06-10 Thread via GitHub


codecov-commenter commented on PR #13354:
URL: https://github.com/apache/pinot/pull/13354#issuecomment-2159468956

   ## 
[Codecov](https://app.codecov.io/gh/apache/pinot/pull/13354?dropdown=coverage=pr=h1_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 Report
   Attention: Patch coverage is `0%` with `70 lines` in your changes missing 
coverage. Please review.
   > Project coverage is 0.00%. Comparing base 
[(`59551e4`)](https://app.codecov.io/gh/apache/pinot/commit/59551e45224f1535c4863fd577622b37366ccc97?dropdown=coverage=desc_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 to head 
[(`497ca54`)](https://app.codecov.io/gh/apache/pinot/commit/497ca54fbc0bb06b7bdaa295f723decf346c4d76?dropdown=coverage=desc_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache).
   > Report is 596 commits behind head on master.
   
   | 
[Files](https://app.codecov.io/gh/apache/pinot/pull/13354?dropdown=coverage=pr=tree_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | Patch % | Lines |
   |---|---|---|
   | 
[...e/operator/blocks/results/GroupByResultsBlock.java](https://app.codecov.io/gh/apache/pinot/pull/13354?src=pr=tree=pinot-core%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fpinot%2Fcore%2Foperator%2Fblocks%2Fresults%2FGroupByResultsBlock.java_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache#diff-cGlub3QtY29yZS9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvcGlub3QvY29yZS9vcGVyYXRvci9ibG9ja3MvcmVzdWx0cy9Hcm91cEJ5UmVzdWx0c0Jsb2NrLmphdmE=)
 | 0.00% | [24 Missing :warning: 
](https://app.codecov.io/gh/apache/pinot/pull/13354?src=pr=tree_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 |
   | 
[...erator/blocks/results/AggregationResultsBlock.java](https://app.codecov.io/gh/apache/pinot/pull/13354?src=pr=tree=pinot-core%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fpinot%2Fcore%2Foperator%2Fblocks%2Fresults%2FAggregationResultsBlock.java_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache#diff-cGlub3QtY29yZS9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvcGlub3QvY29yZS9vcGVyYXRvci9ibG9ja3MvcmVzdWx0cy9BZ2dyZWdhdGlvblJlc3VsdHNCbG9jay5qYXZh)
 | 0.00% | [23 Missing :warning: 
](https://app.codecov.io/gh/apache/pinot/pull/13354?src=pr=tree_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 |
   | 
[.../pinot/query/runtime/operator/utils/TypeUtils.java](https://app.codecov.io/gh/apache/pinot/pull/13354?src=pr=tree=pinot-query-runtime%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fpinot%2Fquery%2Fruntime%2Foperator%2Futils%2FTypeUtils.java_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache#diff-cGlub3QtcXVlcnktcnVudGltZS9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvcGlub3QvcXVlcnkvcnVudGltZS9vcGVyYXRvci91dGlscy9UeXBlVXRpbHMuamF2YQ==)
 | 0.00% | [18 Missing :warning: 
](https://app.codecov.io/gh/apache/pinot/pull/13354?src=pr=tree_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 |
   | 
[...java/org/apache/pinot/common/utils/DataSchema.java](https://app.codecov.io/gh/apache/pinot/pull/13354?src=pr=tree=pinot-common%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fpinot%2Fcommon%2Futils%2FDataSchema.java_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache#diff-cGlub3QtY29tbW9uL3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9waW5vdC9jb21tb24vdXRpbHMvRGF0YVNjaGVtYS5qYXZh)
 | 0.00% | [4 Missing :warning: 
](https://app.codecov.io/gh/apache/pinot/pull/13354?src=pr=tree_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 |
   | 
[...egation/function/HistogramAggregationFunction.java](https://app.codecov.io/gh/apache/pinot/pull/13354?src=pr=tree=pinot-core%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fpinot%2Fcore%2Fquery%2Faggregation%2Ffunction%2FHistogramAggregationFunction.java_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache#diff-cGlub3QtY29yZS9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvcGlub3QvY29yZS9xdWVyeS9hZ2dyZWdhdGlvbi9mdW5jdGlvbi9IaXN0b2dyYW1BZ2dyZWdhdGlvbkZ1bmN0aW9uLmphdmE=)
 | 0.00% | [1 Missing :warning: 
](https://app.codecov.io/gh/apache/pinot/pull/13354?src=pr=tree_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 |
   
   Additional details and impacted files
   
   
   ```diff
   @@  Coverage Diff  @@
   ## master   #13354   +/-   ##
   =
   - Coverage 61.75%0.00%   -61.76% 
   =
 Files  2436 2472   +36 
 Lines133233   136315 +3082 
 Branches  2063621179  +543 
   =
   - Hits  822740-82274 
   - Misses44911   136315+91404 
   + Partials   60480 -6048 
   ```
   
   | 

(pinot) branch master updated: extend CompactedPinotSegmentRecordReader so that it can skip deleteRecord (#13352)

2024-06-10 Thread xbli
This is an automated email from the ASF dual-hosted git repository.

xbli pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/pinot.git


The following commit(s) were added to refs/heads/master by this push:
 new b371feb933 extend CompactedPinotSegmentRecordReader so that it can 
skip deleteRecord (#13352)
b371feb933 is described below

commit b371feb933036b92a1400a8dc7b4dc7f2f739ea8
Author: Xiaobing <61892277+klsi...@users.noreply.github.com>
AuthorDate: Mon Jun 10 15:50:36 2024 -0700

extend CompactedPinotSegmentRecordReader so that it can skip deleteRecord 
(#13352)

* extend CompactedPinotSegmentRecordReader so that it can skip deleteRecord
---
 .../util/ServerSegmentMetadataReader.java  |  6 +--
 .../pinot/plugin/minion/tasks/MinionTaskUtils.java | 12 +++---
 .../readers/CompactedPinotSegmentRecordReader.java | 23 ---
 .../CompactedPinotSegmentRecordReaderTest.java | 47 +-
 4 files changed, 73 insertions(+), 15 deletions(-)

diff --git 
a/pinot-controller/src/main/java/org/apache/pinot/controller/util/ServerSegmentMetadataReader.java
 
b/pinot-controller/src/main/java/org/apache/pinot/controller/util/ServerSegmentMetadataReader.java
index dcca712af4..08b8b2d71e 100644
--- 
a/pinot-controller/src/main/java/org/apache/pinot/controller/util/ServerSegmentMetadataReader.java
+++ 
b/pinot-controller/src/main/java/org/apache/pinot/controller/util/ServerSegmentMetadataReader.java
@@ -265,7 +265,7 @@ public class ServerSegmentMetadataReader {
 List validDocIdsMetadataInfoList =
 JsonUtils.stringToObject(validDocIdsMetadataList, new 
TypeReference>() {
 });
-for (ValidDocIdsMetadataInfo validDocIdsMetadataInfo: 
validDocIdsMetadataInfoList) {
+for (ValidDocIdsMetadataInfo validDocIdsMetadataInfo : 
validDocIdsMetadataInfoList) {
   
validDocIdsMetadataInfos.put(validDocIdsMetadataInfo.getSegmentName(), 
validDocIdsMetadataInfo);
 }
 returnedServerRequestsCount++;
@@ -286,8 +286,8 @@ public class ServerSegmentMetadataReader {
 }
 
 if (segmentNames != null && !segmentNames.isEmpty() && segmentNames.size() 
!= validDocIdsMetadataInfos.size()) {
-  LOGGER.error("Unable to get validDocIdsMetadata for all segments. 
Expected: {}, Actual: {}",
-  segmentNames.size(), validDocIdsMetadataInfos.size());
+  LOGGER.error("Unable to get validDocIdsMetadata for all segments. 
Expected: {}, Actual: {}", segmentNames.size(),
+  validDocIdsMetadataInfos.size());
 }
 
 LOGGER.info("Retrieved validDocIds metadata for {} segments from {} server 
requests.",
diff --git 
a/pinot-plugins/pinot-minion-tasks/pinot-minion-builtin-tasks/src/main/java/org/apache/pinot/plugin/minion/tasks/MinionTaskUtils.java
 
b/pinot-plugins/pinot-minion-tasks/pinot-minion-builtin-tasks/src/main/java/org/apache/pinot/plugin/minion/tasks/MinionTaskUtils.java
index 25e562283e..a827b9fc45 100644
--- 
a/pinot-plugins/pinot-minion-tasks/pinot-minion-builtin-tasks/src/main/java/org/apache/pinot/plugin/minion/tasks/MinionTaskUtils.java
+++ 
b/pinot-plugins/pinot-minion-tasks/pinot-minion-builtin-tasks/src/main/java/org/apache/pinot/plugin/minion/tasks/MinionTaskUtils.java
@@ -94,8 +94,8 @@ public class MinionTaskUtils {
   String pushMode = IngestionConfigUtils.getPushMode(taskConfigs);
 
   Map singleFileGenerationTaskConfig = new 
HashMap<>(taskConfigs);
-  if (pushMode == null
-  || 
pushMode.toUpperCase().contentEquals(BatchConfigProperties.SegmentPushType.TAR.toString()))
 {
+  if (pushMode == null || pushMode.toUpperCase()
+  
.contentEquals(BatchConfigProperties.SegmentPushType.TAR.toString())) {
 singleFileGenerationTaskConfig.put(BatchConfigProperties.PUSH_MODE,
 BatchConfigProperties.SegmentPushType.TAR.toString());
   } else {
@@ -158,7 +158,7 @@ public class MinionTaskUtils {
   ServerSegmentMetadataReader serverSegmentMetadataReader = new 
ServerSegmentMetadataReader();
   try {
 return 
serverSegmentMetadataReader.getValidDocIdsBitmapFromServer(tableNameWithType, 
segmentName, endpoint,
-validDocIdsType, 60_000);
+validDocIdsType, 60_000);
   } catch (Exception e) {
 LOGGER.info("Unable to retrieve validDocIdsBitmap for {} from {}", 
segmentName, endpoint);
   }
@@ -167,7 +167,7 @@ public class MinionTaskUtils {
   }
 
   public static List getServers(String segmentName, String 
tableNameWithType, HelixAdmin helixAdmin,
-String clusterName) {
+  String clusterName) {
 ExternalView externalView = 
helixAdmin.getResourceExternalView(clusterName, tableNameWithType);
 if (externalView == null) {
   throw new IllegalStateException("External view does not exist for table: 
" + tableNameWithType);
@@ -197,8 +197,8 @@ public class MinionTaskUtils {
 if (tableTaskConfig != null) {
  

Re: [PR] extend CompactedPinotSegmentRecordReader so that it can skip deleteRecord [pinot]

2024-06-10 Thread via GitHub


klsince merged PR #13352:
URL: https://github.com/apache/pinot/pull/13352


-- 
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: commits-unsubscr...@pinot.apache.org

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


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



Re: [PR] extend CompactedPinotSegmentRecordReader so that it can skip deleteRecord [pinot]

2024-06-10 Thread via GitHub


codecov-commenter commented on PR #13352:
URL: https://github.com/apache/pinot/pull/13352#issuecomment-2159431626

   ## 
[Codecov](https://app.codecov.io/gh/apache/pinot/pull/13352?dropdown=coverage=pr=h1_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 Report
   Attention: Patch coverage is `0%` with `15 lines` in your changes missing 
coverage. Please review.
   > Project coverage is 0.00%. Comparing base 
[(`59551e4`)](https://app.codecov.io/gh/apache/pinot/commit/59551e45224f1535c4863fd577622b37366ccc97?dropdown=coverage=desc_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 to head 
[(`a7cfccd`)](https://app.codecov.io/gh/apache/pinot/commit/a7cfccd54c9a67f97d415952bcafafa9b46bf8e0?dropdown=coverage=desc_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache).
   > Report is 595 commits behind head on master.
   
   | 
[Files](https://app.codecov.io/gh/apache/pinot/pull/13352?dropdown=coverage=pr=tree_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | Patch % | Lines |
   |---|---|---|
   | 
[...ent/readers/CompactedPinotSegmentRecordReader.java](https://app.codecov.io/gh/apache/pinot/pull/13352?src=pr=tree=pinot-segment-local%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fpinot%2Fsegment%2Flocal%2Fsegment%2Freaders%2FCompactedPinotSegmentRecordReader.java_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache#diff-cGlub3Qtc2VnbWVudC1sb2NhbC9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvcGlub3Qvc2VnbWVudC9sb2NhbC9zZWdtZW50L3JlYWRlcnMvQ29tcGFjdGVkUGlub3RTZWdtZW50UmVjb3JkUmVhZGVyLmphdmE=)
 | 0.00% | [8 Missing :warning: 
](https://app.codecov.io/gh/apache/pinot/pull/13352?src=pr=tree_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 |
   | 
[...che/pinot/plugin/minion/tasks/MinionTaskUtils.java](https://app.codecov.io/gh/apache/pinot/pull/13352?src=pr=tree=pinot-plugins%2Fpinot-minion-tasks%2Fpinot-minion-builtin-tasks%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fpinot%2Fplugin%2Fminion%2Ftasks%2FMinionTaskUtils.java_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache#diff-cGlub3QtcGx1Z2lucy9waW5vdC1taW5pb24tdGFza3MvcGlub3QtbWluaW9uLWJ1aWx0aW4tdGFza3Mvc3JjL21haW4vamF2YS9vcmcvYXBhY2hlL3Bpbm90L3BsdWdpbi9taW5pb24vdGFza3MvTWluaW9uVGFza1V0aWxzLmphdmE=)
 | 0.00% | [4 Missing :warning: 
](https://app.codecov.io/gh/apache/pinot/pull/13352?src=pr=tree_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 |
   | 
[...t/controller/util/ServerSegmentMetadataReader.java](https://app.codecov.io/gh/apache/pinot/pull/13352?src=pr=tree=pinot-controller%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fpinot%2Fcontroller%2Futil%2FServerSegmentMetadataReader.java_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache#diff-cGlub3QtY29udHJvbGxlci9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvcGlub3QvY29udHJvbGxlci91dGlsL1NlcnZlclNlZ21lbnRNZXRhZGF0YVJlYWRlci5qYXZh)
 | 0.00% | [3 Missing :warning: 
](https://app.codecov.io/gh/apache/pinot/pull/13352?src=pr=tree_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 |
   
   Additional details and impacted files
   
   
   ```diff
   @@  Coverage Diff  @@
   ## master   #13352   +/-   ##
   =
   - Coverage 61.75%0.00%   -61.76% 
   =
 Files  2436 2472   +36 
 Lines133233   136248 +3015 
 Branches  2063621160  +524 
   =
   - Hits  822740-82274 
   - Misses44911   136248+91337 
   + Partials   60480 -6048 
   ```
   
   | 
[Flag](https://app.codecov.io/gh/apache/pinot/pull/13352/flags?src=pr=flags_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | Coverage Δ | |
   |---|---|---|
   | 
[custom-integration1](https://app.codecov.io/gh/apache/pinot/pull/13352/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `?` | |
   | 
[integration](https://app.codecov.io/gh/apache/pinot/pull/13352/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `0.00% <0.00%> (-0.01%)` | :arrow_down: |
   | 
[integration1](https://app.codecov.io/gh/apache/pinot/pull/13352/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `?` | |
   | 
[integration2](https://app.codecov.io/gh/apache/pinot/pull/13352/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `0.00% <0.00%> (ø)` | |
   | 
[java-11](https://app.codecov.io/gh/apache/pinot/pull/13352/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `0.00% <0.00%> 

Re: [PR] move shouldReplaceOnComparisonTie to base class to be more reusable [pinot]

2024-06-10 Thread via GitHub


klsince commented on PR #13353:
URL: https://github.com/apache/pinot/pull/13353#issuecomment-2159424750

   cc @rohityadav1993


-- 
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: commits-unsubscr...@pinot.apache.org

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


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



[PR] move shouldReplaceOnComparisonTie to base class to be more reusable [pinot]

2024-06-10 Thread via GitHub


klsince opened a new pull request, #13353:
URL: https://github.com/apache/pinot/pull/13353

   no new changes added, but moved shouldReplaceOnComparisonTie() method to 
base class to make it more reusable in other subclasses 


-- 
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: commits-unsubscr...@pinot.apache.org

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


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



Re: [I] Null Pointer Exception in arrayagg function with empty column data [pinot]

2024-06-10 Thread via GitHub


Jackie-Jiang commented on issue #13343:
URL: https://github.com/apache/pinot/issues/13343#issuecomment-2159410270

   cc @xiangfu0 


-- 
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: commits-unsubscr...@pinot.apache.org

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


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



(pinot) branch master updated: Adding a cluster config to enable instance pool and replica group configuration in table config (#13131)

2024-06-10 Thread jackie
This is an automated email from the ASF dual-hosted git repository.

jackie pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/pinot.git


The following commit(s) were added to refs/heads/master by this push:
 new 425182f438 Adding a cluster config to enable instance pool and replica 
group configuration in table config (#13131)
425182f438 is described below

commit 425182f438094be570740e617ff6274416469ec6
Author: soumitra-st <127247229+soumitra...@users.noreply.github.com>
AuthorDate: Mon Jun 10 15:20:55 2024 -0700

Adding a cluster config to enable instance pool and replica group 
configuration in table config (#13131)
---
 .../pinot/controller/BaseControllerStarter.java|   4 +
 .../apache/pinot/controller/ControllerConf.java|   7 ++
 .../api/resources/PinotTableRestletResource.java   |   6 +-
 .../api/resources/TableConfigsRestletResource.java |   4 +-
 .../segment/local/utils/TableConfigUtils.java  |  68 ---
 .../segment/local/utils/TableConfigUtilsTest.java  | 125 -
 6 files changed, 192 insertions(+), 22 deletions(-)

diff --git 
a/pinot-controller/src/main/java/org/apache/pinot/controller/BaseControllerStarter.java
 
b/pinot-controller/src/main/java/org/apache/pinot/controller/BaseControllerStarter.java
index ea79125277..9fc7d99268 100644
--- 
a/pinot-controller/src/main/java/org/apache/pinot/controller/BaseControllerStarter.java
+++ 
b/pinot-controller/src/main/java/org/apache/pinot/controller/BaseControllerStarter.java
@@ -113,6 +113,7 @@ import 
org.apache.pinot.core.query.executor.sql.SqlQueryExecutor;
 import 
org.apache.pinot.core.segment.processing.lifecycle.PinotSegmentLifecycleEventListenerManager;
 import org.apache.pinot.core.transport.ListenerConfig;
 import org.apache.pinot.core.util.ListenerConfigUtil;
+import org.apache.pinot.segment.local.utils.TableConfigUtils;
 import org.apache.pinot.spi.config.table.TableConfig;
 import org.apache.pinot.spi.crypt.PinotCrypterFactory;
 import org.apache.pinot.spi.data.Schema;
@@ -253,6 +254,9 @@ public abstract class BaseControllerStarter implements 
ServiceStartable {
 
 // Initialize the table config tuner registry.
 TableConfigTunerRegistry.init(_config.getTableConfigTunerPackages());
+
+TableConfigUtils.setDisableGroovy(_config.isDisableIngestionGroovy());
+
TableConfigUtils.setEnforcePoolBasedAssignment(_config.isEnforcePoolBasedAssignmentEnabled());
   }
 
   private void inferHostnameIfNeeded(ControllerConf config) {
diff --git 
a/pinot-controller/src/main/java/org/apache/pinot/controller/ControllerConf.java
 
b/pinot-controller/src/main/java/org/apache/pinot/controller/ControllerConf.java
index 4598b48eeb..1ae79f565a 100644
--- 
a/pinot-controller/src/main/java/org/apache/pinot/controller/ControllerConf.java
+++ 
b/pinot-controller/src/main/java/org/apache/pinot/controller/ControllerConf.java
@@ -316,6 +316,9 @@ public class ControllerConf extends PinotConfiguration {
   public static final String DISABLE_GROOVY = 
"controller.disable.ingestion.groovy";
   public static final boolean DEFAULT_DISABLE_GROOVY = true;
 
+  public static final String ENFORCE_POOL_BASED_ASSIGNMENT_KEY = 
"enforce.pool.based.assignment";
+  public static final boolean DEFAULT_ENFORCE_POOL_BASED_ASSIGNMENT = false;
+
   public ControllerConf() {
 super(new HashMap<>());
   }
@@ -1065,4 +1068,8 @@ public class ControllerConf extends PinotConfiguration {
 Preconditions.checkArgument(SUPPORTED_PROTOCOLS.contains(value), 
"Unsupported %s protocol '%s'", property, value);
 return value;
   }
+
+  public boolean isEnforcePoolBasedAssignmentEnabled() {
+return getProperty(ENFORCE_POOL_BASED_ASSIGNMENT_KEY, 
DEFAULT_ENFORCE_POOL_BASED_ASSIGNMENT);
+  }
 }
diff --git 
a/pinot-controller/src/main/java/org/apache/pinot/controller/api/resources/PinotTableRestletResource.java
 
b/pinot-controller/src/main/java/org/apache/pinot/controller/api/resources/PinotTableRestletResource.java
index 59e748a08f..c2ba66dc34 100644
--- 
a/pinot-controller/src/main/java/org/apache/pinot/controller/api/resources/PinotTableRestletResource.java
+++ 
b/pinot-controller/src/main/java/org/apache/pinot/controller/api/resources/PinotTableRestletResource.java
@@ -229,7 +229,7 @@ public class PinotTableRestletResource {
   TableConfigTunerUtils.applyTunerConfigs(_pinotHelixResourceManager, 
tableConfig, schema, Collections.emptyMap());
 
   // TableConfigUtils.validate(...) is used across table create/update.
-  TableConfigUtils.validate(tableConfig, schema, typesToSkip, 
_controllerConf.isDisableIngestionGroovy());
+  TableConfigUtils.validate(tableConfig, schema, typesToSkip);
   TableConfigUtils.validateTableName(tableConfig);
 } catch (Exception e) {
   throw new ControllerApplicationException(LOGGER, e.getMessage(), 
Response.Status.BAD_REQUEST, e);
@@ -498,7 +498,7 @@ public class PinotTableRestletResource {
   }
 
   Schema schema = 

Re: [PR] Adding a cluster config to enable instance pool and replica group configuration in table config [pinot]

2024-06-10 Thread via GitHub


Jackie-Jiang merged PR #13131:
URL: https://github.com/apache/pinot/pull/13131


-- 
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: commits-unsubscr...@pinot.apache.org

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


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



Re: [PR] Adding a cluster config to enable instance pool and replica group configuration in table config [pinot]

2024-06-10 Thread via GitHub


Jackie-Jiang commented on PR #13131:
URL: https://github.com/apache/pinot/pull/13131#issuecomment-2159405446

   Good job! Please also update the pinot doc about the new config


-- 
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: commits-unsubscr...@pinot.apache.org

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


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



[PR] extend CompactedPinotSegmentRecordReader so that it can skip deleteRecord [pinot]

2024-06-10 Thread via GitHub


klsince opened a new pull request, #13352:
URL: https://github.com/apache/pinot/pull/13352

   Extend CompactedPinotSegmentRecordReader so that it can skip deleteRecord if 
configured. 
   
   Note that dropping deleteRecord too soon may cause the old soft-deleted 
record to show up unexpectedly, so one should be careful when to skip the 
deleteRecord. e.g. tombstones from segments older than certain threshold may be 
dropped safely.


-- 
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: commits-unsubscr...@pinot.apache.org

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


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



(pinot) branch master updated: Revert "support deleteColumn for compactionTask by extending the record reader (#13342)" (#13351)

2024-06-10 Thread xbli
This is an automated email from the ASF dual-hosted git repository.

xbli pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/pinot.git


The following commit(s) were added to refs/heads/master by this push:
 new e825e13978 Revert "support deleteColumn for compactionTask by 
extending the record reader (#13342)" (#13351)
e825e13978 is described below

commit e825e139787bc3f6e460f4b7cb1b390e8fd1dfc1
Author: Xiaobing <61892277+klsi...@users.noreply.github.com>
AuthorDate: Mon Jun 10 14:33:41 2024 -0700

Revert "support deleteColumn for compactionTask by extending the record 
reader (#13342)" (#13351)

This reverts commit caf25238f4166a8b5fbddaab64dc3df9a99a6275.
---
 .../util/ServerSegmentMetadataReader.java  |  6 +--
 .../pinot/plugin/minion/tasks/MinionTaskUtils.java | 12 +++---
 .../UpsertCompactionTaskExecutor.java  |  2 +-
 .../readers/CompactedPinotSegmentRecordReader.java | 20 +++--
 .../CompactedPinotSegmentRecordReaderTest.java | 47 +-
 5 files changed, 16 insertions(+), 71 deletions(-)

diff --git 
a/pinot-controller/src/main/java/org/apache/pinot/controller/util/ServerSegmentMetadataReader.java
 
b/pinot-controller/src/main/java/org/apache/pinot/controller/util/ServerSegmentMetadataReader.java
index 08b8b2d71e..dcca712af4 100644
--- 
a/pinot-controller/src/main/java/org/apache/pinot/controller/util/ServerSegmentMetadataReader.java
+++ 
b/pinot-controller/src/main/java/org/apache/pinot/controller/util/ServerSegmentMetadataReader.java
@@ -265,7 +265,7 @@ public class ServerSegmentMetadataReader {
 List validDocIdsMetadataInfoList =
 JsonUtils.stringToObject(validDocIdsMetadataList, new 
TypeReference>() {
 });
-for (ValidDocIdsMetadataInfo validDocIdsMetadataInfo : 
validDocIdsMetadataInfoList) {
+for (ValidDocIdsMetadataInfo validDocIdsMetadataInfo: 
validDocIdsMetadataInfoList) {
   
validDocIdsMetadataInfos.put(validDocIdsMetadataInfo.getSegmentName(), 
validDocIdsMetadataInfo);
 }
 returnedServerRequestsCount++;
@@ -286,8 +286,8 @@ public class ServerSegmentMetadataReader {
 }
 
 if (segmentNames != null && !segmentNames.isEmpty() && segmentNames.size() 
!= validDocIdsMetadataInfos.size()) {
-  LOGGER.error("Unable to get validDocIdsMetadata for all segments. 
Expected: {}, Actual: {}", segmentNames.size(),
-  validDocIdsMetadataInfos.size());
+  LOGGER.error("Unable to get validDocIdsMetadata for all segments. 
Expected: {}, Actual: {}",
+  segmentNames.size(), validDocIdsMetadataInfos.size());
 }
 
 LOGGER.info("Retrieved validDocIds metadata for {} segments from {} server 
requests.",
diff --git 
a/pinot-plugins/pinot-minion-tasks/pinot-minion-builtin-tasks/src/main/java/org/apache/pinot/plugin/minion/tasks/MinionTaskUtils.java
 
b/pinot-plugins/pinot-minion-tasks/pinot-minion-builtin-tasks/src/main/java/org/apache/pinot/plugin/minion/tasks/MinionTaskUtils.java
index a827b9fc45..25e562283e 100644
--- 
a/pinot-plugins/pinot-minion-tasks/pinot-minion-builtin-tasks/src/main/java/org/apache/pinot/plugin/minion/tasks/MinionTaskUtils.java
+++ 
b/pinot-plugins/pinot-minion-tasks/pinot-minion-builtin-tasks/src/main/java/org/apache/pinot/plugin/minion/tasks/MinionTaskUtils.java
@@ -94,8 +94,8 @@ public class MinionTaskUtils {
   String pushMode = IngestionConfigUtils.getPushMode(taskConfigs);
 
   Map singleFileGenerationTaskConfig = new 
HashMap<>(taskConfigs);
-  if (pushMode == null || pushMode.toUpperCase()
-  
.contentEquals(BatchConfigProperties.SegmentPushType.TAR.toString())) {
+  if (pushMode == null
+  || 
pushMode.toUpperCase().contentEquals(BatchConfigProperties.SegmentPushType.TAR.toString()))
 {
 singleFileGenerationTaskConfig.put(BatchConfigProperties.PUSH_MODE,
 BatchConfigProperties.SegmentPushType.TAR.toString());
   } else {
@@ -158,7 +158,7 @@ public class MinionTaskUtils {
   ServerSegmentMetadataReader serverSegmentMetadataReader = new 
ServerSegmentMetadataReader();
   try {
 return 
serverSegmentMetadataReader.getValidDocIdsBitmapFromServer(tableNameWithType, 
segmentName, endpoint,
-validDocIdsType, 60_000);
+validDocIdsType, 60_000);
   } catch (Exception e) {
 LOGGER.info("Unable to retrieve validDocIdsBitmap for {} from {}", 
segmentName, endpoint);
   }
@@ -167,7 +167,7 @@ public class MinionTaskUtils {
   }
 
   public static List getServers(String segmentName, String 
tableNameWithType, HelixAdmin helixAdmin,
-  String clusterName) {
+String clusterName) {
 ExternalView externalView = 
helixAdmin.getResourceExternalView(clusterName, tableNameWithType);
 if (externalView == null) {
   throw new IllegalStateException("External view does not exist for table: 
" + tableNameWithType);
@@ -197,8 +197,8 

Re: [PR] Revert "support deleteColumn for compactionTask by extending the record reader [pinot]

2024-06-10 Thread via GitHub


klsince merged PR #13351:
URL: https://github.com/apache/pinot/pull/13351


-- 
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: commits-unsubscr...@pinot.apache.org

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


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



Re: [PR] Revert "support deleteColumn for compactionTask by extending the record reader [pinot]

2024-06-10 Thread via GitHub


klsince commented on PR #13351:
URL: https://github.com/apache/pinot/pull/13351#issuecomment-2159321440

   > (minor) We might want to keep the first 2 files unchanged since we are 
reverting some valid formatting change 
   
   Will keep this PR as a pure revert PR. and I'll open another PR for this, 
and will include the extension for the CompactedPinotSegmentRecordReader, as 
there are cases we'd know it's safe to skip 'delete record'.


-- 
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: commits-unsubscr...@pinot.apache.org

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


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



Re: [PR] Support array sum aggregation function [pinot]

2024-06-10 Thread via GitHub


xiangfu0 commented on code in PR #13324:
URL: https://github.com/apache/pinot/pull/13324#discussion_r1633842707


##
pinot-core/src/main/java/org/apache/pinot/core/query/aggregation/function/array/SumArrayDoubleAggregationFunction.java:
##
@@ -0,0 +1,155 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.pinot.core.query.aggregation.function.array;
+
+import it.unimi.dsi.fastutil.doubles.DoubleArrayList;
+import java.util.List;
+import java.util.Map;
+import org.apache.pinot.common.request.context.ExpressionContext;
+import org.apache.pinot.common.utils.DataSchema;
+import org.apache.pinot.core.common.BlockValSet;
+import org.apache.pinot.core.query.aggregation.AggregationResultHolder;
+import org.apache.pinot.core.query.aggregation.ObjectAggregationResultHolder;
+import 
org.apache.pinot.core.query.aggregation.function.BaseSingleInputAggregationFunction;
+import org.apache.pinot.core.query.aggregation.groupby.GroupByResultHolder;
+import 
org.apache.pinot.core.query.aggregation.groupby.ObjectGroupByResultHolder;
+import org.apache.pinot.segment.spi.AggregationFunctionType;
+
+
+public class SumArrayDoubleAggregationFunction
+extends BaseSingleInputAggregationFunction {

Review Comment:
   Added.



-- 
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: commits-unsubscr...@pinot.apache.org

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


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



Re: [PR] Revert "support deleteColumn for compactionTask by extending the record reader [pinot]

2024-06-10 Thread via GitHub


codecov-commenter commented on PR #13351:
URL: https://github.com/apache/pinot/pull/13351#issuecomment-2159196572

   ## 
[Codecov](https://app.codecov.io/gh/apache/pinot/pull/13351?dropdown=coverage=pr=h1_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 Report
   Attention: Patch coverage is `0%` with `9 lines` in your changes missing 
coverage. Please review.
   > Project coverage is 0.00%. Comparing base 
[(`59551e4`)](https://app.codecov.io/gh/apache/pinot/commit/59551e45224f1535c4863fd577622b37366ccc97?dropdown=coverage=desc_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 to head 
[(`be67b22`)](https://app.codecov.io/gh/apache/pinot/commit/be67b2243d13e5e24fc4e643b9eaa265f619e5a3?dropdown=coverage=desc_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache).
   > Report is 593 commits behind head on master.
   
   | 
[Files](https://app.codecov.io/gh/apache/pinot/pull/13351?dropdown=coverage=pr=tree_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | Patch % | Lines |
   |---|---|---|
   | 
[...che/pinot/plugin/minion/tasks/MinionTaskUtils.java](https://app.codecov.io/gh/apache/pinot/pull/13351?src=pr=tree=pinot-plugins%2Fpinot-minion-tasks%2Fpinot-minion-builtin-tasks%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fpinot%2Fplugin%2Fminion%2Ftasks%2FMinionTaskUtils.java_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache#diff-cGlub3QtcGx1Z2lucy9waW5vdC1taW5pb24tdGFza3MvcGlub3QtbWluaW9uLWJ1aWx0aW4tdGFza3Mvc3JjL21haW4vamF2YS9vcmcvYXBhY2hlL3Bpbm90L3BsdWdpbi9taW5pb24vdGFza3MvTWluaW9uVGFza1V0aWxzLmphdmE=)
 | 0.00% | [4 Missing :warning: 
](https://app.codecov.io/gh/apache/pinot/pull/13351?src=pr=tree_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 |
   | 
[...t/controller/util/ServerSegmentMetadataReader.java](https://app.codecov.io/gh/apache/pinot/pull/13351?src=pr=tree=pinot-controller%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fpinot%2Fcontroller%2Futil%2FServerSegmentMetadataReader.java_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache#diff-cGlub3QtY29udHJvbGxlci9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvcGlub3QvY29udHJvbGxlci91dGlsL1NlcnZlclNlZ21lbnRNZXRhZGF0YVJlYWRlci5qYXZh)
 | 0.00% | [3 Missing :warning: 
](https://app.codecov.io/gh/apache/pinot/pull/13351?src=pr=tree_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 |
   | 
[...ent/readers/CompactedPinotSegmentRecordReader.java](https://app.codecov.io/gh/apache/pinot/pull/13351?src=pr=tree=pinot-segment-local%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fpinot%2Fsegment%2Flocal%2Fsegment%2Freaders%2FCompactedPinotSegmentRecordReader.java_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache#diff-cGlub3Qtc2VnbWVudC1sb2NhbC9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvcGlub3Qvc2VnbWVudC9sb2NhbC9zZWdtZW50L3JlYWRlcnMvQ29tcGFjdGVkUGlub3RTZWdtZW50UmVjb3JkUmVhZGVyLmphdmE=)
 | 0.00% | [2 Missing :warning: 
](https://app.codecov.io/gh/apache/pinot/pull/13351?src=pr=tree_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 |
   
   Additional details and impacted files
   
   
   ```diff
   @@  Coverage Diff  @@
   ## master   #13351   +/-   ##
   =
   - Coverage 61.75%0.00%   -61.76% 
   =
 Files  2436 2472   +36 
 Lines133233   136241 +3008 
 Branches  2063621159  +523 
   =
   - Hits  822740-82274 
   - Misses44911   136241+91330 
   + Partials   60480 -6048 
   ```
   
   | 
[Flag](https://app.codecov.io/gh/apache/pinot/pull/13351/flags?src=pr=flags_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | Coverage Δ | |
   |---|---|---|
   | 
[custom-integration1](https://app.codecov.io/gh/apache/pinot/pull/13351/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `?` | |
   | 
[integration](https://app.codecov.io/gh/apache/pinot/pull/13351/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `0.00% <0.00%> (-0.01%)` | :arrow_down: |
   | 
[integration1](https://app.codecov.io/gh/apache/pinot/pull/13351/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `?` | |
   | 
[integration2](https://app.codecov.io/gh/apache/pinot/pull/13351/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `0.00% <0.00%> (ø)` | |
   | 
[java-11](https://app.codecov.io/gh/apache/pinot/pull/13351/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `0.00% <0.00%> 

[PR] Revert "support deleteColumn for compactionTask by extending the record reader [pinot]

2024-06-10 Thread via GitHub


klsince opened a new pull request, #13351:
URL: https://github.com/apache/pinot/pull/13351

   As analyzed in https://github.com/apache/pinot/pull/13347, it's not right to 
drop 'delete record' in compaction task, as that'd remove 'delete record' too 
soon, making the deleted records in older segments to be visible to queries 
again under some cases, e.g. when the server has to load old segments w/o the 
valid doc snapshots


-- 
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: commits-unsubscr...@pinot.apache.org

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


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



(pinot) branch master updated: Fix URI construction so that AddSchema command line tool works when override flag is set to true (#13320)

2024-06-10 Thread jackie
This is an automated email from the ASF dual-hosted git repository.

jackie pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/pinot.git


The following commit(s) were added to refs/heads/master by this push:
 new 5fc9bf60bd Fix URI construction so that AddSchema command line tool 
works when override flag is set to true (#13320)
5fc9bf60bd is described below

commit 5fc9bf60bdc1c63e0204627a625dce6e1be4b6d4
Author: Suyash Patel 
AuthorDate: Mon Jun 10 12:05:41 2024 -0700

Fix URI construction so that AddSchema command line tool works when 
override flag is set to true (#13320)
---
 .../java/org/apache/pinot/tools/admin/command/AddSchemaCommand.java | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git 
a/pinot-tools/src/main/java/org/apache/pinot/tools/admin/command/AddSchemaCommand.java
 
b/pinot-tools/src/main/java/org/apache/pinot/tools/admin/command/AddSchemaCommand.java
index b777646c45..10c7e92e7b 100644
--- 
a/pinot-tools/src/main/java/org/apache/pinot/tools/admin/command/AddSchemaCommand.java
+++ 
b/pinot-tools/src/main/java/org/apache/pinot/tools/admin/command/AddSchemaCommand.java
@@ -177,7 +177,7 @@ public class AddSchemaCommand extends 
AbstractBaseAdminCommand implements Comman
 try (FileUploadDownloadClient fileUploadDownloadClient = new 
FileUploadDownloadClient()) {
   URI schemaURI = FileUploadDownloadClient
   .getUploadSchemaURI(_controllerProtocol, _controllerHost, 
Integer.parseInt(_controllerPort));
-  schemaURI = new URI(schemaURI + "?override=" + _override + "?force=" + 
_force);
+  schemaURI = new URI(schemaURI + "?override=" + _override + "=" + 
_force);
   fileUploadDownloadClient.addSchema(schemaURI,
   schema.getSchemaName(), schemaFile, 
AuthProviderUtils.makeAuthHeaders(
   AuthProviderUtils.makeAuthProvider(_authProvider, _authTokenUrl, 
_authToken,


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



Re: [PR] [Bug fix] Fix URI construction so that AddSchema command line tool works [pinot]

2024-06-10 Thread via GitHub


Jackie-Jiang merged PR #13320:
URL: https://github.com/apache/pinot/pull/13320


-- 
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: commits-unsubscr...@pinot.apache.org

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


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



Re: [I] Data ingestion CPU efficiency improvements [pinot]

2024-06-10 Thread via GitHub


Jackie-Jiang commented on issue #13319:
URL: https://github.com/apache/pinot/issues/13319#issuecomment-2159097713

   Good findings! Let's first check if there are some low hanging fruit 
optimizations.
   cc @swaminathanmanish 


-- 
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: commits-unsubscr...@pinot.apache.org

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


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



Re: [PR] do not fail on duplicate relaxed vars [pinot]

2024-06-10 Thread via GitHub


Jackie-Jiang merged PR #13214:
URL: https://github.com/apache/pinot/pull/13214


-- 
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: commits-unsubscr...@pinot.apache.org

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


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



(pinot) branch master updated: do not fail on duplicate relaxed vars (#13214)

2024-06-10 Thread jackie
This is an automated email from the ASF dual-hosted git repository.

jackie pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/pinot.git


The following commit(s) were added to refs/heads/master by this push:
 new 49698174ee do not fail on duplicate relaxed vars (#13214)
49698174ee is described below

commit 49698174eea43fbaec331d298da8031db4e4ef03
Author: Johan Adami <4760722+jadam...@users.noreply.github.com>
AuthorDate: Mon Jun 10 15:01:42 2024 -0400

do not fail on duplicate relaxed vars (#13214)
---
 .../apache/pinot/spi/env/PinotConfiguration.java   | 10 ++-
 .../pinot/spi/env/PinotConfigurationTest.java  | 33 ++
 2 files changed, 42 insertions(+), 1 deletion(-)

diff --git 
a/pinot-spi/src/main/java/org/apache/pinot/spi/env/PinotConfiguration.java 
b/pinot-spi/src/main/java/org/apache/pinot/spi/env/PinotConfiguration.java
index 72be975544..8615f61923 100644
--- a/pinot-spi/src/main/java/org/apache/pinot/spi/env/PinotConfiguration.java
+++ b/pinot-spi/src/main/java/org/apache/pinot/spi/env/PinotConfiguration.java
@@ -233,7 +233,15 @@ public class PinotConfiguration {
 
   private static Map relaxEnvironmentVariables(Map environmentVariables) {
 return environmentVariables.entrySet().stream()
-.collect(Collectors.toMap(PinotConfiguration::relaxEnvVarName, 
Entry::getValue));
+// Sort by key to ensure choosing a consistent env var if there are 
collisions
+.sorted(Entry.comparingByKey())
+.collect(Collectors.toMap(
+PinotConfiguration::relaxEnvVarName,
+Entry::getValue,
+// Nothing prevents users from setting env variables like foo_bar 
and foo.bar
+// This should not prevent Pinot from starting.
+(existingValue, newValue) -> existingValue
+));
   }
 
   private static String relaxEnvVarName(Entry envVarEntry) {
diff --git 
a/pinot-spi/src/test/java/org/apache/pinot/spi/env/PinotConfigurationTest.java 
b/pinot-spi/src/test/java/org/apache/pinot/spi/env/PinotConfigurationTest.java
index 1c810dc6ef..02000b746d 100644
--- 
a/pinot-spi/src/test/java/org/apache/pinot/spi/env/PinotConfigurationTest.java
+++ 
b/pinot-spi/src/test/java/org/apache/pinot/spi/env/PinotConfigurationTest.java
@@ -187,6 +187,39 @@ public class PinotConfigurationTest {
 Assert.assertEquals(configuration.getProperty("pinot.controller.host"), 
"test-host");
   }
 
+  @Test
+  public void assertHandlesDuplicateRelaxedKeys()
+  throws IOException {
+Map baseProperties = new HashMap<>();
+Map mockedEnvironmentVariables = new HashMap<>();
+
+String configFile = File.createTempFile("pinot-configuration-test-4", 
".properties").getAbsolutePath();
+
+baseProperties.put("server.host", "ENV_SERVER_HOST");
+baseProperties.put("dynamic.env.config", "server.host");
+
+mockedEnvironmentVariables.put("ENV_SERVER_HOST", "test-server-host-1");
+mockedEnvironmentVariables.put("ENV.SERVER.HOST", "test-server-host-2");
+mockedEnvironmentVariables.put("ENV.SERVER_HOST", "test-server-host-3");
+mockedEnvironmentVariables.put("ENV_SERVER.HOST", "test-server-host-4");
+
+mockedEnvironmentVariables.put("ENV_VAR_HOST", "test-host-1");
+mockedEnvironmentVariables.put("ENV.VAR_HOST", "test-host-2");
+mockedEnvironmentVariables.put("env_var_host", "test-host-3");
+mockedEnvironmentVariables.put("env_var.host", "test-host-4");
+
+// config.paths sorts before config_paths, so we should get the right 
config
+mockedEnvironmentVariables.put("config.paths", 
"classpath:/pinot-configuration-4.properties");
+mockedEnvironmentVariables.put("config_paths", 
"classpath:/does-not-exist-configuration.properties");
+copyClasspathResource("/pinot-configuration-4.properties", configFile);
+
+PinotConfiguration configuration = new PinotConfiguration(baseProperties, 
mockedEnvironmentVariables);
+
+// These are taken from raw and not relaxed values
+Assert.assertEquals(configuration.getProperty("server.host"), 
"test-server-host-1");
+Assert.assertEquals(configuration.getProperty("pinot.controller.host"), 
"test-host-1");
+  }
+
   @Test(expectedExceptions = IllegalArgumentException.class)
   public void assertInvalidConfigPathBehavior() {
 Map baseProperties = new HashMap<>();


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



(pinot) branch master updated: update node version in the docs (#13294)

2024-06-10 Thread jackie
This is an automated email from the ASF dual-hosted git repository.

jackie pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/pinot.git


The following commit(s) were added to refs/heads/master by this push:
 new c5dc885bac update node version in the docs (#13294)
c5dc885bac is described below

commit c5dc885bac72a3d830114836d093bf15e44c39be
Author: Jayesh Choudhary 
AuthorDate: Tue Jun 11 00:26:04 2024 +0530

update node version in the docs (#13294)
---
 README.md | 2 ++
 pinot-controller/src/main/resources/Readme.md | 2 +-
 2 files changed, 3 insertions(+), 1 deletion(-)

diff --git a/README.md b/README.md
index 1e64526341..f39ad1a3b1 100644
--- a/README.md
+++ b/README.md
@@ -102,6 +102,8 @@ $ cd build/
 $ bin/quick-start-batch.sh
 ```
 
+For UI development setup refer this 
[doc](https://github.com/apache/pinot/blob/master/pinot-controller/src/main/resources/Readme.md).
+
 ## Deploying Pinot to Kubernetes
 Please refer to [Running Pinot on 
Kubernetes](https://docs.pinot.apache.org/basics/getting-started/kubernetes-quickstart)
 in our project documentation. Pinot also provides Kubernetes integrations with 
the interactive query engine, 
[Trino](https://docs.pinot.apache.org/integrations/trino) 
[Presto](https://docs.pinot.apache.org/integrations/presto), and the data 
visualization tool, [Apache Superset](kubernetes/helm/superset.yaml).
 
diff --git a/pinot-controller/src/main/resources/Readme.md 
b/pinot-controller/src/main/resources/Readme.md
index e019abc63d..524eb56ff5 100644
--- a/pinot-controller/src/main/resources/Readme.md
+++ b/pinot-controller/src/main/resources/Readme.md
@@ -29,7 +29,7 @@ This package contains code for Pinot Controller UI.
 ```shell
 cd pinot-controller/src/main/resources
 ```
-3. Install Required Packages. Make sure you are using node v14 or more 
specifially v14.18.1
+3. Install Required Packages. Make sure you are using node v16 or more 
specifically v16.15.0
 ```shell
 npm install 
 ```


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



Re: [PR] update node version in the docs [pinot]

2024-06-10 Thread via GitHub


Jackie-Jiang merged PR #13294:
URL: https://github.com/apache/pinot/pull/13294


-- 
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: commits-unsubscr...@pinot.apache.org

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


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



Re: [PR] Bump com.azure:azure-storage-file-datalake from 12.19.0 to 12.19.1 [pinot]

2024-06-10 Thread via GitHub


Jackie-Jiang merged PR #13350:
URL: https://github.com/apache/pinot/pull/13350


-- 
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: commits-unsubscr...@pinot.apache.org

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


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



(pinot) branch dependabot/maven/com.azure-azure-storage-file-datalake-12.19.1 deleted (was 0fbfc38021)

2024-06-10 Thread jackie
This is an automated email from the ASF dual-hosted git repository.

jackie pushed a change to branch 
dependabot/maven/com.azure-azure-storage-file-datalake-12.19.1
in repository https://gitbox.apache.org/repos/asf/pinot.git


 was 0fbfc38021 Bump com.azure:azure-storage-file-datalake from 12.19.0 to 
12.19.1

The revisions that were on this branch are still contained in
other references; therefore, this change does not discard any commits
from the repository.


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



(pinot) branch dependabot/maven/software.amazon.awssdk-bom-2.25.69 deleted (was 3ba73cc3dc)

2024-06-10 Thread jackie
This is an automated email from the ASF dual-hosted git repository.

jackie pushed a change to branch 
dependabot/maven/software.amazon.awssdk-bom-2.25.69
in repository https://gitbox.apache.org/repos/asf/pinot.git


 was 3ba73cc3dc Bump software.amazon.awssdk:bom from 2.25.68 to 2.25.69

The revisions that were on this branch are still contained in
other references; therefore, this change does not discard any commits
from the repository.


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



(pinot) branch master updated (30a7609d09 -> b0f356cfd1)

2024-06-10 Thread jackie
This is an automated email from the ASF dual-hosted git repository.

jackie pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/pinot.git


from 30a7609d09 Bump software.amazon.awssdk:bom from 2.25.68 to 2.25.69 
(#13349)
 add b0f356cfd1 Bump com.azure:azure-storage-file-datalake from 12.19.0 to 
12.19.1 (#13350)

No new revisions were added by this update.

Summary of changes:
 pinot-plugins/pinot-file-system/pinot-adls/pom.xml | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



(pinot) branch master updated: Bump software.amazon.awssdk:bom from 2.25.68 to 2.25.69 (#13349)

2024-06-10 Thread jackie
This is an automated email from the ASF dual-hosted git repository.

jackie pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/pinot.git


The following commit(s) were added to refs/heads/master by this push:
 new 30a7609d09 Bump software.amazon.awssdk:bom from 2.25.68 to 2.25.69 
(#13349)
30a7609d09 is described below

commit 30a7609d0988b55b59b48a805a33057c54a562fe
Author: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
AuthorDate: Mon Jun 10 11:50:46 2024 -0700

Bump software.amazon.awssdk:bom from 2.25.68 to 2.25.69 (#13349)
---
 pom.xml | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/pom.xml b/pom.xml
index ae4413007f..930627b667 100644
--- a/pom.xml
+++ b/pom.xml
@@ -172,7 +172,7 @@
 0.15.0
 0.4.4
 4.2.2
-2.25.68
+2.25.69
 2.12.7
 3.1.12
 7.10.2


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



Re: [PR] Bump software.amazon.awssdk:bom from 2.25.68 to 2.25.69 [pinot]

2024-06-10 Thread via GitHub


Jackie-Jiang merged PR #13349:
URL: https://github.com/apache/pinot/pull/13349


-- 
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: commits-unsubscr...@pinot.apache.org

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


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



(pinot) branch master updated (e8db382d51 -> e072542e78)

2024-06-10 Thread jackie
This is an automated email from the ASF dual-hosted git repository.

jackie pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/pinot.git


from e8db382d51 [Backfill] allow externally partitioned segment uploads for 
upsert tables (#13107)
 add e072542e78 Bump dropwizard-metrics.version from 4.2.25 to 4.2.26 
(#13348)

No new revisions were added by this update.

Summary of changes:
 pom.xml | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



(pinot) branch dependabot/maven/dropwizard-metrics.version-4.2.26 deleted (was bf7485ab97)

2024-06-10 Thread jackie
This is an automated email from the ASF dual-hosted git repository.

jackie pushed a change to branch 
dependabot/maven/dropwizard-metrics.version-4.2.26
in repository https://gitbox.apache.org/repos/asf/pinot.git


 was bf7485ab97 Bump dropwizard-metrics.version from 4.2.25 to 4.2.26

The revisions that were on this branch are still contained in
other references; therefore, this change does not discard any commits
from the repository.


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



Re: [PR] Bump dropwizard-metrics.version from 4.2.25 to 4.2.26 [pinot]

2024-06-10 Thread via GitHub


Jackie-Jiang merged PR #13348:
URL: https://github.com/apache/pinot/pull/13348


-- 
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: commits-unsubscr...@pinot.apache.org

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


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



(pinot) branch master updated: [Backfill] allow externally partitioned segment uploads for upsert tables (#13107)

2024-06-10 Thread xbli
This is an automated email from the ASF dual-hosted git repository.

xbli pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/pinot.git


The following commit(s) were added to refs/heads/master by this push:
 new e8db382d51 [Backfill] allow externally partitioned segment uploads for 
upsert tables (#13107)
e8db382d51 is described below

commit e8db382d519aa59310f5788b75f5b1cc13143f55
Author: rohit 
AuthorDate: Mon Jun 10 21:48:44 2024 +0530

[Backfill] allow externally partitioned segment uploads for upsert tables 
(#13107)

* [Backfill] allow externally partitioned segment uploads for upsert tables

* upload segment with partitionId

* revise uploaded realtime segment name convention
---
 .../apache/pinot/common/utils/SegmentUtils.java|   6 +
 .../common/utils/UploadedRealtimeSegmentName.java  | 181 +
 .../pinot/common/utils/SegmentUtilsTest.java   |  60 +++
 .../utils/UploadedRealtimeSegmentNameTest.java |  58 +++
 .../batch/common/SegmentGenerationTaskRunner.java  |  23 ++-
 ...oncurrentMapPartitionUpsertMetadataManager.java |  49 +-
 ...rrentMapPartitionUpsertMetadataManagerTest.java | 169 +++
 .../spi/creator/SegmentGeneratorConfig.java|  21 +++
 .../creator/name/SegmentNameGeneratorFactory.java  |   1 +
 .../name/UploadedRealtimeSegmentNameGenerator.java |  91 +++
 .../spi/creator/SegmentGeneratorConfigTest.java|  15 ++
 .../UploadedRealtimeSegmentNameGeneratorTest.java  |  27 +--
 .../spi/ingestion/batch/BatchConfigProperties.java |   1 +
 13 files changed, 682 insertions(+), 20 deletions(-)

diff --git 
a/pinot-common/src/main/java/org/apache/pinot/common/utils/SegmentUtils.java 
b/pinot-common/src/main/java/org/apache/pinot/common/utils/SegmentUtils.java
index aaf44dc441..8b89a2b1a5 100644
--- a/pinot-common/src/main/java/org/apache/pinot/common/utils/SegmentUtils.java
+++ b/pinot-common/src/main/java/org/apache/pinot/common/utils/SegmentUtils.java
@@ -44,6 +44,12 @@ public class SegmentUtils {
 if (llcSegmentName != null) {
   return llcSegmentName.getPartitionGroupId();
 }
+
+UploadedRealtimeSegmentName uploadedRealtimeSegmentName = 
UploadedRealtimeSegmentName.of(segmentName);
+if (uploadedRealtimeSegmentName != null) {
+  return uploadedRealtimeSegmentName.getPartitionId();
+}
+
 // Otherwise, retrieve the partition id from the segment zk metadata.
 SegmentZKMetadata segmentZKMetadata =
 
ZKMetadataProvider.getSegmentZKMetadata(helixManager.getHelixPropertyStore(), 
realtimeTableName, segmentName);
diff --git 
a/pinot-common/src/main/java/org/apache/pinot/common/utils/UploadedRealtimeSegmentName.java
 
b/pinot-common/src/main/java/org/apache/pinot/common/utils/UploadedRealtimeSegmentName.java
new file mode 100644
index 00..ec2b257b12
--- /dev/null
+++ 
b/pinot-common/src/main/java/org/apache/pinot/common/utils/UploadedRealtimeSegmentName.java
@@ -0,0 +1,181 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.pinot.common.utils;
+
+import com.google.common.base.Joiner;
+import com.google.common.base.Preconditions;
+import java.util.Objects;
+import javax.annotation.Nullable;
+import org.apache.commons.lang3.StringUtils;
+import org.joda.time.format.DateTimeFormat;
+import org.joda.time.format.DateTimeFormatter;
+
+
+/**
+ * Class to represent segment names like: 
{prefix}__{tableName}__{partitionId}__{creationTime}__{suffix}
+ *
+ * This naming convention is adopted to represent a segment uploaded to a 
realtime table. The naming
+ * convention has been kept semantically similar to {@link LLCSegmentName} but 
differs in following ways:
+ *
+ *  prefix to quickly identify the type/source of segment e.g. 
"uploaded"/"minion"
+ *  name of the table to which the segment belongs
+ *  partitionId which should be consistent as the stream partitioning in 
case of upsert realtime tables.
+ *  creationTime creation time of segment of the format MMdd'T'HHmm'Z'
+ *  suffix to uniquely identify segments created at the same time.
+ *
+ * Use {@link 
org.apache.pinot.segment.spi.creator.name.UploadedRealtimeSegmentNameGenerator} 

Re: [PR] [Backfill] allow externally partitioned segment uploads for upsert tables [pinot]

2024-06-10 Thread via GitHub


klsince merged PR #13107:
URL: https://github.com/apache/pinot/pull/13107


-- 
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: commits-unsubscr...@pinot.apache.org

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


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



Re: [PR] [Backfill] allow externally partitioned segment uploads for upsert tables [pinot]

2024-06-10 Thread via GitHub


klsince commented on code in PR #13107:
URL: https://github.com/apache/pinot/pull/13107#discussion_r1633513536


##
pinot-segment-spi/src/main/java/org/apache/pinot/segment/spi/creator/SegmentGeneratorConfig.java:
##
@@ -600,6 +616,11 @@ public String inferSegmentNameGeneratorType() {
   return BatchConfigProperties.SegmentNameGeneratorType.NORMALIZED_DATE;
 }
 
+// if segment is externally partitioned
+if (_uploadedSegmentPartitionId != -1) {

Review Comment:
   my bad, I meant to be reattime table, but anyway not blocking for this PR



-- 
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: commits-unsubscr...@pinot.apache.org

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


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



Re: [PR] UI Load time Improvement API Fixes #13278 [pinot]

2024-06-10 Thread via GitHub


deepthi912 commented on code in PR #13296:
URL: https://github.com/apache/pinot/pull/13296#discussion_r1633380421


##
pinot-common/src/main/java/org/apache/pinot/common/config/provider/TableCache.java:
##
@@ -361,7 +361,8 @@ private void putSchema(ZNRecord znRecord)
 columnNameMap.put(columnName, columnName);
   }
 }
-_schemaInfoMap.put(schemaName, new SchemaInfo(schema, columnNameMap));
+_schemaInfoMap.put(schemaName, new SchemaInfo(schema, columnNameMap, 
schema.getDimensionFieldSpecs().size(),
+schema.getDateTimeFieldSpecs().size(), 
schema.getMetricFieldSpecs().size()));

Review Comment:
   Will check it out.



-- 
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: commits-unsubscr...@pinot.apache.org

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


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



Re: [I] Use Foreign Memory API, introduced in Java 22 [pinot]

2024-06-10 Thread via GitHub


gortiz commented on issue #12809:
URL: https://github.com/apache/pinot/issues/12809#issuecomment-2158186978

   pinot-test.yml is the one that tests the code.


-- 
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: commits-unsubscr...@pinot.apache.org

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


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



Re: [I] Unable to Run Ingestion Job when using ADLS Gen2 as a source and destination [pinot]

2024-06-10 Thread via GitHub


amirjalali1 commented on issue #11025:
URL: https://github.com/apache/pinot/issues/11025#issuecomment-2158090798

   i'm facing the same issue @Akash-Nair any resolution
   @snleee here is my spec im using the recipe for importing CSV file the only 
change here is reading from ADLS
   
   `
   executionFrameworkSpec:
 name: 'standalone'
 segmentGenerationJobRunnerClassName: 
'org.apache.pinot.plugin.ingestion.batch.standalone.SegmentGenerationJobRunner'
 segmentTarPushJobRunnerClassName: 
'org.apache.pinot.plugin.ingestion.batch.standalone.SegmentTarPushJobRunner'
 segmentUriPushJobRunnerClassName: 
'org.apache.pinot.plugin.ingestion.batch.standalone.SegmentUriPushJobRunner'
   jobType: SegmentCreationAndTarPush
   inputDirURI: 'adl2://x/pin_in'
   outputDirURI: 'adl2://x/pin_out'
   overwriteOutput: true
   includeFileNamePattern: 'glob:**/import.csv'
   pinotFSSpecs:
   - scheme: adl2
 className: org.apache.pinot.plugin.filesystem.ADLSGen2PinotFS
 configs:
   accountName: ''
   accessKey: 'x'
   fileSystemName: 'x'
   recordReaderSpec:
 dataFormat: 'csv'
 className: 'org.apache.pinot.plugin.inputformat.csv.CSVRecordReader'
 configClassName: 
'org.apache.pinot.plugin.inputformat.csv.CSVRecordReaderConfig'
   tableSpec:
 tableName: 'crimes'
   pinotClusterSpecs:
 - controllerURI: 'http://pinot-controller-csv:9000/'
   pushJobSpec:
 pushAttempts: 2
 pushRetryIntervalMillis: 1000
   
   
   `


-- 
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: commits-unsubscr...@pinot.apache.org

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


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



(pinot) branch dependabot/maven/com.azure-azure-storage-file-datalake-12.19.1 created (now 0fbfc38021)

2024-06-10 Thread github-bot
This is an automated email from the ASF dual-hosted git repository.

github-bot pushed a change to branch 
dependabot/maven/com.azure-azure-storage-file-datalake-12.19.1
in repository https://gitbox.apache.org/repos/asf/pinot.git


  at 0fbfc38021 Bump com.azure:azure-storage-file-datalake from 12.19.0 to 
12.19.1

No new revisions were added by this update.


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



[PR] Bump com.azure:azure-storage-file-datalake from 12.19.0 to 12.19.1 [pinot]

2024-06-10 Thread via GitHub


dependabot[bot] opened a new pull request, #13350:
URL: https://github.com/apache/pinot/pull/13350

   Bumps 
[com.azure:azure-storage-file-datalake](https://github.com/Azure/azure-sdk-for-java)
 from 12.19.0 to 12.19.1.
   
   Release notes
   Sourced from https://github.com/Azure/azure-sdk-for-java/releases;>com.azure:azure-storage-file-datalake's
 releases.
   
   azure-storage-file-datalake_12.19.1
   12.19.1 (2024-06-06)
   Other Changes
   Dependency Updates
   
   Upgraded azure-core from 1.49.0 to version 
1.49.1.
   Upgraded azure-core-http-netty from 1.15.0 to 
version 1.15.1.
   Upgraded azure-storage-blob from 12.26.0 to 
version 12.26.1.
   
   
   
   
   Commits
   
   https://github.com/Azure/azure-sdk-for-java/commit/d41a24f603e94f69eb1cbbb7547e1058ca10ab91;>d41a24f
 Updated CHANGELOGs and READMEs.
   https://github.com/Azure/azure-sdk-for-java/commit/0c172865edd5b810e48d4488a1c31817ed664294;>0c17286
 Removed expiration dates for playback tests.
   https://github.com/Azure/azure-sdk-for-java/commit/4b60f4c99c3eba4946706bf3b22ce4ceba881fb9;>4b60f4c
 Reset test recordings/
   https://github.com/Azure/azure-sdk-for-java/commit/477deede12cf411bbe9c43e764240d1db5618729;>477deed
 Updating the SDK dependencies for azure-storage-queue
   https://github.com/Azure/azure-sdk-for-java/commit/7dbf87525e87f763eb1a3e77f67dd6585bdf;>7dbf875
 Reset changes to the patch version.
   https://github.com/Azure/azure-sdk-for-java/commit/0adde7a450280c3cc0bebd86830a33d981e0;>0ad
 Updating the SDK dependencies for azure-storage-file-share
   https://github.com/Azure/azure-sdk-for-java/commit/7bbdd383c04f2221d3a4c116968f59a87ae12b50;>7bbdd38
 Reset changes to the patch version.
   https://github.com/Azure/azure-sdk-for-java/commit/803d3cd470b8ded6cae13d9ab3a5d2cb2aa57b6b;>803d3cd
 Updating the SDK dependencies for azure-storage-file-datalake
   https://github.com/Azure/azure-sdk-for-java/commit/d654a5e0314c45ff1acc705278a4799f1768b277;>d654a5e
 Reset changes to the patch version.
   https://github.com/Azure/azure-sdk-for-java/commit/ecd1ee44a6e406d3f19c7133997971c0a17a77e8;>ecd1ee4
 Updating the SDK dependencies for azure-storage-internal-avro
   Additional commits viewable in https://github.com/Azure/azure-sdk-for-java/compare/azure-storage-blob_12.19.0...azure-storage-blob_12.19.1;>compare
 view
   
   
   
   
   
   [![Dependabot compatibility 
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=com.azure:azure-storage-file-datalake=maven=12.19.0=12.19.1)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)
   
   Dependabot will resolve any conflicts with this PR as long as you don't 
alter it yourself. You can also trigger a rebase manually by commenting 
`@dependabot rebase`.
   
   [//]: # (dependabot-automerge-start)
   [//]: # (dependabot-automerge-end)
   
   ---
   
   
   Dependabot commands and options
   
   
   You can trigger Dependabot actions by commenting on this PR:
   - `@dependabot rebase` will rebase this PR
   - `@dependabot recreate` will recreate this PR, overwriting any edits that 
have been made to it
   - `@dependabot merge` will merge this PR after your CI passes on it
   - `@dependabot squash and merge` will squash and merge this PR after your CI 
passes on it
   - `@dependabot cancel merge` will cancel a previously requested merge and 
block automerging
   - `@dependabot reopen` will reopen this PR if it is closed
   - `@dependabot close` will close this PR and stop Dependabot recreating it. 
You can achieve the same result by closing it manually
   - `@dependabot show  ignore conditions` will show all of 
the ignore conditions of the specified dependency
   - `@dependabot ignore this major version` will close this PR and stop 
Dependabot creating any more for this major version (unless you reopen the PR 
or upgrade to it yourself)
   - `@dependabot ignore this minor version` will close this PR and stop 
Dependabot creating any more for this minor version (unless you reopen the PR 
or upgrade to it yourself)
   - `@dependabot ignore this dependency` will close this PR and stop 
Dependabot creating any more for this dependency (unless you reopen the PR or 
upgrade to it yourself)
   
   
   


-- 
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: commits-unsubscr...@pinot.apache.org

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


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



(pinot) branch dependabot/maven/software.amazon.awssdk-bom-2.25.69 created (now 3ba73cc3dc)

2024-06-10 Thread github-bot
This is an automated email from the ASF dual-hosted git repository.

github-bot pushed a change to branch 
dependabot/maven/software.amazon.awssdk-bom-2.25.69
in repository https://gitbox.apache.org/repos/asf/pinot.git


  at 3ba73cc3dc Bump software.amazon.awssdk:bom from 2.25.68 to 2.25.69

No new revisions were added by this update.


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



[PR] Bump software.amazon.awssdk:bom from 2.25.68 to 2.25.69 [pinot]

2024-06-10 Thread via GitHub


dependabot[bot] opened a new pull request, #13349:
URL: https://github.com/apache/pinot/pull/13349

   Bumps software.amazon.awssdk:bom from 2.25.68 to 2.25.69.
   
   
   [![Dependabot compatibility 
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=software.amazon.awssdk:bom=maven=2.25.68=2.25.69)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)
   
   Dependabot will resolve any conflicts with this PR as long as you don't 
alter it yourself. You can also trigger a rebase manually by commenting 
`@dependabot rebase`.
   
   [//]: # (dependabot-automerge-start)
   [//]: # (dependabot-automerge-end)
   
   ---
   
   
   Dependabot commands and options
   
   
   You can trigger Dependabot actions by commenting on this PR:
   - `@dependabot rebase` will rebase this PR
   - `@dependabot recreate` will recreate this PR, overwriting any edits that 
have been made to it
   - `@dependabot merge` will merge this PR after your CI passes on it
   - `@dependabot squash and merge` will squash and merge this PR after your CI 
passes on it
   - `@dependabot cancel merge` will cancel a previously requested merge and 
block automerging
   - `@dependabot reopen` will reopen this PR if it is closed
   - `@dependabot close` will close this PR and stop Dependabot recreating it. 
You can achieve the same result by closing it manually
   - `@dependabot show  ignore conditions` will show all of 
the ignore conditions of the specified dependency
   - `@dependabot ignore this major version` will close this PR and stop 
Dependabot creating any more for this major version (unless you reopen the PR 
or upgrade to it yourself)
   - `@dependabot ignore this minor version` will close this PR and stop 
Dependabot creating any more for this minor version (unless you reopen the PR 
or upgrade to it yourself)
   - `@dependabot ignore this dependency` will close this PR and stop 
Dependabot creating any more for this dependency (unless you reopen the PR or 
upgrade to it yourself)
   
   
   


-- 
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: commits-unsubscr...@pinot.apache.org

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


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



[PR] Bump dropwizard-metrics.version from 4.2.25 to 4.2.26 [pinot]

2024-06-10 Thread via GitHub


dependabot[bot] opened a new pull request, #13348:
URL: https://github.com/apache/pinot/pull/13348

   Bumps `dropwizard-metrics.version` from 4.2.25 to 4.2.26.
   Updates `io.dropwizard.metrics:metrics-core` from 4.2.25 to 4.2.26
   
   Release notes
   Sourced from https://github.com/dropwizard/metrics/releases;>io.dropwizard.metrics:metrics-core's
 releases.
   
   v4.2.26
   What's Changed
   
   Update dependency org.mockito:mockito-core to v5.10.0 (release/4.2.x) by 
https://github.com/renovate;>@​renovate in https://redirect.github.com/dropwizard/metrics/pull/3925;>dropwizard/metrics#3925
   Update github/codeql-action digest to b7bf0a3 (release/4.2.x) by https://github.com/renovate;>@​renovate in https://redirect.github.com/dropwizard/metrics/pull/3926;>dropwizard/metrics#3926
   Update dependency org.eclipse.jetty:jetty-bom to v10.0.20 
(release/4.2.x) by https://github.com/renovate;>@​renovate in https://redirect.github.com/dropwizard/metrics/pull/3930;>dropwizard/metrics#3930
   Update dependency org.eclipse.jetty:jetty-bom to v11.0.20 
(release/4.2.x) by https://github.com/renovate;>@​renovate in https://redirect.github.com/dropwizard/metrics/pull/3931;>dropwizard/metrics#3931
   Update jetty12.version to v12.0.6 (release/4.2.x) (patch) by https://github.com/renovate;>@​renovate in https://redirect.github.com/dropwizard/metrics/pull/3932;>dropwizard/metrics#3932
   Update dependency org.jdbi:jdbi3-core to v3.44.0 (release/4.2.x) by https://github.com/renovate;>@​renovate in https://redirect.github.com/dropwizard/metrics/pull/3933;>dropwizard/metrics#3933
   Update github/codeql-action digest to e8893c5 (release/4.2.x) by https://github.com/renovate;>@​renovate in https://redirect.github.com/dropwizard/metrics/pull/3938;>dropwizard/metrics#3938
   Update dependency org.assertj:assertj-core to v3.25.3 (release/4.2.x) by 
https://github.com/renovate;>@​renovate in https://redirect.github.com/dropwizard/metrics/pull/3940;>dropwizard/metrics#3940
   Update slf4j monorepo to v2.0.12 (release/4.2.x) (patch) by https://github.com/renovate;>@​renovate in https://redirect.github.com/dropwizard/metrics/pull/3943;>dropwizard/metrics#3943
   Update webfactory/ssh-agent action to v0.9.0 (release/4.2.x) by https://github.com/renovate;>@​renovate in https://redirect.github.com/dropwizard/metrics/pull/3945;>dropwizard/metrics#3945
   Update dependency org.jdbi:jdbi3-core to v3.44.1 (release/4.2.x) by https://github.com/renovate;>@​renovate in https://redirect.github.com/dropwizard/metrics/pull/3947;>dropwizard/metrics#3947
   Update jetty9.version to v9.4.54.v20240208 (release/4.2.x) (patch) by https://github.com/renovate;>@​renovate in https://redirect.github.com/dropwizard/metrics/pull/3950;>dropwizard/metrics#3950
   Update github/codeql-action digest to e675ced (release/4.2.x) by https://github.com/renovate;>@​renovate in https://redirect.github.com/dropwizard/metrics/pull/3949;>dropwizard/metrics#3949
   Pin JetBrains/qodana-action action to e42ff2d (release/4.2.x) by https://github.com/renovate;>@​renovate in https://redirect.github.com/dropwizard/metrics/pull/3952;>dropwizard/metrics#3952
   Update github/codeql-action digest to 3796146 (release/4.2.x) by https://github.com/renovate;>@​renovate in https://redirect.github.com/dropwizard/metrics/pull/3954;>dropwizard/metrics#3954
   Update dependency net.bytebuddy:byte-buddy to v1.14.12 (release/4.2.x) 
by https://github.com/renovate;>@​renovate in https://redirect.github.com/dropwizard/metrics/pull/3956;>dropwizard/metrics#3956
   Update dependency com.google.errorprone:error_prone_core to v2.25.0 
(release/4.2.x) by https://github.com/renovate;>@​renovate in https://redirect.github.com/dropwizard/metrics/pull/3957;>dropwizard/metrics#3957
   Update dependency org.jdbi:jdbi3-core to v3.45.0 (release/4.2.x) by https://github.com/renovate;>@​renovate in https://redirect.github.com/dropwizard/metrics/pull/3964;>dropwizard/metrics#3964
   Add module for Logback 1.5.x by https://github.com/joschi;>@​joschi in https://redirect.github.com/dropwizard/metrics/pull/3967;>dropwizard/metrics#3967
   Update dependency org.apache.maven.plugins:maven-shade-plugin to v3.5.2 
(release/4.2.x) by https://github.com/renovate;>@​renovate in https://redirect.github.com/dropwizard/metrics/pull/3969;>dropwizard/metrics#3969
   Update log4j2 monorepo to v2.23.0 (release/4.2.x) (minor) by https://github.com/renovate;>@​renovate in https://redirect.github.com/dropwizard/metrics/pull/3971;>dropwizard/metrics#3971
   Update github/codeql-action digest to e2e140a (release/4.2.x) by https://github.com/renovate;>@​renovate in https://redirect.github.com/dropwizard/metrics/pull/3973;>dropwizard/metrics#3973
   Update github/codeql-action digest to 47b3d88 (release/4.2.x) by https://github.com/renovate;>@​renovate in https://redirect.github.com/dropwizard/metrics/pull/3975;>dropwizard/metrics#3975
   Update logback15.version to v1.5.1 (release/4.2.x) (patch) by 

(pinot) branch dependabot/maven/dropwizard-metrics.version-4.2.26 created (now bf7485ab97)

2024-06-10 Thread github-bot
This is an automated email from the ASF dual-hosted git repository.

github-bot pushed a change to branch 
dependabot/maven/dropwizard-metrics.version-4.2.26
in repository https://gitbox.apache.org/repos/asf/pinot.git


  at bf7485ab97 Bump dropwizard-metrics.version from 4.2.25 to 4.2.26

No new revisions were added by this update.


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



Re: [PR] Improve performance of DataBlock serde [pinot]

2024-06-10 Thread via GitHub


gortiz commented on code in PR #13303:
URL: https://github.com/apache/pinot/pull/13303#discussion_r1633056604


##
pinot-perf/src/main/java/org/apache/pinot/perf/BenchmarkDataBlock.java:
##
@@ -0,0 +1,269 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.pinot.perf;
+
+import java.io.File;
+import java.io.IOException;
+import java.math.BigDecimal;
+import java.nio.ByteBuffer;
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.List;
+import java.util.Random;
+import java.util.concurrent.TimeUnit;
+import java.util.function.Consumer;
+import org.apache.commons.lang3.SystemUtils;
+import org.apache.pinot.common.datablock.DataBlock;
+import org.apache.pinot.common.datablock.DataBlockSerde;
+import org.apache.pinot.common.datablock.DataBlockUtils;
+import org.apache.pinot.common.datablock.ZeroCopyDataBlockSerde;
+import org.apache.pinot.common.utils.DataSchema;
+import org.apache.pinot.core.common.datablock.DataBlockBuilder;
+import org.apache.pinot.segment.spi.memory.PagedPinotOutputStream;
+import org.apache.pinot.spi.utils.ByteArray;
+import org.openjdk.jmh.annotations.Benchmark;
+import org.openjdk.jmh.annotations.Fork;
+import org.openjdk.jmh.annotations.Level;
+import org.openjdk.jmh.annotations.Measurement;
+import org.openjdk.jmh.annotations.OutputTimeUnit;
+import org.openjdk.jmh.annotations.Param;
+import org.openjdk.jmh.annotations.Scope;
+import org.openjdk.jmh.annotations.Setup;
+import org.openjdk.jmh.annotations.State;
+import org.openjdk.jmh.annotations.Threads;
+import org.openjdk.jmh.annotations.Warmup;
+import org.openjdk.jmh.profile.GCProfiler;
+import org.openjdk.jmh.results.format.ResultFormatType;
+import org.openjdk.jmh.runner.Runner;
+import org.openjdk.jmh.runner.RunnerException;
+import org.openjdk.jmh.runner.options.ChainedOptionsBuilder;
+import org.openjdk.jmh.runner.options.OptionsBuilder;
+
+@Warmup(iterations = 2, time = 2)
+@Measurement(iterations = 5, time = 1)
+@Fork(value = 1, jvmArgsPrepend = {
+"--add-opens=java.base/java.nio=ALL-UNNAMED",
+"--add-opens=java.base/sun.nio.ch=ALL-UNNAMED",
+"--add-opens=java.base/java.lang=ALL-UNNAMED",
+"--add-opens=java.base/java.util=ALL-UNNAMED",
+"--add-opens=java.base/java.lang.reflect=ALL-UNNAMED"
+})
+@Threads(5)
+@State(Scope.Benchmark)
+@OutputTimeUnit(TimeUnit.MILLISECONDS)
+public class BenchmarkDataBlock {
+
+  public static void main(String[] args)
+  throws RunnerException {
+start(BenchmarkDataBlock.class, opt -> opt
+//.addProfiler(LinuxPerfAsmProfiler.class)
+//.addProfiler(JavaFlightRecorderProfiler.class)
+.addProfiler(GCProfiler.class));
+  }
+
+  @Param(value = {"INT", "LONG", "STRING", "BYTES", "BIG_DECIMAL", 
"LONG_ARRAY", "STRING_ARRAY"})
+  DataSchema.ColumnDataType _dataType;
+  @Param(value = {"COLUMNAR", "ROW"})
+  DataBlock.Type _blockType = DataBlock.Type.COLUMNAR;
+  //@Param(value = {"0", "10", "90"})
+  int _nullPerCent = 10;
+
+//  @Param(value = {"direct_small", "heap_small"})

Review Comment:
   This can be used to study the performance on different allocators. 
`heal_small` is the faster by a large margin.



-- 
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: commits-unsubscr...@pinot.apache.org

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


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



Re: [PR] Ensure upsert deletion consistency when enabled with compaction flow [pinot]

2024-06-10 Thread via GitHub


codecov-commenter commented on PR #13347:
URL: https://github.com/apache/pinot/pull/13347#issuecomment-2158006287

   ## 
[Codecov](https://app.codecov.io/gh/apache/pinot/pull/13347?dropdown=coverage=pr=h1_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 Report
   Attention: Patch coverage is `0%` with `26 lines` in your changes missing 
coverage. Please review.
   > Project coverage is 0.00%. Comparing base 
[(`59551e4`)](https://app.codecov.io/gh/apache/pinot/commit/59551e45224f1535c4863fd577622b37366ccc97?dropdown=coverage=desc_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 to head 
[(`2bbe2bd`)](https://app.codecov.io/gh/apache/pinot/commit/2bbe2bdaf2b6e131666b21f08831d3fe0a4cb442?dropdown=coverage=desc_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache).
   > Report is 586 commits behind head on master.
   
   | 
[Files](https://app.codecov.io/gh/apache/pinot/pull/13347?dropdown=coverage=pr=tree_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | Patch % | Lines |
   |---|---|---|
   | 
[...t/ConcurrentMapPartitionUpsertMetadataManager.java](https://app.codecov.io/gh/apache/pinot/pull/13347?src=pr=tree=pinot-segment-local%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fpinot%2Fsegment%2Flocal%2Fupsert%2FConcurrentMapPartitionUpsertMetadataManager.java_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache#diff-cGlub3Qtc2VnbWVudC1sb2NhbC9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvcGlub3Qvc2VnbWVudC9sb2NhbC91cHNlcnQvQ29uY3VycmVudE1hcFBhcnRpdGlvblVwc2VydE1ldGFkYXRhTWFuYWdlci5qYXZh)
 | 0.00% | [26 Missing :warning: 
](https://app.codecov.io/gh/apache/pinot/pull/13347?src=pr=tree_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 |
   
   Additional details and impacted files
   
   
   ```diff
   @@  Coverage Diff  @@
   ## master   #13347   +/-   ##
   =
   - Coverage 61.75%0.00%   -61.76% 
   =
 Files  2436 2470   +34 
 Lines133233   136151 +2918 
 Branches  2063621141  +505 
   =
   - Hits  822740-82274 
   - Misses44911   136151+91240 
   + Partials   60480 -6048 
   ```
   
   | 
[Flag](https://app.codecov.io/gh/apache/pinot/pull/13347/flags?src=pr=flags_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | Coverage Δ | |
   |---|---|---|
   | 
[custom-integration1](https://app.codecov.io/gh/apache/pinot/pull/13347/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `?` | |
   | 
[integration](https://app.codecov.io/gh/apache/pinot/pull/13347/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `0.00% <0.00%> (-0.01%)` | :arrow_down: |
   | 
[integration1](https://app.codecov.io/gh/apache/pinot/pull/13347/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `?` | |
   | 
[integration2](https://app.codecov.io/gh/apache/pinot/pull/13347/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `0.00% <0.00%> (ø)` | |
   | 
[java-11](https://app.codecov.io/gh/apache/pinot/pull/13347/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `?` | |
   | 
[java-21](https://app.codecov.io/gh/apache/pinot/pull/13347/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `0.00% <0.00%> (-61.63%)` | :arrow_down: |
   | 
[skip-bytebuffers-false](https://app.codecov.io/gh/apache/pinot/pull/13347/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `?` | |
   | 
[skip-bytebuffers-true](https://app.codecov.io/gh/apache/pinot/pull/13347/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `0.00% <0.00%> (-27.73%)` | :arrow_down: |
   | 
[temurin](https://app.codecov.io/gh/apache/pinot/pull/13347/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `0.00% <0.00%> (-61.76%)` | :arrow_down: |
   | 
[unittests](https://app.codecov.io/gh/apache/pinot/pull/13347/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `?` | |
   | 
[unittests1](https://app.codecov.io/gh/apache/pinot/pull/13347/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `?` | |
   | 
[unittests2](https://app.codecov.io/gh/apache/pinot/pull/13347/flags?src=pr=flag_medium=referral_source=github_content=comment_campaign=pr+comments_term=apache)
 | `?` | |
 

Re: [PR] Improve performance of DataBlock serde [pinot]

2024-06-10 Thread via GitHub


gortiz commented on code in PR #13303:
URL: https://github.com/apache/pinot/pull/13303#discussion_r1633033128


##
pinot-core/src/main/java/org/apache/pinot/core/common/datablock/DataBlockBuilder.java:
##
@@ -187,200 +141,315 @@ public static RowDataBlock buildFromRows(List 
rows, DataSchema dataSch
 dataSchema.getColumnName(colId)));
 }
   }
-  rowBuilder._fixedSizeDataByteArrayOutputStream.write(byteBuffer.array(), 
0, byteBuffer.position());
 }
+
+CompoundDataBuffer.Builder varBufferBuilder = new 
CompoundDataBuffer.Builder(ByteOrder.BIG_ENDIAN, true)
+.addPagedOutputStream(varSize);
+
 // Write null bitmaps after writing data.
-for (RoaringBitmap nullBitmap : nullBitmaps) {
-  rowBuilder.setNullRowIds(nullBitmap);
-}
-return buildRowBlock(rowBuilder);
+setNullRowIds(nullBitmaps, fixedSize, varBufferBuilder);
+return buildRowBlock(numRows, dataSchema, 
getReverseDictionary(dictionary), fixedSize, varBufferBuilder);
   }
 
   public static ColumnarDataBlock buildFromColumns(List columns, 
DataSchema dataSchema)
   throws IOException {
 int numRows = columns.isEmpty() ? 0 : columns.get(0).length;
-DataBlockBuilder columnarBuilder = new DataBlockBuilder(dataSchema, 
DataBlock.Type.COLUMNAR, numRows);
+
+int fixedBytesPerRow = calculateBytesPerRow(dataSchema);
+int nullFixedBytes = dataSchema.size() * Integer.BYTES * 2;
+int fixedBytesRequired = fixedBytesPerRow * numRows + nullFixedBytes;
+
+Object2IntOpenHashMap dictionary = new Object2IntOpenHashMap<>();
+
 // TODO: consolidate these null utils into data table utils.
 // Selection / Agg / Distinct all have similar code.
-ColumnDataType[] storedTypes = dataSchema.getStoredColumnDataTypes();
-int numColumns = storedTypes.length;
+int numColumns = dataSchema.size();
+
 RoaringBitmap[] nullBitmaps = new RoaringBitmap[numColumns];
-Object[] nullPlaceholders = new Object[numColumns];
-for (int colId = 0; colId < numColumns; colId++) {
-  nullBitmaps[colId] = new RoaringBitmap();
-  nullPlaceholders[colId] = storedTypes[colId].getNullPlaceholder();
+ByteBuffer fixedSize = ByteBuffer.allocate(fixedBytesRequired);
+CompoundDataBuffer.Builder varBufferBuilder = new 
CompoundDataBuffer.Builder(ByteOrder.BIG_ENDIAN, true);
+
+try (PagedPinotOutputStream varSize = PagedPinotOutputStream.createHeap()) 
{
+  for (int colId = 0; colId < numColumns; colId++) {
+RoaringBitmap nullBitmap = new RoaringBitmap();
+nullBitmaps[colId] = nullBitmap;
+serializeColumnData(columns, dataSchema, colId, fixedSize, varSize, 
nullBitmap, dictionary);
+  }
+  varBufferBuilder.addPagedOutputStream(varSize);
 }
-for (int colId = 0; colId < numColumns; colId++) {
-  Object[] column = columns.get(colId);
-  ByteBuffer byteBuffer = ByteBuffer.allocate(numRows * 
columnarBuilder._columnSizeInBytes[colId]);
-  Object value;
-
-  // NOTE:
-  // We intentionally make the type casting very strict here (e.g. only 
accepting Integer for INT) to ensure the
-  // rows conform to the data schema. This can help catch the unexpected 
data type issues early.
-  switch (storedTypes[colId]) {
-// Single-value column
-case INT:
-  for (int rowId = 0; rowId < numRows; rowId++) {
-value = column[rowId];
-if (value == null) {
-  nullBitmaps[colId].add(rowId);
-  value = nullPlaceholders[colId];
-}
-byteBuffer.putInt((int) value);
+// Write null bitmaps after writing data.
+setNullRowIds(nullBitmaps, fixedSize, varBufferBuilder);
+return buildColumnarBlock(numRows, dataSchema, 
getReverseDictionary(dictionary), fixedSize, varBufferBuilder);
+  }
+
+  private static void serializeColumnData(List columns, DataSchema 
dataSchema, int colId,
+  ByteBuffer fixedSize, PagedPinotOutputStream varSize, RoaringBitmap 
nullBitmap,
+  Object2IntOpenHashMap dictionary)
+  throws IOException {
+ColumnDataType storedType = 
dataSchema.getColumnDataType(colId).getStoredType();
+int numRows = columns.get(colId).length;
+
+Object[] column = columns.get(colId);
+
+// NOTE:
+// We intentionally make the type casting very strict here (e.g. only 
accepting Integer for INT) to ensure the
+// rows conform to the data schema. This can help catch the unexpected 
data type issues early.
+switch (storedType) {
+  // Single-value column
+  case INT: {
+int nullPlaceholder = (int) storedType.getNullPlaceholder();
+for (int rowId = 0; rowId < numRows; rowId++) {
+  Object value = column[rowId];
+  if (value == null) {
+nullBitmap.add(rowId);
+fixedSize.putInt(nullPlaceholder);
+  } else {
+fixedSize.putInt((int) value);
   }
-  break;
-case 

Re: [PR] Improve performance of DataBlock serde [pinot]

2024-06-10 Thread via GitHub


gortiz commented on code in PR #13303:
URL: https://github.com/apache/pinot/pull/13303#discussion_r1633031444


##
pinot-core/src/main/java/org/apache/pinot/core/common/datablock/DataBlockBuilder.java:
##
@@ -187,200 +141,315 @@ public static RowDataBlock buildFromRows(List 
rows, DataSchema dataSch
 dataSchema.getColumnName(colId)));
 }
   }
-  rowBuilder._fixedSizeDataByteArrayOutputStream.write(byteBuffer.array(), 
0, byteBuffer.position());
 }
+
+CompoundDataBuffer.Builder varBufferBuilder = new 
CompoundDataBuffer.Builder(ByteOrder.BIG_ENDIAN, true)
+.addPagedOutputStream(varSize);
+

Review Comment:
   This is probably the biggest improvement in performance when creating the 
block. The older version allocated a large array (which is expensive as it may 
be outside the TLAB) and then copy that into the ArrayOutputStream, which 
probably ends up allocating that amount of bytes again.
   
   Now instead we just reuse the whole byte buffer, adding it into the builder, 
which is basically a list of byte buffers that can be later be used to send the 
data through the network or directly read the info on another local stage.



-- 
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: commits-unsubscr...@pinot.apache.org

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


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



Re: [PR] Improve performance of DataBlock serde [pinot]

2024-06-10 Thread via GitHub


gortiz commented on code in PR #13303:
URL: https://github.com/apache/pinot/pull/13303#discussion_r1633023949


##
pinot-common/src/test/java/org/apache/pinot/common/datablock/BaseDataBlockContract.java:
##
@@ -1,42 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *   http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied.  See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.pinot.common.datablock;
-
-import java.io.IOException;
-import java.nio.ByteBuffer;
-
-import static org.testng.Assert.*;
-
-
-public abstract class BaseDataBlockContract {
-
-  protected abstract BaseDataBlock deserialize(ByteBuffer byteBuffer, int 
versionType)
-  throws IOException;
-
-  public void testSerdeCorrectness(BaseDataBlock dataBlock)
-  throws IOException {
-byte[] bytes = dataBlock.toBytes();
-ByteBuffer byteBuffer = ByteBuffer.wrap(bytes);
-int versionType = DataBlockUtils.readVersionType(byteBuffer);
-BaseDataBlock deserialize = deserialize(byteBuffer, versionType);
-
-assertEquals(byteBuffer.position(), bytes.length, "Buffer position should 
be at the end of the buffer");
-assertEquals(deserialize, dataBlock, "Deserialized data block should be 
the same as the original data block");
-  }

Review Comment:
   Serde correctness is implemented now in the DataBlockSerde tests



-- 
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: commits-unsubscr...@pinot.apache.org

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


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



[PR] Ensure upsert deletion consistency when enabled with compaction flow [pinot]

2024-06-10 Thread via GitHub


tibrewalpratik17 opened a new pull request, #13347:
URL: https://github.com/apache/pinot/pull/13347

   Labels:
   `enhancement`
   `upsert`
   
   ### Problem statement
   
   In #12037, we added support for removing deleted keys and the validDocId for 
the deleted records after a TTL window. This ensured that deleted records would 
eventually be picked up by the compaction flow.
   In #13342, we directly enabled compaction to take care of deleted rows.
   
   In both scenarios, we could end up in a situation where an older non-deleted 
record for a particular key is not compacted, but the deleted record is. During 
a server restart, when all segments are loaded, Pinot would incorrectly mark 
the record as non-deleted and start returning it as a valid primary key, 
leading to an inconsistent state in the table.
   
   **Example**:
   
   Consider a primary key PK1 with records in segments S0 and S1. In S1, the 
record is marked as deleted. If S1 gets compacted but S0 doesn't due to 
threshold reasons in the upsert-compaction flow, during a server restart, the 
upsert-metadata-manager map would incorrectly point PK1 to S0, even though it 
should be considered deleted for the end-user.
   
   **Why not use enablePreload?**
   While enablePreload might prevent loading previous invalid records, it is 
not foolproof. Valid-doc-id snapshots are not always available due to scenarios 
like fetching segments from deepstore or upsert-compaction refreshing the 
segment. If a validDocID snapshot is missing and enablePreload is set to true, 
the segment loads normally, iterating through records and would potentially 
end-up reviving a deleted primary key with an old value with the present flow.
   
   ### Proposal
   
   This PR aims to maintain the state of PK -> distinct-segment-count. This 
means tracking the number of segments in which a record exists for a given 
primary key. If the count is <= 1, we can compact the deleted record, ensuring 
that all other records in other segments are removed.
   
   Changes required in the following upsert methods:
   - `addOrReplaceSegment`: When adding a segment, increment the counter by 1. 
For replacing a segment, the removeSegment flow will decrement the count by 1.
   - `removeSegment`: This method needs to decrement the count by 1 for all 
keys present in the segment, which requires more intrusive changes as we 
currently only iterate valid-doc-id records.
   - `addRecord` : Here, we need to check if the last pointed record is from 
the same consuming segment and increment the value accordingly. This might need 
better checks with `dropOutOfOrder` config enabled.
   
   **Inconsistent with enablePreload**
   
   This proposal might not work with `enablePreload`, as `enablePreload` only 
iterates validDocIDs during segment-addition, ultimately missing counts for 
other invalidDocIDs PKs in the upsert-map. 
   We could enable this proposal behind a new config, 
`enableDeletionConsistencyWithCompaction`, and ensure that this config cannot 
be used simultaneously with `enablePreload`. Additionally, we can use this 
boolean flag in the `removeSegment` flow to decide whether to iterate the 
entire segment or just the valid-doc-ids.
   
   cc @klsince @Jackie-Jiang raising this draft PR for early feedback on the 
proposal.


-- 
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: commits-unsubscr...@pinot.apache.org

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


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org



Re: [PR] [Backfill] allow externally partitioned segment uploads for upsert tables [pinot]

2024-06-10 Thread via GitHub


rohityadav1993 commented on code in PR #13107:
URL: https://github.com/apache/pinot/pull/13107#discussion_r1632638123


##
pinot-segment-spi/src/main/java/org/apache/pinot/segment/spi/creator/SegmentGeneratorConfig.java:
##
@@ -600,6 +616,11 @@ public String inferSegmentNameGeneratorType() {
   return BatchConfigProperties.SegmentNameGeneratorType.NORMALIZED_DATE;
 }
 
+// if segment is externally partitioned
+if (_uploadedSegmentPartitionId != -1) {

Review Comment:
   Partitioning is also applicable for non-upsert realtime table(for query 
routing). This check would restrict to upsert only tables.



-- 
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: commits-unsubscr...@pinot.apache.org

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


-
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org