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

Add Ruby implementation of Kafka's partition hasher (based on key). Test #109

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

ovy-altiscale
Copy link

that it matches results from Java.

Not hooked up yet (future commits), but can already be used manually by
a client.

Use case is to pick the partition where one knows a certain class of keys will be found.

that it matches results from Java.

Not hooked up yet (future commits), but can already be used manually by
a client.
@Ben-M
Copy link

Ben-M commented Jan 11, 2016

It's interesting to note the C client (librdkafka) uses a different partition hasher to the java client. I think that the C client implementation is the same as the one in Poseidon. It would still be nice to have this, though.

@ovy-altiscale
Copy link
Author

@Ben-M thanks for the notice. I don't know why rdkafka chose to go that route, given that "similar in spirit" doesn't seem to actually match the Scala.

In any event, for code interacting with the Java client something of this nature is needed. Note that I haven't hooked it up as any kind of default; in my code I instantiate one explicitly to compute partitions. I suppose it could be renamed to JavaCompatibleHasher if we're concerned about confusion.

@liukgg
Copy link

liukgg commented Jan 14, 2016

I encoutered the same problem "All checks have failed", and even the details are the same.
Do you have any idea to solve this problem?

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

Successfully merging this pull request may close these issues.

3 participants