2009-04-14 17:51:03 +02:00
|
|
|
<?xml version="1.0" encoding="UTF-8"?>
|
|
|
|
|
|
|
|
|
|
<beans xmlns="http://www.springframework.org/schema/beans"
|
2009-05-14 19:19:59 +02:00
|
|
|
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:p="http://www.springframework.org/schema/p"
|
|
|
|
|
xmlns:tx="http://www.springframework.org/schema/tx" xmlns:context="http://www.springframework.org/schema/context"
|
2009-04-14 17:51:03 +02:00
|
|
|
xsi:schemaLocation="
|
|
|
|
|
http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.5.xsd
|
|
|
|
|
http://www.springframework.org/schema/tx http://www.springframework.org/schema/tx/spring-tx-2.5.xsd
|
|
|
|
|
http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-2.5.xsd">
|
2009-05-14 19:19:59 +02:00
|
|
|
|
2009-04-14 17:51:03 +02:00
|
|
|
<!-- Data source. -->
|
2009-05-14 19:19:59 +02:00
|
|
|
<bean id="dataSource" class="org.springframework.jndi.JndiObjectFactoryBean"
|
|
|
|
|
p:jndiName="${dataSource.jndiName}" p:resourceRef="true" />
|
|
|
|
|
|
2009-08-05 14:07:15 +02:00
|
|
|
<!-- Letting Spring do automatically exception translation -->
|
|
|
|
|
<bean class="org.springframework.dao.annotation.PersistenceExceptionTranslationPostProcessor"/>
|
|
|
|
|
|
2009-04-14 17:51:03 +02:00
|
|
|
<!-- Hibernate Session Factory. -->
|
|
|
|
|
<bean id="sessionFactory"
|
2009-07-30 09:35:03 +02:00
|
|
|
class="org.springframework.orm.hibernate3.LocalSessionFactoryBean"
|
|
|
|
|
p:dataSource-ref="dataSource" p:configLocation="classpath:/navalplanner-business-hibernate.cfg.xml">
|
2009-05-14 19:19:59 +02:00
|
|
|
|
2009-04-14 17:51:03 +02:00
|
|
|
<property name="mappingResources">
|
|
|
|
|
<list>
|
2009-07-30 09:35:03 +02:00
|
|
|
<value>
|
|
|
|
|
org/navalplanner/business/advance/entities/Advance.hbm.xml
|
|
|
|
|
</value>
|
2009-05-14 19:19:59 +02:00
|
|
|
<value>
|
|
|
|
|
org/navalplanner/business/resources/entities/Resources.hbm.xml
|
|
|
|
|
</value>
|
2009-05-28 20:19:12 +02:00
|
|
|
<value>
|
2009-06-24 15:53:08 +02:00
|
|
|
org/navalplanner/business/orders/entities/Orders.hbm.xml
|
2009-05-28 20:19:12 +02:00
|
|
|
</value>
|
2009-07-07 21:37:11 +02:00
|
|
|
<value>
|
|
|
|
|
org/navalplanner/business/planner/entities/Tasks.hbm.xml
|
|
|
|
|
</value>
|
2009-07-24 13:45:01 +02:00
|
|
|
<value>
|
|
|
|
|
org/navalplanner/business/planner/entities/ResourceAllocations.hbm.xml
|
|
|
|
|
</value>
|
2009-07-15 12:22:41 +02:00
|
|
|
<value>
|
|
|
|
|
org/navalplanner/business/workreports/entities/WorkReports.hbm.xml
|
|
|
|
|
</value>
|
2009-08-13 13:00:55 +02:00
|
|
|
<value>
|
|
|
|
|
org/navalplanner/business/calendars/entities/Calendars.hbm.xml
|
|
|
|
|
</value>
|
2009-09-14 09:07:51 +02:00
|
|
|
<value>
|
|
|
|
|
org/navalplanner/business/labels/entities/Labels.hbm.xml
|
|
|
|
|
</value>
|
2009-10-27 16:25:14 +01:00
|
|
|
<value>
|
|
|
|
|
org/navalplanner/business/requirements/entities/Requirements.hbm.xml
|
|
|
|
|
</value>
|
2009-11-17 12:36:14 +01:00
|
|
|
<value>
|
|
|
|
|
org/navalplanner/business/common/entities/Configuration.hbm.xml
|
|
|
|
|
</value>
|
2009-11-23 10:46:52 +01:00
|
|
|
<value>
|
|
|
|
|
org/navalplanner/business/materials/entities/Materials.hbm.xml
|
|
|
|
|
</value>
|
2009-11-26 15:28:43 +01:00
|
|
|
<value>
|
|
|
|
|
org/navalplanner/business/users/entities/Users.hbm.xml
|
|
|
|
|
</value>
|
2009-07-30 09:35:03 +02:00
|
|
|
</list>
|
2009-04-14 17:51:03 +02:00
|
|
|
</property>
|
|
|
|
|
</bean>
|
2009-05-14 19:19:59 +02:00
|
|
|
|
2009-04-14 17:51:03 +02:00
|
|
|
<!-- Spring Transaction manager -->
|
|
|
|
|
<bean id="transactionManager"
|
|
|
|
|
class="org.springframework.orm.hibernate3.HibernateTransactionManager"
|
2009-05-14 19:19:59 +02:00
|
|
|
p:sessionFactory-ref="sessionFactory" />
|
|
|
|
|
|
|
|
|
|
<!--
|
2009-07-30 09:35:03 +02:00
|
|
|
Enable configuration of transactional behavior based on annotations
|
2009-05-14 19:19:59 +02:00
|
|
|
-->
|
|
|
|
|
<tx:annotation-driven transaction-manager="transactionManager" />
|
|
|
|
|
|
|
|
|
|
<!--
|
2009-05-15 16:05:06 +02:00
|
|
|
For enabling annotation-based configuration (in particular, required
|
|
|
|
|
for "@Autowired")
|
2009-05-14 19:19:59 +02:00
|
|
|
-->
|
|
|
|
|
<context:annotation-config />
|
|
|
|
|
|
2009-07-30 09:35:03 +02:00
|
|
|
<context:component-scan base-package="org.navalplanner.business" />
|
2009-05-15 16:05:06 +02:00
|
|
|
|
2009-08-07 17:06:15 +02:00
|
|
|
<bean id="registry"
|
|
|
|
|
class="org.navalplanner.business.common.Registry"
|
|
|
|
|
factory-method="getInstance" />
|
|
|
|
|
|
2009-11-09 18:31:35 +01:00
|
|
|
<bean id="CriterionRequirementHandler"
|
|
|
|
|
class="org.navalplanner.business.orders.entities.CriterionRequirementHandler"
|
|
|
|
|
factory-method="getInstance" />
|
|
|
|
|
|
2009-04-14 17:51:03 +02:00
|
|
|
</beans>
|