SHARE
TWEET

Untitled

a guest Jul 14th, 2011 395 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <beans xmlns="http://www.springframework.org/schema/beans"
  3.         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  4.         xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.0.xsd">
  5.  
  6.         <!--DAO -->
  7.         <bean id="testServiceDAO" class="com.test.spring.ws.dao.impl.TestServiceDAOImpl">
  8.         <property name="sessionFactory" ref="sessionFactory"/>
  9.         </bean>
  10.         <!-- END DAO -->
  11.        
  12.         <!-- HIBERNATE -->
  13.         <bean id="propertyConfigurer"
  14.                 class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer">
  15.                 <property name="location" value="/WEB-INF/jdbc.properties" />
  16.         </bean>
  17.        
  18.         <bean id="dataSource" class="com.mchange.v2.c3p0.ComboPooledDataSource" destroy-method="close">
  19.         <property name="driverClass" value="${jdbc.driverClassName}" />
  20.         <property name="jdbcUrl" value="${jdbc.databaseurl}" />
  21.         <property name="user" value="${jdbc.username}" />
  22.         <property name="password" value="${jdbc.password}" />
  23.         <property name="acquireIncrement" value="5" />
  24.         <property name="idleConnectionTestPeriod" value="60"/>
  25.         <property name="maxPoolSize" value="100"/>
  26.         <property name="maxStatements" value="50"/>
  27.         <property name="minPoolSize" value="10"/>
  28.         </bean>
  29.  
  30.         <bean id="sessionFactory"
  31.                 class="org.springframework.orm.hibernate3.LocalSessionFactoryBean">
  32.                 <property name="dataSource" ref="dataSource" />
  33.                 <property name="mappingResources">
  34.                         <list>
  35.                                 <value>com/test/ws/mapping/TestDomain.hbm.xml</value>
  36.                         </list>
  37.                 </property>
  38.                 <property name="hibernateProperties">
  39.                         <props>
  40.                                 <prop key="hibernate.dialect">${jdbc.dialect}</prop>
  41.                                 <prop key="hibernate.show_sql">true</prop>
  42.                                 <prop key="hibernate.current_session_context_class">thread</prop>
  43.                         </props>
  44.                 </property>
  45.         </bean>
  46.  
  47.  
  48.         <bean id="transactionManager"
  49.                 class="org.springframework.orm.hibernate3.HibernateTransactionManager">
  50.                 <property name="sessionFactory" ref="sessionFactory" />
  51.         </bean>
  52.        
  53.         <!-- END HIBERNATE -->
  54.  
  55. <!-- SERVICE BEANS -->
  56. <bean id="testService" class="com.test.spring.ws.service.impl.TestServiceImpl">
  57.         <property name="testServiceDAO" ref="testServiceDAO"></property>
  58.         </bean>
  59. <!-- END SERVICE BEANS -->
  60. </beans>
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top