<?xml version='1.0' encoding='utf-8'?>
<!--
~ Hibernate, Relational Persistence for Idiomatic Java
~
~ License: GNU Lesser General Public License (LGPL), version 2.1 or later.
~ See the lgpl.txt file in the root directory or <http://www.gnu.org/licenses/lgpl-2.1.html>.
-->
<!DOCTYPE hibernate-configuration PUBLIC
"-//Hibernate/Hibernate Configuration DTD//EN"
"http://hibernate.sourceforge.net/hibernate-configuration-3.0.dtd">
<hibernate-configuration>
<session-factory>
<property name="hibernate.connection.driver_class">oracle.jdbc.driver.OracleDriver</property>
<property name="hibernate.connection.url">jdbc:oracle:thin:@localhost:1521:xe</property>
<property name="hibernate.connection.username">hr</property>
<property name="hibernate.connection.password">123</property>
<property name="hibernate.dialect">org.hibernate.dialect.Oracle10gDialect</property>
<property name="hibernate.hbm2ddl.auto">update</property>
<property name="current_session_context_class" >thread</property>
<property name="show_sql" >true</property>
<!-- <property name="hibernate.connection.pool_size">5</property>
<property name="hibernate.c3p0.min_size">50</property>
<property name="hibernate.c3p0.max_size">800</property>
<property name="hibernate.c3p0.max_statements">50</property>
<property name="hibernate.jdbc.batch_size">10</property>
<property name="hibernate.c3p0.timeout">300</property>
<property name="hibernate.c3p0.idle_test_period">3000</property>
<property name="hibernate.c3p0.testConnectionOnCheckout">true</property> -->
<!-- <property name="hibernate.connection.pool_size">5</property>
<property name="hibernate.jdbc.batch_size">10</property>
<property name="hibernate.connection.provider_class">proxool</property>
<property name="hibernate.proxool.properties">pool-one.properties</property>
<property name="hibernate.proxool.pool_alias">pool-one</property> -->
<!-- <property name="hibernate.cache.region_prefix">hibernate.test</property>
<property name="cache.use_query_cache">true</property>
<property name="cache.use_second_level_cache">true</property>
<property name="cache.use_structured_entries">true</property>
<property name="cache.region.factory_class">org.hibernate.cache.EhCacheRegionFactory</property>
<property name="net.sf.ehcache.configurationResourceName">file:///[PATH]/unmanaged-jpa/src/main/resources/ehcache.xml</property> -->
<!-- <property name="hibernate.cache.region_prefix">hibernate.test</property>
<property name="cache.use_query_cache">true</property>
<property name="cache.use_second_level_cache">true</property>
<property name="cache.use_structured_entries">true</property>
<property name="cache.region.factory_class">org.hibernate.cache.infinispan.InfinispanRegionFactory</property> -->
<!--<mapping class="org.hibernate.osgitest.entity.DataPoint"/>-->
<mapping resource="Mappings.hbm.xml"></mapping>
</session-factory>
</hibernate-configuration>
hibernate.cfg.xml
©著作权归作者所有,转载或内容合作请联系作者
- 文/潘晓璐 我一进店门,熙熙楼的掌柜王于贵愁眉苦脸地迎上来,“玉大人,你说我怎么就摊上这事。” “怎么了?”我有些...
- 文/花漫 我一把揭开白布。 她就那样静静地躺着,像睡着了一般。 火红的嫁衣衬着肌肤如雪。 梳的纹丝不乱的头发上,一...
- 文/苍兰香墨 我猛地睁开眼,长吁一口气:“原来是场噩梦啊……” “哼!你这毒妇竟也来了?” 一声冷哼从身侧响起,我...
推荐阅读更多精彩内容
- 首先看一个简的 hibernate.cfg.xml 单配置 下面就以上面这个简单的为例,对 hibernate.c...
- 在开发过程中,hibernate的配置是较为复杂的一部分。首先,就是hibernate.cfg.xml文件的配置,...
- Hibernate.cfg.xml配置文件结构详解 Hibernate中配置主要分为两种:一种包含了Hiberna...