added lastSync field and shouldSync method to Job model