private void ExecuteCompensatingOperation() { BehaviorWasApplied("Executing compensating operation"); var context = OperationContext.Create(InnerOperation.GetInnermostOperation()); context.ProvideInputs(_operation); _operation.Execute(); }
/// <summary> /// Register the application of a behavior. Use this when the behavior causes the normal /// execution flow to be abandoned, documenting what happened. Behavior that has no impact /// on the execution should not be registered. /// </summary> /// <param name="description">A text describing how the workflow was modified by the behavior</param> protected void BehaviorWasApplied(string description) { Verify.NotNull(description, nameof(description)); _logger?.BehaviorWasApplied(InnerOperation.GetInnermostOperation(), this, description); }
private bool Log(Exception e) { _logger.OperationFailed(InnerOperation.GetInnermostOperation(), e); return(false); }