|
锁定老贴子 主题:终于可以发帖了,重发spring 事务问题
精华帖 (0) :: 良好帖 (0) :: 新手帖 (0) :: 隐藏帖 (0)
|
|
|---|---|
| 作者 | 正文 |
|
最后更新时间:2007-07-02
<bean id="dataSource" class="org.apache.commons.dbcp.BasicDataSource" destroy-method="close">
<property name="driverClassName" value="${jdbc.driverClassName}" />
<property name="url" value="${jdbc.url}" />
<property name="username" value="${jdbc.username}" />
<property name="password" value="${jdbc.password}" />
<!-- property name="defaultAutoCommit"><value>false</value></property-->
</bean>
<bean id="transactionManager" class="org.springframework.jdbc.datasource.DataSourceTransactionManager">
<property name="dataSource" ref="dataSource" />
</bean>
<bean id="txAttribute"
class="org.springframework.transaction.interceptor.NameMatchTransactionAttributeSource">
<property name="properties">
<props>
<prop key="update*">PROPAGATION_REQUIRED</prop>
<prop key="*">PROPAGATION_REQUIRED,readOnly</prop>
</props>
</property>
</bean>
<bean id="txInterceptor"
class="org.springframework.transaction.interceptor.TransactionInterceptor">
<property name="transactionManager"><ref bean="transactionManager"/></property>
<property name="transactionAttributeSource"><ref bean="txAttribute"/></property>
</bean>
<bean id="autoProxyCreator" class="org.springframework.aop.framework.autoproxy.BeanNameAutoProxyCreator">
<property name="interceptorNames">
<list>
<idref local="txInterceptor"/>
</list>
</property>
<property name="beanNames"><value>*Action</value></property>
</bean>
<bean id="securityInterceptor" class="com.safetys.sqldao.Advice"/>
<bean id="sqlMapClientFactoryBean" class="org.springframework.orm.ibatis.SqlMapClientFactoryBean">
<property name="configLocation" value="WEB-INF/sql-map-config.xml"/>
<property name="dataSource" ref="dataSource"/>
</bean>
<bean id="flowAction" class="com.safetys.action.FlowAction" scope="prototype">
<property name="sqldao" value="com.safetys.sqldao.FlowDao"></property>
<property name="sqldao2" value="com.safetys.sqldao.CommonDao"></property>
<property name="service" value="com.safetys.service.FlowService"></property>
</bean>
<bean id="logonAction" class="com.safetys.action.LogonAction" scope="prototype">
<property name="sqldao" value="com.safetys.sqldao.LogonDao"></property>
<property name="service" value="com.safetys.service.LogonService"></property>
</bean>
</beans>
这是我的配置文件,麻烦了.可能我的问题是有点简单了 |
|
| 返回顶楼 | |
|
最后更新时间:2007-07-03
如果可能,可以把异常信息贴出来么?
|
|
| 返回顶楼 | |
|
最后更新时间:2007-07-03
我是建议你加入spring的源码去debug下,看下究竟发生了什么。
|
|
| 返回顶楼 | |



