idea Error:java: 无效的目标发行版: 17

Error:java: 无效的目标发行版: 17

compiler.xml

xml 复制代码
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
  <component name="CompilerConfiguration">
    <annotationProcessing>
      <profile name="Maven default annotation processors profile" enabled="true">
        <sourceOutputDir name="target/generated-sources/annotations" />
        <sourceTestOutputDir name="target/generated-test-sources/test-annotations" />
        <outputRelativeToContentRoot value="true" />
        <module name="sharding-jdbc-examples" />
      </profile>
    </annotationProcessing>
    <bytecodeTargetLevel>
      <module name="sharding-jdbc-examples" target="17" />
    </bytecodeTargetLevel>
  </component>
  <component name="JavacSettings">
    <option name="ADDITIONAL_OPTIONS_OVERRIDE">
      <module name="sharding-jdbc-examples" options="-parameters" />
    </option>
  </component>
</project>
复制代码
<bytecodeTargetLevel>
  <module name="sharding-jdbc-examples" target="17" />
</bytecodeTargetLevel>

改成

xml 复制代码
    <bytecodeTargetLevel>
      <module name="sharding-jdbc-examples" target="8" />
    </bytecodeTargetLevel>
相关推荐
折哥的程序人生 · 物流技术专研4 小时前
Java面试85题图解版 · 特别篇:2026后端高频面试题复盘(算法底层逻辑+高并发架构设计全解析,附Java实战代码)
java·网络·数据库·算法·面试
一条泥憨鱼4 小时前
【Redis】数据类型和常用命令
java·数据库·redis·后端·缓存
云烟成雨TD4 小时前
Spring AI Alibaba 1.x 系列【78】沙箱(Sandbox)
java·人工智能·spring
程序员二叉4 小时前
【Java】 异常高频面试题精讲 | 易错点+对比总结
java·开发语言·面试
周航宇JoeZhou5 小时前
JB3-9-SpringAI(二)
java·ai·agent·多智能体·调度·智能体·观察
好家伙VCC5 小时前
Web Components主题热切换方案揭秘
java·前端
慕木沐5 小时前
Google ADK Java 1.0版本 核心机制与实战 Demo
java·开发语言·python
焦虑的说说6 小时前
秒杀系统设计方案
java
许彰午6 小时前
30_Java Stream流操作全解
java·windows·python
qq_2518364576 小时前
基于java Web网络订餐系统设计与实现 源码文档
java·开发语言·前端