ankitsultana commented on PR #12538:
URL: https://github.com/apache/pinot/pull/12538#issuecomment-2031252530

   @satishd : yeah just to be clear, I had meant collision between keys that 
don't conform to UUID format.
   
   > @ankitsultana If any of the values is not of type UUID and hash function 
is used as UUID, it generates a string, and appending string bytes prefixed 
with the respective length. But that can also cause key collisions.
   > 
   > Other alternatives when any of the values is invalid UUID type:
   > 
   > 1. Use primaryKey.asBytes() as the intention is more like a no-op hash 
function as you mentioned in this PR 
[description](https://github.com/apache/pinot/pull/12538#issue-2164675632).
   > 2. Fallback to Murmur3 hash.
   > 
   > wdyt?
   
   I guess you mean collision between two primary keys where one is UUID 
conformant and the other is not?
   
   Unless we prepend the length of the string in the UUID conformant 
serialization scheme, there will always be theoretical chances of collision. I 
think prepending the length of the string removes chances of such collision 
beyond any reasonable doubt. I got rid of the null terminated strings because 
those felt too easy to collide (e.g. `(foo, bar) and (fo, obar)`).
   


-- 
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

Reply via email to