refactored triggering for job