You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pinot.apache.org by GitBox <gi...@apache.org> on 2022/02/17 11:17:22 UTC

[GitHub] [pinot] kmozaid opened a new issue #8215: HashCode Partitioning is broken.

kmozaid opened a new issue #8215:
URL: https://github.com/apache/pinot/issues/8215


   HashCodePartitionFunction is producing different partitionId for same value of different type. 
   HashCode generated [here](https://github.com/apache/pinot/blob/master/pinot-segment-local/src/main/java/org/apache/pinot/segment/local/segment/creator/impl/stats/AbstractColumnStatisticsCollector.java#L157) is different than hashcode generated [here](https://github.com/apache/pinot/blob/master/pinot-broker/src/main/java/org/apache/pinot/broker/routing/segmentpruner/PartitionSegmentPruner.java#L215) for exact same value(In pruner, toString() is called before invoking getPartitionId on value.
   
   Consider below example code to reproduce the issue -
   ```
       Object i = 200;
       PartitionFunction partitionFunction = new HashCodePartitionFunction(4);
       System.out.println(partitionFunction.getPartition(i));
       System.out.println(partitionFunction.getPartition(i.toString()));
   ```
   The output of above code - 
   ```
   0
   2
   ```
   


-- 
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-unsubscribe@pinot.apache.org

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



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


[GitHub] [pinot] kmozaid edited a comment on issue #8215: HashCode Partitioning is broken.

Posted by GitBox <gi...@apache.org>.
kmozaid edited a comment on issue #8215:
URL: https://github.com/apache/pinot/issues/8215#issuecomment-1042847991


   The fix for the issue - https://github.com/apache/pinot/pull/8216


-- 
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-unsubscribe@pinot.apache.org

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



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


[GitHub] [pinot] kmozaid commented on issue #8215: HashCode Partitioning is broken.

Posted by GitBox <gi...@apache.org>.
kmozaid commented on issue #8215:
URL: https://github.com/apache/pinot/issues/8215#issuecomment-1042847991


   The fix for the issue - https://github.com/apache/pinot/issues/8192


-- 
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-unsubscribe@pinot.apache.org

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



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