org.apache.cxf.interceptor.Fault: Could not initialize class org.springframework.jdbc.core.Statement

环境是spring JDBC + spring jpa + spring security

现在以上这种情况,肯定是jar冲突有缘故

目前security最高版本为3.2.4,引用的spring 也是3.2.4,而引用的spring-data-jpa是1.3.0的,在引用版本的问题上,spring引用了3.2.8,导致在运行的时候报如下错误:

org.apache.cxf.interceptor.Fault: Could not initialize class org.springframework.jdbc.core.StatementCreatorUtils

StatementCreatorUtils初始化时下面代码时:

static final boolean shouldIgnoreGetParameterType = SpringProperties.getFlag(IGNORE_GETPARAMETERTYPE_PROPERTY_NAME);

其中引用了:

import org.springframework.core.SpringProperties;

不存在

spring core中SpringProperties不存在,3.2.7以上才有


所以把spring-core相关的JAR改为3.2.8就OK了

猜你喜欢

转载自blog.csdn.net/xiazou/article/details/34111837
今日推荐