kenzi

AOP 본문

Spring

AOP

kenzi 2022. 4. 5. 14:37

DI는 object injection 이라면 

AOP는 process injection 이다 

 

AOP는 3개만 중점적으로 체크하자

포인트컷=<aop:pointcut>

aspect클래스=<aop:aspect>

advice =<aop:around/before..>

 

 

포인트컷 조건(어떤 메서드에 AOP걸거야?)에 맞는 메서드가 실행되면

aspect클래스에 있는 메서드가 advice(AOP가 걸리는 위치)에 따라 실행된다 

(JointPoint.proceed()가 핵심 서비스 메서드 실행 )

Comments