본문 바로가기

Spring4

[Spring] Spring MVC 흐름 Spring MVC 🍀 특징 - DI, AOP 같은 기능 뿐만 아니라, Servlet 기반의 WEB 개발을 위한 MVC Framework 제공 - Model2 Architecture와 Front Controller Pattern을 Framework 차원에서 제공 - Spring이 제공하는 Transaction 처리나 DI 및 AOP등을 손쉽게 사용 🌺 구성 요소 DispatcherServlet (Front Contoller) - 모든 클라이언트의 요청을 전달받음 - Controller에게 클라이언트의 요청을 전달하고, Controller가 리턴한 결과값을 View에게 전달하여 알맞은 응답 생성. HandlerMapping - 클라이언트 요청 URL을 어떤 Controller가 처리할지를 결정 - URL과.. 2022. 4. 20.
[Spring] DI(Dependency Injection) Annotation 🔎 Dependency Injection - 객체 간의 의존관계를 자신이 아닌 외부의 조립기가 수행 - 제어의 역행(Inversion of Control, IoC)이라는 의미로 사용 - DI를 통해 시스템에 있는 각 객체를 조정하는 외부 객체가 객체들에게 생성시에 의존관계 주어짐 - 느슨한 결합(loose coupling)의 주요 강점 ✅ Annotation 🦎 Stereotype - 빈 자동등록에 사용할 수 있음 - 계층별로 빈의 특성이나 종류를 구분하기 위해서 annotation이 여러 개 - AOP Pointcut 표현식을 사용하면 특정 annotation이 달린 클래스만 설정 가능 - 특정 계층 빈에 부가기능 부여 @Repository Data Access Layer의 DAO 또는 Reposito.. 2022. 4. 20.
[Spring] AspectJ 적용 시 NoClassDefFoundError, ClassNotFoundException 에러 에러 내용 Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'userRepoImpl' defined in file []: BeanPostProcessor before instantiation of bean failed; nested exception is java.lang.NoClassDefFoundError: org/aspectj/weaver/tools/PointcutDesignatorHandler at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAu.. 2022. 4. 20.
[MAC][Spring] Spring Legacy Project 생성 오류 에러 메시지 an error has occurred. see error log for more details. could not initialize class com.thoughtworks.xstream.converters.collections.propertiesconverter 해결 방법 응용프로그램 > STS > 우클릭 > 패키지 내용 보기 > Contents > Info.plist 위의 경로를 따라 info.plist에 아래 내용 추가 -vm /Library/Java/JavaVirtualMachines/zulu-8.jdk/Contents/Home/bin/java * zulu-8.jdk 부분은 자신의 버전으로 변경해야 한다. 더보기 참고 https://thenicesj.tistory.com/46 [j.. 2022. 4. 18.