Friday, September 5, 2014

Tomcat profile with JNDI datasource in RAD

Setup TOMCAT Profile with JNDI datasource inRAD

applicationContext-resources.xml


Step 1 :

<!-- This is a bean profile which can override items in the WebSphere profile for Tomcat like application servers. -->
    <!-- To activate this profile add -Dspring.profiles.active="tomcat" to your server startup, do not change the default profile setting in the web.xml -->
    <beans profile="tomcat">
        <bean id="transactionManager" class="org.springframework.orm.hibernate3.HibernateTransactionManager" p:sessionFactory-ref="sessionFactory" />

            <bean id="dataSource" destroy-method="close" class="org.apache.commons.dbcp.BasicDataSource">
              <property name="driverClassName" value="oracle.jdbc.driver.OracleDriver" />
              <property name="url" value="jdbc:oracle:thin:@rac.development.aamc.org:1521/AMCAS" />
              <property name="username" value="CFRANCISCO[mcat_thx]" />
              <property name="password" value="Aamc#2012" />
              <property name="maxActive" value="10" />
              <property name="maxIdle" value="1" />
              <property name="maxWait" value="1000" />
              <property name="defaultAutoCommit" value="true" />
              <property name="poolPreparedStatements" value="true" />
              <property name="maxOpenPreparedStatements" value="100" />
              <property name="validationQuery" value="SELECT 1 from DUAL"/>
            </bean>
    </beans>

Step 2:

To activate this profile add -Dspring.profiles.active="tomcat" to your server startup or JVM arguement.







1 comment:

  1. Betway App Review - JTM Hub
    Betway Casino 부산광역 출장마사지 is one of the 문경 출장마사지 best and newest 양산 출장마사지 sports betting options on the market. 이천 출장안마 Read our 부천 출장샵 review and get up to a £20 free bet today!

    ReplyDelete