Skip to content

Commit df69a3b

Browse files
Laurent RICHARDbrmeyer
authored andcommitted
HHH-8302 init c3p0 initialPoolSize with minPoolSize
Adding C3P0_STYLE_INITIAL_POOL_SIZE directly to c3props doesn't work because of prefix "c3p0." Using setOverwriteProperty checks for the nullability of the value and removes this prefix Conflicts: hibernate-c3p0/src/main/java/org/hibernate/c3p0/internal/C3P0ConnectionProvider.java
1 parent 08a32f7 commit df69a3b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

hibernate-c3p0/src/main/java/org/hibernate/service/jdbc/connections/internal/C3P0ConnectionProvider.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -188,7 +188,7 @@ public void configure(Map props) {
188188
// unless otherwise specified with a c3p0.*-style parameter.
189189
Integer initialPoolSize = ConfigurationHelper.getInteger( C3P0_STYLE_INITIAL_POOL_SIZE, props );
190190
if ( initialPoolSize == null && minPoolSize != null ) {
191-
c3props.put( C3P0_STYLE_INITIAL_POOL_SIZE, String.valueOf( minPoolSize ).trim() );
191+
setOverwriteProperty( "", C3P0_STYLE_INITIAL_POOL_SIZE, props, c3props, minPoolSize );
192192
}
193193

194194
/*DataSource unpooled = DataSources.unpooledDataSource(

0 commit comments

Comments
 (0)