养成好习惯第一天
新建一个maven项目想整合springboot跟redis,写了五行测试代码运行编译的时候直接报错
org/springframework/nativex/NativeListener has been compiled by a more recent version of the Java Runtime (class file version 55.0), this version of the Java Runtime only recognizes class file versions up to 52.0
大概意思就是运行跟编译的版本不一致无法运行项目
随即百度找了一个多小时,网上大部分的原因是jdk跟jre版本不一致导致,修改项目依赖的jdk jre以及ideal的jdk版本一致即可,这是在网上看到最全面的一篇
https://www.cnblogs.com/hkgov/p/8074085.html
对照全文看了一遍发现我的环境配置没有问题,随即新建一个新项目测试发现全新的项目也无法运行
查看HELP.md发现以下内容
* The following dependencies are not known to work with Spring Native: 'Spring Boot DevTools, Spring Configuration
Processor'. As a result, your application may not work as expected.
* The JVM level was changed from '1.8' to '11', review
the [JDK Version Range](https://github.com/spring-projects/spring-framework/wiki/Spring-Framework-Versions#jdk-version-range)
on the wiki for more details.
以后新建的项目记得看一眼 HELP.md再删,白瞎一个多小时