External Compatibility Validation for google-java-format on Future JDK Versions
还没有人认领这个 Issue。
评估
调研方向
尚未确定具体的文件、测试或入口点。首先检查现有的 CI、构建脚本和测试环境,然后明确未来哪些 JDK 版本和验证场景属于范围;完成标准是达成一致的实验性配置或分支,并获得可复现的兼容性结果。
由索引模型根据 Issue 内容生成。
描述
Hi everyone,
I would like to share an idea we are currently considering: doing some external validation and tracking work around google-java-format’s compatibility with future JDK versions.
This is not a request for the official project to maintain multiple codebases, create separate official releases for different Java versions, or replace the existing test suite. Our goal is also not to maintain a performance-focused fork.
From the current project setup, google-java-format relies on jdk.compiler / javac-related APIs to parse and format Java source code. This makes it sensitive to the runtime JDK version, new Java language syntax, and changes in JDK internal APIs. The project has already raised its minimum runtime JDK requirement to JDK 21 and continues to track compatibility with newer JDK versions and Java language features.
Because of that, our goal is not to ask the project to maintain multiple Java baselines or change the current minimum runtime JDK requirement. Instead, we would like to do early compatibility validation around future JDK versions, so that potential issues in newer JDK environments can be identified earlier.
This kind of validation may include, but is not limited to:
- Compatibility issues when running the formatter on JDK 22, JDK 23, JDK 24, JDK 25, or later versions
- Formatting differences caused by new Java syntax or preview features
- Formatting issues related to Javadoc / Markdown documentation comments or other documentation syntax changes
- Issues caused by changes in
jdk.compiler/ javac internal APIs - Java module system access restrictions or
--add-exportsrelated issues - Compatibility differences in CLI, IDE plugin, Maven, or Gradle integration scenarios
- CI, build script, or test environment compatibility issues
- Issues users may encounter when using google-java-format on newer JDK environments
Our current idea is to maintain a small number of external experimental compatibility branches or test environments for future JDK versions. The official project can continue normal development on the current main branch, current minimum runtime JDK requirement, and existing release cadence. We would take responsibility for syncing with upstream, running relevant tests, recording issues, and maintaining these experimental validation efforts.
These branches or test environments are not intended to become official separate codebases unless the project and community later find clear value in them. At this stage, their main purpose would be compatibility validation, collecting feedback, and preparing useful reference information for future adaptation to new JDKs or Java language features.
If there is real demand, we may maintain two or three external compatibility validation branches or test configurations for future JDK versions over the long term and report useful findings upstream when helpful. For issues that can be addressed independently, we would document them as reproducible issues or submit small, focused PRs instead of asking the project to review or maintain a large fork.
The goal of this effort is to identify potential compatibility risks google-java-format may face with future JDK versions, new Java language syntax, and javac-related API changes as early as possible, and to provide useful information for future adaptation work without adding extra maintenance burden to the official project.
Thank you for your time, and thank you for maintaining google-java-format.
- 主要语言
- Java
- 星标
- 6.2k
- 派生
- 936
- 平均合并
- 6 分钟
- 30 天内合并 PR
- 3
贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
google/google-java-format 的其他 Issue
-
难度 2/5 1-3 小时 新手友好度 72/100
google/google-java-format#1094 · 1 条评论 ·
-
难度 5/5 一周以上 新手友好度 15/100
google/google-java-format#1450 · 1 个 reaction ·
-
难度 4/5 3-5 天 新手友好度 55/100
google/google-java-format#1439 · 1 条评论 ·
-
难度 3/5 1-2 天 新手友好度 62/100
google/google-java-format#1436 · 2 条评论 ·
-
难度 3/5 1-2 天 新手友好度 48/100
google/google-java-format#1428 · 3 条评论 ·
查看 google/google-java-format 的全部 Issue
相似的 Issue
-
难度 2/5 1-3 小时 新手友好度 65/100
-
bug
难度 2/5 1-3 小时 新手友好度 75/100
-
难度 2/5 1-3 小时 新手友好度 75/100
elastic/gradle-plugins#157 ·
-
难度 2/5 1-3 小时 新手友好度 75/100
cryptomator/hub#497 ·
-
难度 2/5 1-3 小时 新手友好度 75/100
johanhaleby/occurrent#1120 ·