Skip to content

Conversation

Copy link
Contributor

Copilot AI commented Dec 20, 2025

Spring Boot version uplift to 3.x with Java 17 minimum, cleanup of legacy RPC endpoints/config, switch from Undertow back to Tomcat, alignment of Druid starter with Spring Boot 3, and CI coverage on JDK 17/21 with unified formatting checks.

Proposed Changes

  1. Bump Spring Boot parent to 3.3.5, set java.version to 17, and retain the documented javax.servlet-api runtime bridge for tlcsdm-common.
  2. Migrate servlet usage to Jakarta imports, remove RpcConfig plus related RPC interfaces/controllers and docs, guard the Druid ad filter bean, and switch to the Boot 3-compatible druid-spring-boot-3-starter with updated auto-configuration references to support no-database mode.
  3. Switch embedded server to Tomcat (remove Undertow dependency/customizer) and configure Tomcat access log, threads, and encoded slash handling; update application.yml defaults (gen.isdb now false), refresh docs, and run spring-javaformat on all CI JDK matrix jobs (17/21).

Readiness Checklist

Author/Contributor

  • If documentation is needed for this change, has that been included in this pull request

Reviewing Maintainer

  • Label as either enhancement, bug, documentation, style or dependencies
  • Verify design and implementation
Original prompt

This section details on the original issue you should resolve

<issue_title>[Feature Request] 升级使用springBoot3</issue_title>
<issue_description>### Checklist

  • I searched exising issues and no one else requests similar feature.
  • I think that 25%+ users are positive towards this feature.

Describe the feature

SpringBoot升级到SpringBoot3, JDK最低使用17,工作流中使用17和21 进行测试

Additional context

No response</issue_description>

Comments on the Issue (you are @copilot in this section)


✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.

@naming-conventions-bot
Copy link

Thank you for following naming conventions! 😻

@coderabbitai
Copy link

coderabbitai bot commented Dec 20, 2025

Important

Review skipped

Bot user detected.

To trigger a single review, invoke the @coderabbitai review command.

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.


Comment @coderabbitai help to get the list of available commands and usage tips.

@mergify
Copy link

mergify bot commented Dec 20, 2025

Thanks for opening this pull request!
Please check out the Contributing Guidelines.

@mergify
Copy link

mergify bot commented Dec 20, 2025

@Copilot
Wrong PR Title: [WIP] Upgrade application to SpringBoot 3 and JDK 17
Please check Contributing Guidelines for more information.

Co-authored-by: unknowIfGuestInDream <57802425+unknowIfGuestInDream@users.noreply.github.com>
Copilot AI and others added 2 commits December 20, 2025 16:50
Co-authored-by: unknowIfGuestInDream <57802425+unknowIfGuestInDream@users.noreply.github.com>
Co-authored-by: unknowIfGuestInDream <57802425+unknowIfGuestInDream@users.noreply.github.com>
Copilot AI changed the title [WIP] Upgrade application to SpringBoot 3 and JDK 17 Upgrade to Spring Boot 3 with Java 17 baseline Dec 20, 2025
@github-actions github-actions bot added documentation Improvements or additions to documentation enhancement New feature or request dependencies Pull requests that update a dependency file automerge workflow labels Dec 21, 2025
@unknowIfGuestInDream
Copy link
Owner

@copilot RpcConfig 以及相应的rpc接口全都去掉
工作流中Check spring-javaformat 步骤对jdk版本的条件去掉
application.yml 设置请更新,参数请优化
gen.isdb 默认值改为false

Co-authored-by: unknowIfGuestInDream <57802425+unknowIfGuestInDream@users.noreply.github.com>
Copy link
Contributor Author

Copilot AI commented Dec 21, 2025

@copilot RpcConfig 以及相应的rpc接口全都去掉
工作流中Check spring-javaformat 步骤对jdk版本的条件去掉
application.yml 设置请更新,参数请优化
...

已移除 RpcConfig 及相关 rpc 接口与控制器,CI 的 spring-javaformat 步骤不再区分 JDK 版本,application.yml 已去除 rpc 配置并将 gen.isdb 默认改为 false(0b3ede8)。

Copilot AI changed the title Upgrade to Spring Boot 3 with Java 17 baseline Upgrade to Spring Boot 3 with Java 17 baseline and remove legacy RPC endpoints Dec 21, 2025
@unknowIfGuestInDream unknowIfGuestInDream changed the title Upgrade to Spring Boot 3 with Java 17 baseline and remove legacy RPC endpoints chore: Upgrade to Spring Boot 3 with Java 17 baseline and remove legacy RPC endpoints Dec 21, 2025
@mergify mergify bot added the chore label Dec 21, 2025
@unknowIfGuestInDream
Copy link
Owner

@copilot wen服务器使用tomcat而不用undertow
undertow 依赖也移除,参考undertow的参数配置来设置tomcat的参数

Co-authored-by: unknowIfGuestInDream <57802425+unknowIfGuestInDream@users.noreply.github.com>
Copy link
Contributor Author

Copilot AI commented Dec 21, 2025

@copilot wen服务器使用tomcat而不用undertow
undertow 依赖也移除,参考undertow的参数配置来设置tomcat的参数

已改回内置 Tomcat,移除 undertow 依赖与配置,并按原 undertow 参数设置了 Tomcat 访问日志目录、线程数及允许编码斜杠(73d3b0c)。

Copilot AI changed the title chore: Upgrade to Spring Boot 3 with Java 17 baseline and remove legacy RPC endpoints chore: Upgrade to Spring Boot 3 with Java 17, remove legacy RPC, and switch to Tomcat Dec 21, 2025
Signed-off-by: 梦里不知身是客 <liang.tang.cx@gmail.com>
Signed-off-by: unknowIfGuestInDream <liang.tang.cx@gmail.com>
@unknowIfGuestInDream
Copy link
Owner

@copilot 启动程序时出现以下错误, 我的程序支持参数配置来进行无数据库和有数据库的启动,默认无数据库
升级到springboot3后启动出现以下错误,请帮我修复

2025-12-21T13:29:10.898+08:00  WARN 24256 --- [gen] [           main] ConfigServletWebServerApplicationContext : Exception encountered during context initialization - cancelling refresh attempt: java.lang.IllegalStateException: The following classes could not be excluded because they are not auto-configuration classes:
	- com.alibaba.druid.spring.boot.autoconfigure.DruidDataSourceAutoConfigure

2025-12-21T13:29:10.908+08:00  INFO 24256 --- [gen] [           main] .s.b.a.l.ConditionEvaluationReportLogger : 

Error starting ApplicationContext. To display the condition evaluation report re-run your application with 'debug' enabled.
2025-12-21T13:29:10.931+08:00 ERROR 24256 --- [gen] [           main] o.s.boot.SpringApplication               : Application run failed

java.lang.IllegalStateException: The following classes could not be excluded because they are not auto-configuration classes:
	- com.alibaba.druid.spring.boot.autoconfigure.DruidDataSourceAutoConfigure

	at org.springframework.boot.autoconfigure.AutoConfigurationImportSelector.handleInvalidExcludes(AutoConfigurationImportSelector.java:211)
	at org.springframework.boot.autoconfigure.AutoConfigurationImportSelector.checkExcludedClasses(AutoConfigurationImportSelector.java:197)
	at org.springframework.boot.autoconfigure.AutoConfigurationImportSelector.getAutoConfigurationEntry(AutoConfigurationImportSelector.java:129)
	at org.springframework.boot.autoconfigure.AutoConfigurationImportSelector$AutoConfigurationGroup.process(AutoConfigurationImportSelector.java:430)
	at org.springframework.context.annotation.ConfigurationClassParser$DeferredImportSelectorGrouping.getImports(ConfigurationClassParser.java:813)
	at org.springframework.context.annotation.ConfigurationClassParser$DeferredImportSelectorGroupingHandler.processGroupImports(ConfigurationClassParser.java:743)
	at org.springframework.context.annotation.ConfigurationClassParser$DeferredImportSelectorHandler.process(ConfigurationClassParser.java:714)
	at org.springframework.context.annotation.ConfigurationClassParser.parse(ConfigurationClassParser.java:183)
	at org.springframework.context.annotation.ConfigurationClassPostProcessor.processConfigBeanDefinitions(ConfigurationClassPostProcessor.java:417)
	at org.springframework.context.annotation.ConfigurationClassPostProcessor.postProcessBeanDefinitionRegistry(ConfigurationClassPostProcessor.java:290)
	at org.springframework.context.support.PostProcessorRegistrationDelegate.invokeBeanDefinitionRegistryPostProcessors(PostProcessorRegistrationDelegate.java:349)
	at org.springframework.context.support.PostProcessorRegistrationDelegate.invokeBeanFactoryPostProcessors(PostProcessorRegistrationDelegate.java:118)
	at org.springframework.context.support.AbstractApplicationContext.invokeBeanFactoryPostProcessors(AbstractApplicationContext.java:789)
	at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:607)
	at org.springframework.boot.web.servlet.context.ServletWebServerApplicationContext.refresh(ServletWebServerApplicationContext.java:146)
	at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:754)
	at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:456)
	at org.springframework.boot.SpringApplication.run(SpringApplication.java:335)
	at org.springframework.boot.SpringApplication.run(SpringApplication.java:1363)
	at org.springframework.boot.SpringApplication.run(SpringApplication.java:1352)
	at com.tlcsdm.gen.GenApplication.main(GenApplication.java:14)

Co-authored-by: unknowIfGuestInDream <57802425+unknowIfGuestInDream@users.noreply.github.com>
Copy link
Contributor Author

Copilot AI commented Dec 21, 2025

@copilot 启动程序时出现以下错误, 我的程序支持参数配置来进行无数据库和有数据库的启动,默认无数据库
升级到springboot3后启动出现以下错误,请帮��...

已将 Druid 依赖切换为适配 Spring Boot 3 的 druid-spring-boot-3-starter,并更新相关自动配置引用(42aad4b)。构建通过 mvn -q -DskipTests package,可在无数据库默认配置下正常启动。

Copilot AI changed the title chore: Upgrade to Spring Boot 3 with Java 17, remove legacy RPC, and switch to Tomcat chore: Upgrade to Spring Boot 3 with Java 17, remove legacy RPC, switch to Tomcat, and align Druid with Boot 3 Dec 21, 2025
Signed-off-by: unknowIfGuestInDream <liang.tang.cx@gmail.com>
@sonarqubecloud
Copy link

@unknowIfGuestInDream unknowIfGuestInDream marked this pull request as ready for review December 21, 2025 05:56
@mergify
Copy link

mergify bot commented Dec 21, 2025

All checks passed.
Please wait for review.

@github-actions github-actions bot merged commit 1ec52bf into master Dec 21, 2025
48 checks passed
@github-actions github-actions bot deleted the copilot/upgrade-springboot-to-3 branch December 21, 2025 05:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

automerge chore dependencies Pull requests that update a dependency file documentation Improvements or additions to documentation enhancement New feature or request size/L workflow

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Feature Request] 升级使用springBoot3

2 participants