Hi,

I've tried 2 differents configs for managing tx in my app

The first one is fully parametered with annotations, i.e on each method
i've got :
Code:
@Transactional(readOnly = false,propagation= Propagation.REQUIRED)//, rollbackForClassName={"Throwable"})
Each time an exception is thrown (Throwable), the first exception thrown
is type with the exception that occured in the code. The problem with this issue is that i'm obliged to repeat thoses props on each method ( long ...)

The second way is using the AOP config (more centralized), il looks like this :
Code:
<tx:annotation-driven transaction-manager="txManager"  />

	<tx:advice id="txAdvice" transaction-manager="txManager">
		<tx:attributes>
			<tx:method name="*" rollback-for="Throwable" />
			<tx:method name="get*" read-only="true"/>
		</tx:attributes>
	</tx:advice>

	<aop:config>
    	<aop:pointcut id="serviceOperation" expression="execution(* com.company.service..*Service.*(..))"/>
    	<aop:advisor pointcut-ref="serviceOperation" advice-ref="txAdvice" />
  	</aop:config>
And there no annotation on the class.
In this 2nd way, the Exception thrown during a rollback case will be an UnexpectedRollbackException at first and MyException nested.

How to change the conf in order to have the real exception on top level ?
Thanks in advance


gz