Refactor and improve Resque jobs and tasks