garydgregory commented on a change in pull request #33: [DBCP-547] Add a 
ConnectionFactory interface in BasicDataSource.createConnectionFactory()
URL: https://github.com/apache/commons-dbcp/pull/33#discussion_r300067427
 
 

 ##########
 File path: src/main/java/org/apache/commons/dbcp2/BasicDataSource.java
 ##########
 @@ -2527,4 +2558,21 @@ private void updateJmxName(final 
GenericObjectPoolConfig<?> config) {
         config.setJmxNameBase(base.toString());
         config.setJmxNamePrefix(Constants.JMX_CONNECTION_POOL_PREFIX);
     }
+    
+    private ConnectionFactory getConnectionFactoryInstance(Driver driver)  
throws SQLException {
+       if (connectionFactoryClassName != null) {
+            try {
+               Class<?> connectionFactoryFromCCL = 
Class.forName(connectionFactoryClassName);
+               return (ConnectionFactory) 
connectionFactoryFromCCL.getConstructor(Driver.class, String.class, 
Properties.class)
+                                                                               
                                   .newInstance(driver, url, 
connectionProperties);
 
 Review comment:
   Fix weird formatting.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to