java-spring 错误 Unsupported class file major version 57


环境

ubuntu 18.04 jdk13

错误代码

Caused by: org.springframework.core.NestedIOException: ASM ClassReader failed to parse class file - probably due to a new Java class file version that isn't supported yet: file ;

nested exception is java.lang.IllegalArgumentException: Unsupported class file major version 57

解决方法

jdk13暂时不被支持,降级至jdk11,可正常运行

降级方法(IDEA)

  • File->Settings->Build,Execution,Deployment->Compiler->Java Compiler->project bytecode version 选择11

  • File->Project Structure->Project->

    • Porject Sdk 选择11

    • Porject language level 选择11

  • File->Project Structure->Modules->language level 选择11


免责声明!

本站转载的文章为个人学习借鉴使用,本站对版权不负任何法律责任。如果侵犯了您的隐私权益,请联系本站邮箱yoyou2525@163.com删除。



 
粤ICP备18138465号  © 2018-2025 CODEPRJ.COM