Hello,
I would like to finalize the upgrade of hibernate.
The system used v2.1 and recently i´ve migrate to v3.1.
It was successfull and the program works fine, but every time i start the app the info below is printed:
INFO DriverManagerConnectionProvider:41 - Using Hibernate built-in connection pool (not for production use!)
My problem is the necessity of a connection pool to be used in production enviroment.
The file cfg.xml is attached at the end of this message.
I have two questions for the community:
1. Which pool do you prefer for production env ?
2. Does anyone know the reason why the DBCP is not running ?
I am thankful anticipatedly and waiting for some reply.
Raphael
<?xml version='1.0' encoding='utf-8'?>
<!DOCTYPE hibernate-configuration PUBLIC
"-//Hibernate/Hibernate Configuration DTD//EN"
"http://hibernate.sourceforge.net/hibernate-configuration-3.0.dtd">
<hibernate-configuration>
<session-factory>
<!-- Postgre SQL -->
<property name="hibernate.connection.driver_class">org.postgresql.Driver</property>
<property name="hibernate.connection.url">jdbc:postgresql://10.0.0.159/internet</property>
<property name="hibernate.connection.username">postgres</property>
<property name="hibernate.connection.password">1234</property>
<!-- property name="hibernate.connection.pool_size">10</property-->
<property name="hibernate.show_sql">true</property>
<property name="hibernate.dialect">org.hibernate.dialect.PostgreSQLDialect</property>
<property name="hibernate.hbm2ddl.auto">update</property>
<!-- novas propriedades em teste -->
<property name="hibernate.connection.autocommit">false</property>
<property name="hibernate.max_fetch_depth">0</property>
<!-- pool de conexões -->
<property name="hibernate.connection.pool_size">10</property>
<property name="hibernate.statement_cache.size">6</property>
<property name="hibernate.dbcp.initialSize">10</property>
<property name="hibernate.dbcp.validationQuery">select 1</property>
<property name="hibernate.dbcp.defaultAutoCommit">false</property>
<property name="hibernate.dbcp.maxActive">20</property>
<property name="hibernate.dbcp.maxIdle">5</property>
<property name="hibernate.dbcp.minIdle">1</property>
<property name="hibernate.dbcp.maxWait">30000</property>
<property name="hibernate.dbcp.testOnBorrow">false</property>
<property name="hibernate.dbcp.poolPreparedStatements">true</property>
<!--property name="hibernate.dbcp.maxOpenPreparedStatements">20</property-->
<property name="hibernate.dbcp.removeAbandoned">false</property>
<property name="query.substitutions">yes 'Y', no 'N'</property>
<!-- fim das novas propriedades em teste -->
<!-- mapping Access Control files -->
<mapping resource="domain/Vestibulando.hbm.xml" />
</session-factory>
</hibernate-configuration>
|