인터페이스인 DAO로 구현체를 안 만들고 바로 mapper에 접근하는 방법이 궁금합니다.
인터페이스인 DAO를 @Autowired를 하니까
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'loginController': Injection of autowired dependencies failed; nested exception is org.springframework.beans.factory.BeanCreationException: Could not autowire field: private com.jwtLogin.login.dao.SignUpDao com.jwtLogin.login.controller.LoginController.signUpDao; nested exception is org.springframework.beans.factory.NoSuchBeanDefinitionException: No qualifying bean of type [com.jwtLogin.login.dao.SignUpDao] found for dependency: expected at least 1 bean which qualifies as autowire candidate for this dependency. Dependency annotations: {@org.springframework.beans.factory.annotation.Autowired(required=true)}
이런 에러(500)가 뜹니다. 그리고 @Autowired를 주석 처리하면 실행이 됩니다.
Implements를 해야만 Bean이 생성되는 건가요?
아니면 제가 못하고 있는 건가요?ㅜ
답변해 주시면 감사하겠습니다.