This documentation is archived and is not being maintained.


Specifies settings for an instance of WorkflowRuntime for hosting workflow-based Windows Communication Foundation (WCF) services.

<workflowRuntime cachedInstanceExpiration="TimeSpan"
                    <add name="String" value="String" />
                    <add type="String"/>

The following sections describe attributes, child elements, and parent elements.


Attribute Description


An optional Timespan value that specifies the maximum duration a workflow instance can stay in-memory in idle state before it is forcefully unloaded or aborted. If the workflowruntime has PersistenceService which performs unloadOnIdle, this attribute is ignored.


An optional Boolean value that specifies whether performance counters are enabled. Performance counters provide information on various workflow-related statistics, but they cause a performance penalty when the workflow runtime engine starts, and when workflow instances are running. The default value is true.


A string containing the name of the workflow runtime engine. The name is used in output to distinguish this runtime from other runtimes that may be running on the system, for example, in performance counters.

The default is an empty string.


An optional Boolean value that specifies whether validation of workflow definition will occur when the WorkflowServiceHost is opened. When this attribute is set to true, the workflow validation is executed every time WorkflowServiceHost.Open is called. If validation errors are found, a WorkflowValidationFailedException error is thrown.

When this property is set to false, no Workflow definition validation will happen.

The default value for this property is true.

Child Elements

Element Description


A collection of common parameters used by services. This collection will typically include the database connection string that might be shared by durable services.


A collection of services that will be added to the WorkflowRuntime engine. The elements are of type WorkflowRuntimeServiceElement. The services specified in the collection will be initialized by the workflow runtime engine and added to its services when the appropriate WorkflowRuntime constructor is called. Therefore, the services specified in the collection must follow certain rules about the signatures of their constructors. See WorkflowRuntimeServiceElement for more information.

Parent Elements

Element Description

<behavior> of <endpointBehaviors>

Specifies a behavior element.

For more information on using a configuration file to control the behavior of a WorkflowRuntime object of a Windows Workflow Foundation host application, see Workflow Configuration Files.

   <behavior name="ServiceBehavior">
      <workflowRuntime name="WorkflowServiceHostRuntime"
            <add name="ConnectionString" value="Initial Catalog=WorkflowStore;Data Source=localhost;Integrated Security=SSPI;" />
            <add name="EnableRetries" value="True" />
             <add type="NetFx.Checkin.Scenario.WorkflowServices.WorkflowBasedServices.Common.TestPersistenceService.FilePersistenceService, NetFx.Checkin.Scenario.WorkflowServices.WorkflowBasedServices.Common"/>