-
Notifications
You must be signed in to change notification settings - Fork 54
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 murmur3 to hash module #122
Conversation
4368b14
to
422768a
Compare
go/hashmodule/hashmodule.go
Outdated
// md5, | ||
// sha1, | ||
// sha256, | ||
// murmur3, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Indentation looks off here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah yeah that's my formatter. Can fix
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fixed
go/hashmodule/hashmodule.go
Outdated
"md5": starlark.NewBuiltin("hash.md5", fnHash(md5.New)), | ||
"sha1": starlark.NewBuiltin("hash.sha1", fnHash(sha1.New)), | ||
"sha256": starlark.NewBuiltin("hash.sha256", fnHash(sha256.New)), | ||
"murmur3_64": starlark.NewBuiltin("hash.murmur3_64", fnHash64(murmur3.New64)), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
murmur3
above but murmur3_64
here. Former seems better to me.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fixed
422768a
to
1fa0365
Compare
As per the description, we wanted to use murmur3, hence we'd like to add it to the hash module. We are experimenting with it internally at Stripe for some CI tooling, given its known better performance for fair distribution of a small set of inputs.