sidekiq-debounce icon indicating copy to clipboard operation
sidekiq-debounce copied to clipboard

Set value + expiration in one trip

Open tldev opened this issue 7 years ago • 3 comments

Small optimization. I'm not sure if this is less ideal due to the expiration saved potentially being +/- a second from the desired expiration due to I/O. Let me know.

tldev avatar Apr 24 '17 14:04 tldev

That seems like an acceptable trade-off to make :+1: One fewer roundtrip at the cost of possibly being off by 1 RTT seems like a good optimization

NuckChorris avatar Apr 25 '17 04:04 NuckChorris

One of the specs seems to be broken, any idea what might've happened there?

NuckChorris avatar Apr 25 '17 04:04 NuckChorris

I came across the same sort of thing when working on https://github.com/hummingbird-me/sidekiq-debounce/pull/17 . It was due to an interaction with the stubbed scheduled set object. In that case I got past it by pulling in timecop and not using the stub, but there'll be a less drastic solution in there.

ben-axnick avatar Apr 26 '17 03:04 ben-axnick