WorkflowUnhandledExceptionBehavior Class

WorkflowUnhandledExceptionBehavior Class

.NET Framework (current version)
 

A service behavior that enables you to specify the action to take when an unhandled exception occurs within a workflow service.

Namespace:   System.ServiceModel.Activities.Description
Assembly:  System.ServiceModel.Activities (in System.ServiceModel.Activities.dll)

System.Object
  System.ServiceModel.Activities.Description.WorkflowUnhandledExceptionBehavior

public class WorkflowUnhandledExceptionBehavior : IServiceBehavior

NameDescription
System_CAPS_pubmethodWorkflowUnhandledExceptionBehavior()

Initializes a new instance of the WorkflowUnhandledExceptionBehavior class.

NameDescription
System_CAPS_pubpropertyAction

Gets or sets the action to take when an unhandled exception occurs.

NameDescription
System_CAPS_pubmethodAddBindingParameters(ServiceDescription, ServiceHostBase, Collection<ServiceEndpoint>, BindingParameterCollection)

Implements the IServiceBehavior.AddBindingParameters method to support the behavior.

System_CAPS_pubmethodApplyDispatchBehavior(ServiceDescription, ServiceHostBase)

Implements the IServiceBehavior.ApplyDispatchBehavior method to support the behavior.

System_CAPS_pubmethodEquals(Object)

Determines whether the specified object is equal to the current object.(Inherited from Object.)

System_CAPS_protmethodFinalize()

Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.(Inherited from Object.)

System_CAPS_pubmethodGetHashCode()

Serves as the default hash function. (Inherited from Object.)

System_CAPS_pubmethodGetType()

Gets the Type of the current instance.(Inherited from Object.)

System_CAPS_protmethodMemberwiseClone()

Creates a shallow copy of the current Object.(Inherited from Object.)

System_CAPS_pubmethodToString()

Returns a string that represents the current object.(Inherited from Object.)

System_CAPS_pubmethodValidate(ServiceDescription, ServiceHostBase)

Implements the IServiceBehavior.Validate method to support the behavior.

Both OnUnhandledException and WorkflowUnhandledExceptionBehavior dictate the behavior of the runtime when an exception is not handled in the workflow; however, WorkflowUnhandledExceptionBehavior has the option of leaving a suspended workflow in the persistence store, while OnUnhandledException does not. The reason for this is that what happens to a suspended workflow is host-specific, and WorkflowApplication is not. To implement this functionality using WorkflowApplication, create a custom PersistenceParticipant that has this behavior.

For an example of how to use this behavior see Workflow Service Host Extensibility.

.NET Framework
Available since 4.0

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

Return to top
Show:
© 2016 Microsoft