Regular |
 |
Joined: Sun Apr 13, 2008 3:04 am Posts: 71 Location: Bangalore
|
Like ant, does hibernate support import of another subset config..
This would ease xml configuration maintance. e.g
some thing like this
main.cfg.xml:
?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE hibernate-configuration PUBLIC
"-//Hibernate/Hibernate Configuration DTD 3.0//EN"
"http://hibernate.sourceforge.net/hibernate-configuration-3.0.dtd">
<hibernate-configuration>
<session-factory>
<import file="mysql.xml"/>
</session-factory>
</hibernate-configuration>
mysql.xml:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE hibernate-configuration PUBLIC
"-//Hibernate/Hibernate Configuration DTD 3.0//EN"
"http://hibernate.sourceforge.net/hibernate-configuration-3.0.dtd">
<hibernate-configuration>
<session-factory>
<property name="hibernate.connection.driver_class">
org.gjt.mm.mysql.Driver
</property>
<property name="hibernate.dialect">
com.tejasoft.utils.hibernate.TejaSQLDialect
</property>
<property name="hibernate.connection.username">tezzd</property>
<property name="hibernate.connection.password">abc123</property>
<property name="hibernate.connection.autoReconnect">true</property>
<property name="hibernate.connection.pool_size">4</property>
</session-factory>
</hibernate-configuration>
_________________ Raja Nagendra Kumar, C.T.O http://www.tejasoft.com TejaSoft - Specialists in Code Audit, Unit Testing and Merciless Re-factoring - Engineering Crisis Turnaround Experts
|
|