How to close JDBC Connection in jmeter

Viewed 1692

I'm using JDBC connection configuration and JDBC request sampler to fetch test data from database for large set of data for my test requirement. My question is, if we connecting to database through connection configuration and JDBC sampler to fetch data from database then how we can close the connection from database like we are having other performance testing tool Neoload. As of now what i'm seeing from total number of active connections in sql server using sp_who2 or below query is that JDBC connection not closed after jmeter test execution completed. Question is, How to closed JDBC connection if my purpose to use is completed within the script execution? Any help would be appreciated.

2 Answers

There's an issue with JDBC Connection Configuration when using connection pooling

Maximum number of connections allowed in the pool. In most cases, set this to zero (0). This means that each thread will get its own pool with a single connection in it, i.e. the connections are not shared between threads.

If you set 0 connections and problem still persist, open an issue for JMeter

Related