SpringBoot2.x 集成Activiti6.xs :java.lang.ArrayStoreException: sun.reflect.annotation.***

今天使用SpringBoot2.x 版本集成Activiti 6.x 启动Application.java 程序,提示如下错误信息:

org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'requestMappingHandlerMapping' defined in class path resource [org/springframework/boot/autoconfigure/web/servlet/WebMvcAutoConfiguration$EnableWebMvcConfiguration.class]: Invocation of init method failed; nested exception is java.lang.ArrayStoreException: sun.reflect.annotation.TypeNotPresentExceptionProxy
	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1762)
	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:593)
	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:515)

经过相关的百度,造成错误的原因:springboot2.0不能与activiti6.0.0直接集成使用,因为activiti6.0.0出来的时候springboot2.0还没有出来,activiti6.0.0 支持springboot1.2.6以上,2.0.0以下的版本

 

给出了两种解决方法:

1:将springboot2.0换成1.X版本(我的选择,将springboot版本由2.x 下降为1.5.x)

2:在springboot启动类上添加:

@SpringBootApplication(exclude = SecurityAutoConfiguration.class)

 

你可能感兴趣的:(activiti,流程引擎)