mperham/sidekiq — pull request #1033 by jonhyman (2013-06-27 23:05:12+00:00)
Title: Minor optimization to just enqueue something now if it's set to perform_in the past or now

A really simple optimization to just go ahead and enqueue something now if it's set to perform_in now or in the past. The reason behind this tweak is that some of our code has an interface that takes in a time to perform, which could be immediate (Time.now) or in the future, and this will help it get processed faster in the former scenario -- it avoids the overhead of dealing with the zadd and also the potential few second timer delay from POLL_INTERVAL.

Given the triviality of this change, I didn't write a spec. Let me know if you think I should and I can update it.