def schedule_job(job = nil)
      if can_schedule_job?(job)
        callback = ScheduledJob.config.fast_mode
        in_fast_mode = callback ? callback.call(self) : false

        run_at = in_fast_mode ? Time.now.utc + 1 : time_to_recur(Time.now.utc)

        Delayed::Job.enqueue(new, :run_at => run_at, :queue => queue_name)
      end
    end
def schedule_job(job = nil)
      if can_schedule_job?(job)
        callback = ScheduledJob.config.fast_mode
        in_fast_mode = callback ? callback.call(self) : false

        run_at = in_fast_mode ? Time.now.utc + 1 : time_to_recur(Time.now.utc)

        Delayed::Job.enqueue(new, :run_at => run_at, :queue => queue_name)
      end
    end
This method should be called when scheduling a recurring job as it checks to ensure no
 other instances of the job are already running.