From adabec13d3c4cc2d41cdb39787122793e0cc8d22 Mon Sep 17 00:00:00 2001 From: ouyangxq <775153912@qq.com> Date: Thu, 27 Aug 2026 15:21:28 +0800 Subject: [PATCH] fix(print): include Spring DAO exceptions at runtime --- common-web/pom.xml | 4 ++++ .../print/acceptance/PrintStatelessArchitectureTest.java | 3 +++ 2 files changed, 7 insertions(+) diff --git a/common-web/pom.xml b/common-web/pom.xml index 3a5a14627..ee8c7876b 100644 --- a/common-web/pom.xml +++ b/common-web/pom.xml @@ -23,6 +23,10 @@ org.springframework.boot spring-boot-starter-web + + org.springframework + spring-tx + org.springframework.security spring-security-core diff --git a/print/src/test/java/com/baiyue/print/acceptance/PrintStatelessArchitectureTest.java b/print/src/test/java/com/baiyue/print/acceptance/PrintStatelessArchitectureTest.java index eb0069624..9dedbf27f 100644 --- a/print/src/test/java/com/baiyue/print/acceptance/PrintStatelessArchitectureTest.java +++ b/print/src/test/java/com/baiyue/print/acceptance/PrintStatelessArchitectureTest.java @@ -44,6 +44,9 @@ class PrintStatelessArchitectureTest { @Test void runtimeClasspathDoesNotBringBackJdbcOrMybatisTransitively() { ClassLoader loader = getClass().getClassLoader(); + assertThat(isPresent("org.springframework.dao.CannotAcquireLockException", loader)) + .as("common-web exception handling requires Spring DAO exceptions at runtime") + .isTrue(); assertThat(isPresent("org.springframework.jdbc.core.JdbcTemplate", loader)) .as("Print must exclude the JDBC starter inherited through common-core") .isFalse();