티스토리 뷰

Exception encountered during context initialization - cancelling refresh attempt: org.springframework.beans.factory.BeanCreationException:
Error creating bean with name 'org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerMapping':
Invocation of init method failed; nested exception is java.lang.IllegalStateException: Ambiguous mapping. Cannot map 'xxxController' method 
There is already 'xxxController' bean method.
Shutting down ExecutorService 'annotationbatchSecheduler'

자바 스프링 프로그래밍을 하다 보면 위와 같은 에러를 만날것이다.

평소에는 잘 못 보는데 소스를 복사 붙여넣기 할 때 위와 같은 에러를 자주 만날것이다.

나름 수정한다고 했는데..

소스를 복사 붙여넣기 해서 열심히 찾기 바꾸기를 한다고 할지라도 뭔가 빈틈이 생겨서 위와 같은 에러가 발생한다.

결론적으로

@RequestMapping(value="")

이 value 부분에 같은것이 있어서 그런것 이다.

컴파일 에러처럼 빨간색 밑줄이 그어지면 바로 알텐데.. 그냥 텍스트라서 컴파일시에는 알 수가 없다.

마치 xml 에러처럼..

서버를 올릴때 중복이 되는게 있어서 에러를 뱉는다.

아.. 어렵당..

자 이제 에러가 난 곳으로 가보면 아.. 이런게 있었네.. 하고 바꾸기를 다시 할 것이다.

댓글
공지사항
최근에 올라온 글
최근에 달린 댓글
Total
Today
Yesterday
링크
«   2025/08   »
1 2
3 4 5 6 7 8 9
10 11 12 13 14 15 16
17 18 19 20 21 22 23
24 25 26 27 28 29 30
31
글 보관함