1.问题描述
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'pullService': Invocation of init method failed; nested exception is java.lang.NoSuchMethodError: net.sf.cglib.core.Signature.<init>(Ljava/lang/String;Lnet/sf/cglib/asm/Type;[Lnet/sf/cglib/asm/Type;)V
2.解决方法
使用的cglib和asm版本如下:
<dependency>
<groupId>cglib</groupId>
<artifactId>cglib-nodep</artifactId>
<version>2.1_3</version>
</dependency>
<dependency>
<groupId>asm</groupId>
<artifactId>asm</artifactId>
<version>1.5.3</version>
</dependency>
<dependency>
<groupId>asm</groupId>
<artifactId>asm-attrs</artifactId>
<version>1.5.3</version>
</dependency>
同时需要使用如下依赖,干掉其他版本的cglib
<dependency>
<groupId>cglib</groupId>
<artifactId>cglib</artifactId>
<version>99.0-does-not-exist</version>
</dependency>