Closed bf4 closed 8 years ago
Interesting, that's the first I've seen using a float for the expiration period. I've thought about this a little bit, and whether this would be a breaking change. Considering that it has been impossible to use a float when setting the expiration this seems backward compatible, and would increase parity with other AS caches.
Example from the ActiveModelSerializers caching benchmark:
Setting
expire_in: 0.1
works fine using the ActiveSupport memory storebut
readthis
casts it toto_i #=> 0
which causes the below failure and stacktrace. (PerhapsFloat(0.1).ceil
would be preferable?)