一、该问题的重现步骤是什么?
没有改是可以正常运行的
报错:
23-Jul-2020 10:08:35.896 严重 [RMI TCP Connection(2)-127.0.0.1] org.apache.catalina.core.ContainerBase.addChildInternal ContainerBase.addChild: start:
org.apache.catalina.LifecycleException: 无法启动组件[StandardEngine[Catalina].StandardHost[localhost].StandardContext[/riskmg_war]]
Caused by: org.springframework.beans.factory.support.BeanDefinitionOverrideException: Invalid bean definition with name 'redisCache Manager' defined in class path resource [org/springblade/core/redis/config/BladeRedisCacheAutoConfiguration.class]: Cannot register bean definition [Root bean: class [null]; scope=; abstract=false; lazyInit=false; autowireMode=3; dependencyCheck=0; autowireCandidate=true; primary=true; factoryBeanName=org.springblade.core.redis.config.BladeRedisCacheAutoConfiguration; factoryMethodName=redisCacheManager; initMethodName=null; destroyMethodName=(inferred); defined in class path resource [org/springblade/core/redis/config/BladeRedisCacheAutoConfiguration.class]] for bean 'redisCacheManager': There is already [Root bean: class [null]; scope=; abstract=false; lazyInit=false; autowireMode=3; dependencyCheck=0; autowireCandidate=true; primary=false; factoryBeanName=org.springblade.core.jwt.config.JwtRedisConfiguration; factoryMethodName=cacheManager; initMethodName=null; destroyMethodName=(inferred); defined in class path resource [org/springblade/core/jwt/config/JwtRedisConfiguration.class]] bound.
后根据 其中提示百度后添加一个配置
spring.main.allow-bean-definition-overriding: true
结果仍旧无法运行
Caused by: org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'workController' defined in file [D:\KaifaRuanJian\apache-tomcat-8.5.55\webapps\riskmg_war\WEB-INF\classes\org\springblade\flow\business\controller\WorkController.class]: Unsatisfied dependency expressed through constructor parameter 0; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'taskServiceBean' defined in class path resource [org/flowable/spring/boot/ProcessEngineServicesAutoConfiguration.class]: Unsatisfied dependency expressed through method 'taskServiceBean' parameter 0; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'processEngine' defined in class path resource [org/flowable/spring/boot/ProcessEngineServicesAutoConfiguration$AlreadyInitializedAppEngineConfiguration.class]: Unsatisfied dependency expressed through method 'processEngine' parameter 0; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'org.flowable.spring.boot.app.AppEngineServicesAutoConfiguration': Unsatisfied dependency expressed through method 'setEngineConfigurers' parameter 0; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'processAppEngineConfigurationConfigurer' defined in class path resource [org/flowable/spring/boot/ProcessEngineAutoConfiguration$ProcessEngineAppConfiguration.class]: Unsatisfied dependency expressed through method 'processAppEngineConfigurationConfigurer' parameter 0; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'processEngineConfigurator' defined in class path resource [org/flowable/spring/boot/ProcessEngineAutoConfiguration$ProcessEngineAppConfiguration.class]: Unsatisfied dependency expressed through method 'processEngineConfigurator' parameter 0; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'springProcessEngineConfiguration' defined in class path resource [org/flowable/spring/boot/ProcessEngineAutoConfiguration.class]: Unsatisfied dependency expressed through method 'springProcessEngineConfiguration' parameter 0; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'dataSource' defined in class path resource [com/alibaba/druid/spring/boot/autoconfigure/DruidDataSourceAutoConfigure.class]: Invocation of init method failed; nested exception is org.springframework.boot.autoconfigure.jdbc.DataSourceProperties$DataSourceBeanCreationException: Failed to determine suitable jdbc url
二、你期待的结果是什么?实际看到的又是什么?
只希望能正常运行,打包后无法运行
三、你正在使用的是什么产品,什么版本?在什么操作系统上?
spring-boot版本 win10系统 idea jdk8 tomcat8.5
四、请提供详细的错误堆栈信息,这很重要。
五、若有更多详细信息,请在下面提供。
希望作者能能重视下这个问题实践下。刚开始我怀疑是我的配置问题,昨天又下载了一个rowyi前后端分离版,进行如上配置,结果是可以在同环境进行运行war包并启动成功的
扫一扫访问 Blade技术社区 移动端