작성
·
340
0
A problem occurred configuring root project 'hello-spring'.
> Could not resolve all artifacts for configuration 'classpath'.
> Could not resolve org.springframework.boot:spring-boot-gradle-plugin:3.4.1.
Required by:
root project : > org.springframework.boot:org.springframework.boot.gradle.plugin:3.4.1
> Dependency requires at least JVM runtime version 17. This build uses a Java 8 JVM.
* Try:
> Run this build using a Java 17 or newer JVM.
> Run with --stacktrace option to get the stack trace.
> Run with --info or --debug option to get more log output.
> Run with --scan to get full insights.
> Get more help at https://help.gradle.org.
Deprecated Gradle features were used in this build, making it incompatible with Gradle 9.0.
You can use '--warning-mode all' to show the individual deprecation warnings and determine if they come from your own scripts or plugins.
For more on this, please refer to https://docs.gradle.org/8.11.1/userguide/command_line_interface.html#sec:command_line_warnings in the Gradle documentation.
인텔리제이에서 open 폴더로 hellospring 열었는데 해당 오류가 뜨네요 이거 뭔가요?
답변 1
0
안녕하세요, 인프런 AI 인턴입니다.
이승태님이 겪고 계신 문제는 스프링 부트 프로젝트가 Java 8 JVM을 사용하는데, 해당 프로젝트는 Java 17 또는 그 이상의 버전을 필요로 해서 발생하는 오류입니다. 스프링 부트 3.4.1 버전은 Java 17 이상에서 구동해야 하기 때문입니다.
이 문제를 해결하기 위해서는 몇 가지 단계를 거치게 됩니다:
Java 버전 확인 및 변경: 현재 사용 중인 Java Runtime 버전을 17 이상으로 변경해야 합니다. 이렇게 하려면 JDK 17 이상을 설치하고, 환경 변수(JAVA_HOME)를 해당 JDK 설치 경로로 설정해 주세요.
IntelliJ IDE 설정 변경:
File -> Project Structure -> Project
탭에서 Project SDK
를 설정합니다.Gradle Wrapper 설정 확인:
gradlew build
실행 시 필요한 JVM 버전이 제대로 등록되어 있는지 확인합니다. gradle.properties
파일이나 build.gradle
파일에서 JVM 버전을 확인하세요.이와 유사한 문제를 겪은 수강생들의 관련 질문을 참고하시면 추가적인 도움이 될 수 있습니다. 이 링크에서는 유사한 오류를 해결하는 방법에 대해 논의하고 있습니다. Java 버전과 Gradle 설정을 통해 해결하는 팁도 안내되어 있습니다.
저는 질문자님의 이해를 돕고자 지식공유자님의 기존 답변을 참고하여 유사한 답변 링크를 추천해드리고 있습니다.
현재 베타 기능으로 답변이 만족스럽지 않을 수 있는 점 양해 부탁드립니다. 🙏
추가적으로 궁금한 점이 있으시면, 이어서 질문해 주세요. 곧 지식공유자께서 답변해 주실 것입니다.