急救!!!!!!!!!多谢大家了!!!!!!!!!!!!!!!!!在线等 把Spring的配置文件贴出来看看 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 spring配置文件<?xml version='1.0' encoding='utf-8'?><!DOCTYPE beans PUBLIC "-//SPRING//DTD BEAN//EN" "http://www.springframework.org/dtd/spring-beans.dtd"><beans> <!-- ========================= GENERAL DEFINITIONS ========================= --> <!-- Configurer that replaces ${...} placeholders with values from properties files --> <!-- (in this case, mail and JDBC related properties) --> <bean id="propertyConfigurer" class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer"> <property name="locations"> <list> <value>WEB-INF/datasource.properties</value> </list> </property> </bean> <!--Init datasource--> <!--Oracle DataSource--> <bean id="dataSource" class="org.apache.commons.dbcp.BasicDataSource" destroy-method="close"> <property name="driverClassName"> <value>${jdbc.driver.class}</value> </property> <property name="url"> <value>${jdbc.url}</value> </property> <property name="username"> <value>${jdbc.user}</value> </property> <property name="password"> <value>${jdbc.password}</value> </property> <property name="maxActive"> <value>${pool.maxActive}</value> </property> <property name="maxIdle"> <value>${pool.maxIdle}</value> </property> <property name="maxWait"> <value>${pool.maxWait}</value> </property> </bean> <!-- TransactionManager --> <bean id="transactionManager" class="org.springframework.jdbc.datasource.DataSourceTransactionManager"> <property name="dataSource"> <ref local="dataSource"/> </property> </bean> <!-- statDaoProxy --> <bean id="statDaoProxy" class="org.springframework.transaction.interceptor.TransactionProxyFactoryBean"> <property name="transactionManager"> <ref bean="transactionManager"></ref> </property> <property name="target"> <ref local="statDao"></ref> </property> <property name="transactionAttributes"> <props> <prop key="insert*">PROPAGATION_REQUIRED</prop> <prop key="update*">PROPAGATION_REQUIRED</prop> <prop key="*">PROPAGATION_REQUIRED,readOnly</prop> </props> </property> </bean> <!--StatDao--> <bean id="statDao" class="com.asiainfo.wap.stat.dao.StatDaoJdbcImpl"> <property name="dataSource"> <ref bean="dataSource"/> </property> </bean> <!-- StatService --> <bean id="statSev" class="com.asiainfo.wap.stat.bo.StatService"> <property name="statDao"> <ref local="statDaoProxy"></ref> </property> </bean> <!-- userDaoProxy --> <bean id="userDaoProxy" class="org.springframework.transaction.interceptor.TransactionProxyFactoryBean"> <property name="transactionManager"> <ref bean="transactionManager"></ref> </property> <property name="target"> <ref local="userDao"></ref> </property> <property name="transactionAttributes"> <props> <prop key="insert*">PROPAGATION_REQUIRED</prop> <prop key="update*">PROPAGATION_REQUIRED</prop> <prop key="*">PROPAGATION_REQUIRED,readOnly</prop> </props> </property> </bean> <!--userDao--> <bean id="userDao" class="com.asiainfo.wap.user.dao.UserDaoJdbcImpl"> <property name="dataSource"> <ref bean="dataSource"/> </property> </bean> <!-- userService --> <bean id="userSev" class="com.asiainfo.wap.user.bo.UserService"> <property name="userDao"> <ref local="userDaoProxy"></ref> </property> </bean></beans> 应该是网络原因引起的。你catch住后回滚下次再处理好了饿 找到原因了 <property name="removeAbandoned"> <value>${pool.removeAbandoned}</value> </property> <property name="removeAbandonedTimeout"> <value>${pool.removeAbandonedTimeout}</value> </property> <property name="logAbandoned"> <value>${pool.logAbandoned}</value> </property> 在配置文档中增加垃圾回收的配置 ,以前没有用过spring自身TransactionProxyFactoryBean事务管理,都是自己手动关闭,所以没注意这个垃圾回收的配置,呵呵,谢谢大家 itext表格边框问题 关于Japplet中的init方法的调用问题 java后台实现调用ocx Lazy 属性问题 - 4.0.4RC1 - EJB3.0RC5-PFD EJB 依赖注入问题 weblogic8.1启动时提示:Authentication for user weblogic denied j2ee1.4sdk自带的Deploytool的一个问题 我装了一个JBUILDER9怎么ENTERPRISE不能用? 做Java应用程序,想看看书,有什么好书介绍? 希望大佬相助 poi.jar在哪下载啊? 关于tomcat5.5.17的虚拟路径和servlet的问题,急,在线等待
<?xml version='1.0' encoding='utf-8'?>
<!DOCTYPE beans PUBLIC "-//SPRING//DTD BEAN//EN"
"http://www.springframework.org/dtd/spring-beans.dtd">
<beans>
<!-- ========================= GENERAL DEFINITIONS ========================= -->
<!-- Configurer that replaces ${...} placeholders with values from properties files -->
<!-- (in this case, mail and JDBC related properties) -->
<bean id="propertyConfigurer" class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer">
<property name="locations">
<list>
<value>WEB-INF/datasource.properties</value>
</list>
</property>
</bean>
<!--Init datasource-->
<!--Oracle DataSource-->
<bean id="dataSource"
class="org.apache.commons.dbcp.BasicDataSource"
destroy-method="close">
<property name="driverClassName">
<value>${jdbc.driver.class}</value>
</property>
<property name="url">
<value>${jdbc.url}</value>
</property>
<property name="username">
<value>${jdbc.user}</value>
</property>
<property name="password">
<value>${jdbc.password}</value>
</property>
<property name="maxActive">
<value>${pool.maxActive}</value>
</property>
<property name="maxIdle">
<value>${pool.maxIdle}</value>
</property>
<property name="maxWait">
<value>${pool.maxWait}</value>
</property>
</bean>
<!-- TransactionManager -->
<bean id="transactionManager" class="org.springframework.jdbc.datasource.DataSourceTransactionManager">
<property name="dataSource">
<ref local="dataSource"/>
</property>
</bean>
<!-- statDaoProxy -->
<bean id="statDaoProxy"
class="org.springframework.transaction.interceptor.TransactionProxyFactoryBean">
<property name="transactionManager">
<ref bean="transactionManager"></ref>
</property>
<property name="target">
<ref local="statDao"></ref>
</property>
<property name="transactionAttributes">
<props>
<prop key="insert*">PROPAGATION_REQUIRED</prop>
<prop key="update*">PROPAGATION_REQUIRED</prop>
<prop key="*">PROPAGATION_REQUIRED,readOnly</prop>
</props>
</property>
</bean>
<!--StatDao-->
<bean id="statDao"
class="com.asiainfo.wap.stat.dao.StatDaoJdbcImpl">
<property name="dataSource">
<ref bean="dataSource"/>
</property>
</bean>
<!-- StatService -->
<bean id="statSev" class="com.asiainfo.wap.stat.bo.StatService">
<property name="statDao">
<ref local="statDaoProxy"></ref>
</property>
</bean>
<!-- userDaoProxy -->
<bean id="userDaoProxy"
class="org.springframework.transaction.interceptor.TransactionProxyFactoryBean">
<property name="transactionManager">
<ref bean="transactionManager"></ref>
</property>
<property name="target">
<ref local="userDao"></ref>
</property>
<property name="transactionAttributes">
<props>
<prop key="insert*">PROPAGATION_REQUIRED</prop>
<prop key="update*">PROPAGATION_REQUIRED</prop>
<prop key="*">PROPAGATION_REQUIRED,readOnly</prop>
</props>
</property>
</bean>
<!--userDao-->
<bean id="userDao"
class="com.asiainfo.wap.user.dao.UserDaoJdbcImpl">
<property name="dataSource">
<ref bean="dataSource"/>
</property>
</bean>
<!-- userService -->
<bean id="userSev" class="com.asiainfo.wap.user.bo.UserService">
<property name="userDao">
<ref local="userDaoProxy"></ref>
</property>
</bean>
</beans>
<value>${pool.removeAbandoned}</value>
</property>
<property name="removeAbandonedTimeout">
<value>${pool.removeAbandonedTimeout}</value>
</property>
<property name="logAbandoned">
<value>${pool.logAbandoned}</value>
</property> 在配置文档中增加垃圾回收的配置 ,以前没有用过spring自身TransactionProxyFactoryBean事务管理,都是自己手动关闭,所以没注意这个垃圾回收的配置,呵呵,谢谢大家