Solve the use of declaration transactions in spring java.lang.NoClassDefFoundError: org/aspectj/util/PartialOrder$PartialComparable

The declarative transaction configuration used in spring is as follows:

<!– ================================Transaction related control=========== ============= –>
<bean name=”transactionManager”
class=”org.springframework.jdbc.datasource.DataSourceTransactionManager”>
<property name=”dataSource” ref=”dataSource”> </property>
</bean>
<tx:advice id=”txAdvice” transaction-manager=”transactionManager”>
<tx:attributes>
<tx:method name=”delete*” propagation=”REQUIRED” read-only=” false”
rollback-for=”java.lang.Exception” no-rollback-for=”java.lang.RuntimeException” />
<tx:method name=”insert*” propagation=”REQUIRED” read-only=”false”
rollback-for=”java.lang.RuntimeException” />
<tx:method name=”update*” propagation=”REQUIRED” read-only=”false”
rollback-for=”java.lang.Exception” />
<tx:method name=”find*” propagation=”SUPPORTS” />
<tx:method name=”get*” propagation=”SUPPORTS” />
<tx: method name=”select*” propagation=”SUPPORTS” />
</tx:attributes>
</tx:advice>
<aop:config>
<aop:pointcut id=”pc”
expression=”execution(public * com.framework ..*.*(..))” />
<aop:advisor pointcut-ref=”pc” advice-ref=”txAdvice” />
</aop:config>

The console reports an error when starting the program: java.lang. NoClassDefFoundError: org/aspectj/util/PartialOrder$PartialComparable.
Reason for error: missing jar package, aspectjweaver-1.5.2.jar


Read More:

Leave a Reply

Your email address will not be published. Required fields are marked *