blade-flow-design运行一段时间后出现锁库现象

Blade 已结 1 1076
346527359
346527359 2020-12-01 16:37

一、该问题的重现步骤是什么?


1. blade-flow-design启动运行一段时间后出现数据库锁库


2. 出现问题时间间隔不确定


3.




二、你期待的结果是什么?实际看到的又是什么?


页面操作不报错


依次操作:流程管理--模型管理--配置 ,页面可以正常跳转




三、你正在使用的是什么产品,什么版本?在什么操作系统上?


bladex blade-flow-design   centos7.5




四、请提供详细的错误堆栈信息,这很重要。


2020-12-01 08:07:13.614  INFO 1 --- [           main] l.lockservice.StandardLockService        : Waiting for changelog lock....


2020-12-01 08:07:23.615  INFO 1 --- [           main] liquibase.executor.jvm.JdbcExecutor      : SELECT `LOCKED` FROM db_ceshi_flow.ACT_DE_DATABASECHANGELOGLOCK WHERE ID=1


2020-12-01 08:07:23.618  INFO 1 --- [           main] l.lockservice.StandardLockService        : Waiting for changelog lock....


2020-12-01 08:07:33.620  INFO 1 --- [           main] liquibase.executor.jvm.JdbcExecutor      : SELECT ID,`LOCKED`,LOCKGRANTED,LOCKEDBY FROM db_ceshi_flow.ACT_DE_DATABASECHANGELOGLOCK WHERE ID=1


2020-12-01 08:07:33.631  WARN 1 --- [           main] ConfigServletWebServerApplicationContext : Exception encountered during context initialization - cancelling refresh attempt: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'modelerLiquibase' defined in class path resource [org/springblade/flow/config/FlowableBeanConfiguration.class]: Bean instantiation via factory method failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [liquibase.Liquibase]: Factory method 'modelerLiquibase' threw exception; nested exception is org.flowable.ui.common.service.exception.InternalServerErrorException: Error creating liquibase database


2020-12-01 08:07:33.633  INFO 1 --- [           main] com.alibaba.druid.pool.DruidDataSource   : {dataSource-1} closing ...


2020-12-01 08:07:33.666  INFO 1 --- [           main] com.alibaba.druid.pool.DruidDataSource   : {dataSource-1} closed


2020-12-01 08:07:33.689  INFO 1 --- [           main] ConditionEvaluationReportLoggingListener : 




Error starting ApplicationContext. To display the conditions report re-run your application with 'debug' enabled.


2020-12-01 08:07:33.702 ERROR 1 --- [           main] o.s.boot.SpringApplication               : Application run failed




org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'modelerLiquibase' defined in class path resource [org/springblade/flow/config/FlowableBeanConfiguration.class]: Bean instantiation via factory method failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [liquibase.Liquibase]: Factory method 'modelerLiquibase' threw exception; nested exception is org.flowable.ui.common.service.exception.InternalServerErrorException: Error creating liquibase database


at org.springframework.beans.factory.support.ConstructorResolver.instantiate(ConstructorResolver.java:627) ~[spring-beans-5.1.15.RELEASE.jar!/:5.1.15.RELEASE]


at org.springframework.beans.factory.support.ConstructorResolver.instantiateUsingFactoryMethod(ConstructorResolver.java:607) ~[spring-beans-5.1.15.RELEASE.jar!/:5.1.15.RELEASE]


at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.instantiateUsingFactoryMethod(AbstractAutowireCapableBeanFactory.java:1320) ~[spring-beans-5.1.15.RELEASE.jar!/:5.1.15.RELEASE]


at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:1159) ~[spring-beans-5.1.15.RELEASE.jar!/:5.1.15.RELEASE]


at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:555) ~[spring-beans-5.1.15.RELEASE.jar!/:5.1.15.RELEASE]


at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:515) ~[spring-beans-5.1.15.RELEASE.jar!/:5.1.15.RELEASE]


at org.springframework.beans.factory.support.AbstractBeanFactory.lambda$doGetBean$0(AbstractBeanFactory.java:320) ~[spring-beans-5.1.15.RELEASE.jar!/:5.1.15.RELEASE]


at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:226) ~[spring-beans-5.1.15.RELEASE.jar!/:5.1.15.RELEASE]


at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:318) ~[spring-beans-5.1.15.RELEASE.jar!/:5.1.15.RELEASE]


at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:199) ~[spring-beans-5.1.15.RELEASE.jar!/:5.1.15.RELEASE]


at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:860) ~[spring-beans-5.1.15.RELEASE.jar!/:5.1.15.RELEASE]


at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:877) ~[spring-context-5.1.15.RELEASE.jar!/:5.1.15.RELEASE]


at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:549) ~[spring-context-5.1.15.RELEASE.jar!/:5.1.15.RELEASE]


at org.springframework.boot.web.servlet.context.ServletWebServerApplicationContext.refresh(ServletWebServerApplicationContext.java:141) ~[spring-boot-2.1.14.RELEASE.jar!/:2.1.14.RELEASE]


at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:744) ~[spring-boot-2.1.14.RELEASE.jar!/:2.1.14.RELEASE]


at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:391) ~[spring-boot-2.1.14.RELEASE.jar!/:2.1.14.RELEASE]


at org.springframework.boot.SpringApplication.run(SpringApplication.java:312) ~[spring-boot-2.1.14.RELEASE.jar!/:2.1.14.RELEASE]


at org.springframework.boot.builder.SpringApplicationBuilder.run(SpringApplicationBuilder.java:140) [spring-boot-2.1.14.RELEASE.jar!/:2.1.14.RELEASE]


at org.springblade.core.launch.BladeApplication.run(BladeApplication.java:50) [blade-core-launch-2.5.1.RELEASE.jar!/:na]


at org.springblade.flow.FlowDesignApplication.main(FlowDesignApplication.java:50) [classes!/:na]


at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.8.0_111]


at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[na:1.8.0_111]


at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_111]


at java.lang.reflect.Method.invoke(Method.java:498) ~[na:1.8.0_111]


at org.springframework.boot.loader.MainMethodRunner.run(MainMethodRunner.java:48) [blade-flow-design.jar:na]


at org.springframework.boot.loader.Launcher.launch(Launcher.java:87) [blade-flow-design.jar:na]


at org.springframework.boot.loader.Launcher.launch(Launcher.java:51) [blade-flow-design.jar:na]


at org.springframework.boot.loader.JarLauncher.main(JarLauncher.java:52) [blade-flow-design.jar:na]


Caused by: org.springframework.beans.BeanInstantiationException: Failed to instantiate [liquibase.Liquibase]: Factory method 'modelerLiquibase' threw exception; nested exception is org.flowable.ui.common.service.exception.InternalServerErrorException: Error creating liquibase database


at org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:185) ~[spring-beans-5.1.15.RELEASE.jar!/:5.1.15.RELEASE]


at org.springframework.beans.factory.support.ConstructorResolver.instantiate(ConstructorResolver.java:622) ~[spring-beans-5.1.15.RELEASE.jar!/:5.1.15.RELEASE]


... 27 common frames omitted


Caused by: org.flowable.ui.common.service.exception.InternalServerErrorException: Error creating liquibase database


at org.springblade.flow.config.FlowableBeanConfiguration.modelerLiquibase(FlowableBeanConfiguration.java:62) ~[classes!/:na]


at org.springblade.flow.config.FlowableBeanConfiguration$$EnhancerBySpringCGLIB$$a621d4e6.CGLIB$modelerLiquibase$1() ~[classes!/:na]


at org.springblade.flow.config.FlowableBeanConfiguration$$EnhancerBySpringCGLIB$$a621d4e6$$FastClassBySpringCGLIB$$b3b5d929.invoke() ~[classes!/:na]


at org.springframework.cglib.proxy.MethodProxy.invokeSuper(MethodProxy.java:244) ~[spring-core-5.1.15.RELEASE.jar!/:5.1.15.RELEASE]


at org.springframework.context.annotation.ConfigurationClassEnhancer$BeanMethodInterceptor.intercept(ConfigurationClassEnhancer.java:363) ~[spring-context-5.1.15.RELEASE.jar!/:5.1.15.RELEASE]


at org.springblade.flow.config.FlowableBeanConfiguration$$EnhancerBySpringCGLIB$$a621d4e6.modelerLiquibase() ~[classes!/:na]


at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.8.0_111]


at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[na:1.8.0_111]


at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_111]


at java.lang.reflect.Method.invoke(Method.java:498) ~[na:1.8.0_111]


at org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:154) ~[spring-beans-5.1.15.RELEASE.jar!/:5.1.15.RELEASE]


... 28 common frames omitted


Caused by: liquibase.exception.LockException: Could not acquire change log lock.  Currently locked by 788bb1a029a6 (172.17.0.13) since 9/10/20 11:55 PM


at liquibase.lockservice.StandardLockService.waitForLock(StandardLockService.java:230) ~[liquibase-core-3.6.3.jar!/:na]


at liquibase.Liquibase.update(Liquibase.java:184) ~[liquibase-core-3.6.3.jar!/:na]


at liquibase.Liquibase.update(Liquibase.java:179) ~[liquibase-core-3.6.3.jar!/:na]


at liquibase.Liquibase.update(Liquibase.java:175) ~[liquibase-core-3.6.3.jar!/:na]


at liquibase.Liquibase.update(Liquibase.java:168) ~[liquibase-core-3.6.3.jar!/:na]


at org.springblade.flow.config.FlowableBeanConfiguration.modelerLiquibase(FlowableBeanConfiguration.java:59) ~[classes!/:na]


... 38 common frames omitted




五、若有更多详细信息,请在下面提供。


已手动解决,但是需要定位根源问题


附手动解决方案


UPDATE db_test.ACT_DE_DATABASECHANGELOGLOCK SET locked=0, lockgranted=NULL, lockedby=NULL


WHERE id=1;





1条回答
  •  admin
    admin (楼主)
    2020-12-02 09:37

    这是flow-design或者flow模块启动的时候强制关闭会导致的情况,启动期间会锁定,启动完毕会解锁,如果期间没启动完就关闭就会锁定了。

    0 讨论(1)
提交回复