在春季项目中AOP最常见的用途是什么 [英] What is the most common use for AOP in spring project

查看:216
本文介绍了在春季项目中AOP最常见的用途是什么的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在审查了AOP模式之后,我对我在春季项目中如何使用它以及如何使用它的方式感到不知所措。

After reviewing the AOP pattern, I'm overwhelmed with the ways of how and what to use it for in my spring project.

我想将它用作所有财务业务逻辑的审计日志系统。它似乎很容易整合。但是我想听听你对此的看法。

I'd like to use it as audit log system of all the financial business logic. It just seems to be easy to integrate. But I'd like to hear your take on this.

问题是 - 我应该考虑哪种其他用途对于这种模式是常见的?只要有好处,我不介意重构我当前的逻辑与AOP一起使用。

The question is - what other uses should I consider that are common for this pattern? I would not mind refactoring my current logic to be used with AOP as long as there is benefits to it.

推荐答案

最常见的use可能是使用 @Transactional 进行声明式事务处理。

The most common use is probably the declarative transaction handling using @Transactional.

这篇关于在春季项目中AOP最常见的用途是什么的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆