Pool and shares connections
- Last UpdatedJul 19, 2024
- 1 minute read
Multiple instances of the SQLDataGrid configured with identical connection strings use a shared connection pool and SQL command queue when they are active in the same instances of the InTouch WindowViewer. To limit the size of the shared pool, you can use the connection pool property MaxConnections. For configuration options, see Custom Properties for the SQLDataGrid Graphic.
Physical connections to the SQL database are opened based on command requests and are closed when no requests are pending. All SQL commands are queued and processed based on availability of connections and processing time.
The SQLDataGrid asynchronously processes all SQL commands. Asynchronous command processing ensures availability of interaction with the InTouch WindowViewer during time-consuming command processing.
Any database connection that is established in a script within a graphic using the SQLData Script Library also takes advantage of connection pooling. Similar connection strings from either the SQLDataGrid or the script in the same InTouchView application share a common pool.
Note: Connection sharing and connection pooling require that the same security mode and user credentials be used for all SQLDataGrid graphics within the InTouchView application that shares the connection or the pool.