Implement Connection pooling in JDBC using apache dbcp [duplicate]
问题 This question already has answers here : Am I Using JDBC Connection Pooling? (4 answers) Closed 3 years ago . Is this Good Code to implement pooling? I want to implement this in my project which has 30 threads operating concurrently and each thread requires more than four connection for each request? Does this code work? import java.sql.Connection; import java.sql.DriverManager; import java.sql.ResultSet; import java.sql.SQLException; import java.sql.Statement; import java.sql.Connection;