added hooks for after_success, after_completion, after_failure