[spring] jakarta.servlet.ServletException: Handler dispatch failed: java.lang.NoSuchMethodError: 'void org.springframework.web.method.ControllerAdviceBean.<init>(java.lang.Object)' 에러 해결

2025. 1. 2. 13:16·Server/spring

갑자기 스웨거 생성이 안되었다.

 

 

해결방법

1. @RestControllerAdvice(annotations = {RestController.class})을 없앤다.

@RestControllerAdvice(annotations = {RestController.class})

 

 

 

2. 버전을 수정한다.

2.3.0에서 2.7.0으로 바꾸니 잘 동작한다.

implementation 'org.springdoc:springdoc-openapi-starter-webmvc-ui:2.7.0'

'Server > spring' 카테고리의 다른 글

[S3] 이미지 링크 자꾸 다운로드 됨  (1) 2025.05.25
[CICD] SpringBoot + Github Action + EC2 배포  (0) 2025.01.05
[spring/IntelliJ] error: Attempt to recreate a file for type ~  (0) 2025.01.02
[spring] Cannot resolve method 'assertThat' in 'Assertions'  (0) 2024.11.29
[spring] DB 연동  (0) 2024.11.03
'Server/spring' 카테고리의 다른 글
  • [S3] 이미지 링크 자꾸 다운로드 됨
  • [CICD] SpringBoot + Github Action + EC2 배포
  • [spring/IntelliJ] error: Attempt to recreate a file for type ~
  • [spring] Cannot resolve method 'assertThat' in 'Assertions'
2월2
2월2
  • 2월2
    서벅돌의 성장일기
    2월2
  • 전체
    오늘
    어제
    • 분류 전체보기 (120)
      • TIL (2)
      • Server (28)
        • spring (7)
        • node.js (16)
        • 기타 (5)
      • App&Web (17)
        • Web (1)
        • Android (16)
        • iOS (0)
      • 공부 (59)
        • 깃&깃허브 (3)
        • 파이썬 (17)
        • 유니티 (4)
        • 자료구조 | 알고리즘 (15)
        • 자바 (3)
        • 운영체제 (8)
        • AI와 데이터 (9)
      • 대외활동 (12)
        • NPC 동아리 (1)
        • UMC 동아리 (11)
      • 대학교 (1)
        • 교직 (1)
      • 기타 (0)
  • 블로그 메뉴

    • 홈
    • 태그
    • 방명록
    • 글 관리
  • 링크

  • 공지사항

    • Notice
  • 인기 글

  • 태그

    루아
    안드로이드
    Unity
    코틀린
    파이썬
    kotlin
    Lua
    유니티
    C
    mysql
    Python
    자바
    Android
    java
  • 최근 댓글

  • 최근 글

  • hELLO· Designed By정상우.v4.10.3
2월2
[spring] jakarta.servlet.ServletException: Handler dispatch failed: java.lang.NoSuchMethodError: 'void org.springframework.web.method.ControllerAdviceBean.<init>(java.lang.Object)' 에러 해결
상단으로

티스토리툴바