refactoring connection pool classes and introduced a new ConnectionPool.