`

websphere应用必看配置(spring jndi的配置)

 
阅读更多
websphere配置困扰我好找时间,配置的不对,websphere启动要半天才行。
终于在此博客中找到原因,在此做以记录。
spring jndi的配置 在不同容器中是不同的。

http://jlins.iteye.com/blog/679062

先在websphere和 weblogic里配置一个数据源,jndi名叫offsetJndi

spring里配置数据源  这种配置方法 websphere weblogic通用
<beans>  
<bean id="dataSource"  
class="org.springframework.jndi.JndiObjectFactoryBean">  
<property name="jndiName">  
<value>offsetJndi</value>  
</property>  





tomcat中使用如下方式

<beans>  
<bean id="dataSource"  
class="org.springframework.jndi.JndiObjectFactoryBean">  
<property name="jndiName">  
<value>java:comp/env/offsetJndi</value>  
</property> 
分享到:
评论

相关推荐

Global site tag (gtag.js) - Google Analytics