http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.5.xsd
http://www.springframework.org/schema/tx http://www.springframework.org/schema/tx/spring-tx-2.5.xsd
http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop-2.5.xsd">
-
+
<!-- Services -->
<bean id="testManagerService" class="org.argeo.slc.services.impl.test.TestManagerServiceImpl">
<constructor-arg ref="testResultDao" />
<bean id="agentService" class="org.argeo.slc.services.impl.runtime.AgentServiceImpl">
<constructor-arg ref="slcAgentDescriptorDao" />
</bean>
+
+ <!-- Services transactions -->
+ <aop:config>
+ <aop:pointcut id="serviceMethods"
+ expression="execution(* org.argeo.slc.services.test.TestManagerService.*(..))" />
+ <aop:advisor advice-ref="serviceAdvice" pointcut-ref="serviceMethods" />
+ </aop:config>
+
+ <tx:advice id="serviceAdvice" transaction-manager="transactionManager">
+ <tx:attributes>
+ <tx:method name="*" propagation="REQUIRED" />
+ </tx:attributes>
+ </tx:advice>
+
</beans>
\ No newline at end of file