Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Switch to python builtin hash function generates too few partitions for tuple keys #619

Open
sumpfork opened this issue Apr 16, 2015 · 1 comment

Comments

@sumpfork
Copy link

Python 2.x: In 0.5.3 disco used md5 on a stringified version of the key mod the number of partitions to generate partition assignments by default. In 0.5.4 this switched to using the python hash() call. Calling this on tuples yields very few results when taken mod a low number like 100 - we're seeing in the range of 2-16 or so, yielding far few actual partitions than requested. Using strings works fine.

Seems like if keys need to be strings this should be enforced/documented, or a different hash function used?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant