Skip to content

feature: server: spring-boot upgrade to 4.0.6#8137

Merged
funky-eyes merged 40 commits into
apache:2.xfrom
xuxiaowei-com-cn:xuxiaowei/spring-boot-4.x-seata-server
Jun 25, 2026
Merged

feature: server: spring-boot upgrade to 4.0.6#8137
funky-eyes merged 40 commits into
apache:2.xfrom
xuxiaowei-com-cn:xuxiaowei/spring-boot-4.x-seata-server

Conversation

@xuxiaowei-com-cn

@xuxiaowei-com-cn xuxiaowei-com-cn commented Jun 9, 2026

Copy link
Copy Markdown
Contributor

https://github.com/redis/jedis/blob/master/docs/migration-guides/v3-to-v4.md

Ⅰ. Describe what this PR did

Ⅱ. Does this pull request fix one issue?

fixes #8053

Ⅲ. Why don't you add test cases (unit test/integration test)?

Ⅳ. Describe how to verify it

Ⅴ. Special notes for reviews

# Conflicts:
#	changes/en-us/2.x.md
#	changes/zh-cn/2.x.md
#	console/pom.xml
#	namingserver/pom.xml
# Conflicts:
#	changes/en-us/2.x.md
#	changes/zh-cn/2.x.md
@xuxiaowei-com-cn xuxiaowei-com-cn changed the title feature: server: spring-boot upgrade to 4.0.6 chore(deps): server: spring-boot upgrade to 4.0.6 Jun 9, 2026
@xuxiaowei-com-cn xuxiaowei-com-cn changed the title chore(deps): server: spring-boot upgrade to 4.0.6 feature: server: spring-boot upgrade to 4.0.6 Jun 9, 2026
@codecov

codecov Bot commented Jun 9, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 72.83%. Comparing base (396ed94) to head (1c9b829).

Additional details and impacted files
@@             Coverage Diff              @@
##                2.x    #8137      +/-   ##
============================================
+ Coverage     72.69%   72.83%   +0.14%     
- Complexity      879     1141     +262     
============================================
  Files          1327     1151     -176     
  Lines         50853    42272    -8581     
  Branches       6071     5045    -1026     
============================================
- Hits          36967    30790    -6177     
+ Misses        10898     9007    -1891     
+ Partials       2988     2475     -513     

see 243 files with indirect coverage changes

Impacted file tree graph

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@funky-eyes funky-eyes requested a review from Copilot June 25, 2026 03:33
@funky-eyes funky-eyes added this to the 2.8.0 milestone Jun 25, 2026
@funky-eyes funky-eyes added type: feature Category issues or prs related to feature request. module/server server module labels Jun 25, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR upgrades the server module’s Spring Boot/Spring Framework baseline (targeting Spring Boot 4.0.6 / Spring Framework 7.0.7) and updates impacted server/test code to match new package names and dependency APIs (notably Jakarta annotations and Jedis API return types).

Changes:

  • Bump Spring Boot/Spring Framework versions for server and adjust Spring package imports accordingly.
  • Migrate javax.annotation.* usage to jakarta.annotation.* across server code and tests.
  • Update Redis/Jedis-related code/tests for newer Jedis API return types and update CI to avoid building server on Java 8.

Reviewed changes

Copilot reviewed 30 out of 30 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
server/src/test/java/org/apache/seata/server/storage/redis/store/RedisTransactionStoreManagerTest.java Adjust Jedis zset query result type to match updated Jedis API.
server/src/test/java/org/apache/seata/server/storage/redis/JedisPooledFactoryTest.java Update pool abstraction usage to Pool<Jedis> for newer Jedis.
server/src/test/java/org/apache/seata/server/session/redis/RedisQueryConsolTest.java Switch @Resource import from javax to jakarta.
server/src/test/java/org/apache/seata/server/session/FileSessionManagerTest.java Switch @Resource import from javax to jakarta.
server/src/test/java/org/apache/seata/server/logging/AppenderTest.java Update logging test configuration approach and SLF4J factory access.
server/src/test/java/org/apache/seata/server/lock/LockManagerTest.java Switch @Resource import from javax to jakarta.
server/src/test/java/org/apache/seata/server/LoaderConfTest.java Minor assertion style adjustment for JUnit usage.
server/src/test/java/org/apache/seata/server/instance/RaftServerInstanceStrategyTest.java Update ServerProperties import path for new Spring Boot packaging.
server/src/test/java/org/apache/seata/server/console/impl/db/GlobalSessionDBServiceImplTest.java Replace @MockBean with newer Mockito test override annotation.
server/src/test/java/org/apache/seata/server/console/impl/db/GlobalLockDBServiceImplTest.java Replace @MockBean with newer Mockito test override annotation.
server/src/test/java/org/apache/seata/server/console/impl/db/BranchSessionDBServiceImplTest.java Replace @MockBean with newer Mockito test override annotation.
server/src/main/resources/logback-spring.xml Add dedicated Kafka logger configuration to reduce noise/control level.
server/src/main/java/org/apache/seata/server/storage/redis/store/RedisTransactionStoreManager.java Adjust Jedis zset query return type to match updated Jedis API.
server/src/main/java/org/apache/seata/server/storage/redis/JedisPooledFactory.java Generalize pool type to Pool<Jedis> (Jedis API alignment).
server/src/main/java/org/apache/seata/server/ServerRunner.java Update Jakarta annotations and Spring Boot web server event import path.
server/src/main/java/org/apache/seata/server/Server.java Switch @Resource import from javax to jakarta.
server/src/main/java/org/apache/seata/server/instance/RaftServerInstanceStrategy.java Switch @Resource import from javax to jakarta.
server/src/main/java/org/apache/seata/server/instance/AbstractSeataInstanceStrategy.java Switch lifecycle/resource annotations to jakarta + update ServerProperties import.
server/src/main/java/org/apache/seata/server/controller/ClusterController.java Switch @Resource import from javax to jakarta.
server/src/main/java/org/apache/seata/server/console/impl/db/GlobalSessionDBServiceImpl.java Switch @Resource import from javax to jakarta.
server/src/main/java/org/apache/seata/server/console/controller/GlobalSessionController.java Switch @Resource import from javax to jakarta.
server/src/main/java/org/apache/seata/server/console/controller/GlobalLockController.java Switch @Resource import from javax to jakarta.
server/src/main/java/org/apache/seata/server/console/controller/BranchSessionController.java Switch @Resource import from javax to jakarta.
server/src/main/java/org/apache/seata/server/config/ServerConfig.java Update ServerProperties import path for new Spring Boot packaging.
server/src/main/java/org/apache/seata/server/cluster/raft/context/SeataClusterContext.java Switch nullability annotations to jakarta.annotation.*.
server/src/main/java/org/apache/seata/server/cluster/manager/ClusterWatcherManager.java Switch @PostConstruct import from javax to jakarta.
server/pom.xml Upgrade Spring Boot/Spring Framework versions and adjust dependencies.
changes/zh-cn/2.x.md Register the server Spring Boot upgrade in the 2.x changelog and add contributor.
changes/en-us/2.x.md Register the server Spring Boot upgrade in the 2.x changelog and add contributor.
.github/workflows/build.yml Skip building/testing server on Java 8 in CI matrix.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines 55 to +57
if (appender.getName().equals("KAFKA")) {
KafkaAppender<ILoggingEvent> kafkaAppender = (KafkaAppender<ILoggingEvent>) appender;
kafkaFound = true;
Comment thread changes/en-us/2.x.md Outdated
Comment thread .github/workflows/build.yml Outdated
- Move server, test-suite/test-new-version modules to JDK17Plus profile
  in root pom.xml, activated automatically on JDK 17+
- Move apm-seata-skywalking-plugin to JDK17Plus profile in
  extensions/apm/pom.xml
- Remove manual module exclusions in CI build.yml for Java 8,
  since Maven profiles now handle this automatically
…s profile

- test-suite/test-new-version depends on server module which requires JDK 17+,
  keeping it in include-test-modules would cause build failure on JDK < 17
- The module is already declared in JDK17Plus profile for JDK 17+ activation

@funky-eyes funky-eyes left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@funky-eyes funky-eyes merged commit c92f96f into apache:2.x Jun 25, 2026
11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

module/server server module type: feature Category issues or prs related to feature request.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

console/namingserver/server: spring-boot upgrade to 4.x

3 participants