-
Notifications
You must be signed in to change notification settings - Fork 436
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
fixed long cachekeys reported on issue #380 #385
Conversation
Ok. Locally all tests are passing, but they fail on Travis. Do you have any ideas? |
Ruby 1.8.7 doesn't have the method |
Good catch! I haven't noticed you guys are using Ruby 1.8.7. I will propose a new way to hash the |
|
@i0rek Just saw your remark on CRC32 as a hashing function on #380, is it about the collisions? If none of these are good enough, you can use MurmurHash (which is what Ruby uses for strings) which is again fast and small. |
@Zapotek I recently stumbled over this: http://stackoverflow.com/questions/996843/when-is-crc-more-appropriate-to-use-than-md5-sha1. |
Hm, fair enough. Better safe than sorry then, there's also a MurmurHash3 implementation available as a gem which is faster than MurmurHash 1 or 2: https://github.com/funny-falcon/murmurhash3-ruby I think I'll switch my project to MurmurHash3 too, heh. Thanks for the info man. |
at least for Typhoeus I would prefer a stdlib solution... |
Hi guys. Sorry for the delay. I've switched the hashing method from |
Great! Since |
Hi @i0rek, Probably I haven't understood properly, but I'm currently calling
The only difference is that I'm encoding it using CRC as the return shouldn't be a string. |
@trein I am sorry. That was confusing. Thank you for your work. I will merge and make the tiny change myself. Should have done that in the first place instead of bothering you. |
fixed long cachekeys reported on issue #380
I was talking without thinking. hash returns an int... |
No description provided.