17,741
社区成员
发帖
与我相关
我的任务
分享
<db:provider id="DbProvider"
connectionString="Data Source=196.1.208.57;port=3306;user id=Kxx;password=Kinxxxxxxx;Initial Catalog=KsPushNew"
provider="MySql"/>
<object id="transactionManager"
type="Spring.Data.Core.AdoPlatformTransactionManager, Spring.Data">
<property name="DbProvider" ref="DbProvider"/>
</object>
<object id="adoTemplate" type="Spring.Data.AdoTemplate, Spring.Data">
<property name="DbProvider" ref="DbProvider"/>
</object>
<tx:advice id="txAdvice" transaction-manager="transactionManager">
<tx:attributes>
<tx:method name="Save*"/>
<tx:method name="Delete*"/>
</tx:attributes>
</tx:advice>
<!--<tx:attribute-driven transaction-manager="transactionManager"/>-->
<object id="txPointCut" type="Spring.Aop.Support.SdkRegularExpressionMethodPointcut,Spring.Aop">
<property name="Pattern" value=".*erv*"/>
</object>
<aop:config>
<!--<aop:advisor id="getDescriptionAdvisor" pointcut-ref="SdkRegularExpressionMethodPointcut" advice-ref="TestAfterAdvice"/>-->
<!--<aop:advisor id="transactionAdvisor" pointcut-ref="txPointCut" advice-ref="txAdvice"></aop:advisor>-->
<aop:advisor pointcut-ref="txPointCut" advice-ref="txAdvice"/>
</aop:config>
errorError creating context 'spring.root': Error thrown by a dependency of object 'txAdvice' : Initialization of object failed : 未将对象引用设置到对象的实例。
while resolving 'transactionManager' to 'transactionManager' defined in 'config [d:\documents\visual studio 2015\Projects\KsPushNew\KsTest\bin\Debug\KsTest.dll.config#spring/objects] line 1'