This article refers to legacy products, components or features. Therefore, the content in this article is offered "as is" and will no longer be updated. This content does not infer that the product, component or feature is supported, or that the product, component or feature will continue to function as described herein.
When retrieving large volumes of data (i.e., a large number of process instances) via the Management Tools in K2 Workspace, the following error may be received: "Timeout Expired: The timeout period elapsed prior to obtaining a connection from the pool. This may have occurred because all pooled connections were in use and max pool size was reached" as shown in the figure below:[Figure 1. Time out error from K2 Workspace]
The error will occur on standalone and/or distributed installations.
|Note: Rebooting the K2 Server does not resolve the problem.|
|Note: The details below describe symptoms from systems where the error has been known to occur.|
The K2 developer is attempting to view a large number of process via the Management Tools in K2 Workspace with the following items installed:
- Microsoft .NET Framework 2.0 SP1
- K2 blackpearl SP1
The following error message relates to this KB Article:
- Timeout expired. The timeout period elapsed prior to obtaining a connection from the pool. This may have occurred because all pooled connections were in use and max pool size was reached.
The error is caused by the Max Pool Size configuration setting being too small. Increase the Max Pool Size by following these steps:
Important: With the release of K2 4.6.9 the SourceCode.Workflow.Runtime.Management.config has been consolidated into a single configuration file called K2HostServer.exe.Config file, which is located in the \K2 blackpearl\Host Server\Bin folder on the K2 Server. The connection strings previously stored in these files are now retrieved from the K2HostServer.exe.Config file.
- Browse to the installation directory of the K2 blackpearl Server (e.g., C:\Program Files\K2 Blackpearl\Host Server\Bin)
- Locate the following file: SourceCode.Workflow.Runtime.Management.config
- Open the file with a text editor (e.g., Notepad)
- Locate the configuration section that begins with <add name="K2"...
- Alter the connectionString attribute to contain this additional information: Max Pool Size=1000000;
The configuration section should look similar to this:
<add name="K2" connectionString="Data Source=localhost;Initial Catalog=K2Server;Integrated Security=SSPI;Max Pool Size=1000000"/>
Restart the K2 Server