Issue upgrading flowable common schema from 6.1.2.0 to 6.2.0.0

2017-11-13 10:09:47.730 INFO 10416 — [ main] o.f.idm.engine.impl.IdmEngineImpl : IdmEngine default created
2017-11-13 10:09:47.742 INFO 10416 — [ main] .d.AbstractSqlScriptBasedDbSchemaManager : upgrading flowable common schema from 6.1.2.0 to 6.2.0.0
2017-11-13 10:09:47.742 INFO 10416 — [ main] .d.AbstractSqlScriptBasedDbSchemaManager : Upgrade needed: 6120 -> 6200. Looking for schema update resource for component 'common’
2017-11-13 10:09:47.742 INFO 10416 — [ main] .d.AbstractSqlScriptBasedDbSchemaManager : performing upgrade on common with resource org/flowable/db/upgrade/flowable.all.upgradestep.6120.to.6200.common.sql
2017-11-13 10:09:47.742 INFO 10416 — [ main] .d.AbstractSqlScriptBasedDbSchemaManager : Found MySQL: majorVersion=5 minorVersion=5
2017-11-13 10:09:47.745 ERROR 10416 — [ main] .d.AbstractSqlScriptBasedDbSchemaManager : problem during schema upgrade, statement insert into ACT_GE_PROPERTY values (‘common.schema.version’, ‘6.2.0.0’, 1)

java.sql.SQLSyntaxErrorException: Table ‘manju.act_ge_property’ doesn’t exist
at com.mysql.cj.jdbc.exceptions.SQLError.createSQLException(SQLError.java:536) ~[mysql-connector-java-6.0.6.jar:6.0.6]
at com.mysql.cj.jdbc.exceptions.SQLError.createSQLException(SQLError.java:513) ~[mysql-connector-java-6.0.6.jar:6.0.6]
at com.mysql.cj.jdbc.exceptions.SQLExceptionsMapping.translateException(SQLExceptionsMapping.java:115) ~[mysql-connector-java-6.0.6.jar:6.0.6]
at com.mysql.cj.jdbc.ConnectionImpl.execSQL(ConnectionImpl.java:1983) ~[mysql-connector-java-6.0.6.jar:6.0.6]
at com.mysql.cj.jdbc.ConnectionImpl.execSQL(ConnectionImpl.java:1936) ~[mysql-connector-java-6.0.6.jar:6.0.6]
at com.mysql.cj.jdbc.StatementImpl.executeInternal(StatementImpl.java:891) ~[mysql-connector-java-6.0.6.jar:6.0.6]
at com.mysql.cj.jdbc.StatementImpl.execute(StatementImpl.java:795) ~[mysql-connector-java-6.0.6.jar:6.0.6]
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.8.0_144]
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[na:1.8.0_144]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_144]
at java.lang.reflect.Method.invoke(Method.java:498) ~[na:1.8.0_144]
at org.apache.tomcat.jdbc.pool.StatementFacade$StatementProxy.invoke(StatementFacade.java:114) ~[tomcat-jdbc-8.5.23.jar:na]
at com.sun.proxy.$Proxy65.execute(Unknown Source) ~[na:na]
at org.flowable.engine.common.impl.db.AbstractSqlScriptBasedDbSchemaManager.executeSchemaResource(AbstractSqlScriptBasedDbSchemaManager.java:271) [flowable-engine-common-6.2.0.jar:6.2.0]
at org.flowable.engine.common.impl.db.AbstractSqlScriptBasedDbSchemaManager.executeSchemaResource(AbstractSqlScriptBasedDbSchemaManager.java:192) [flowable-engine-common-6.2.0.jar:6.2.0]
at org.flowable.engine.common.impl.db.AbstractSqlScriptBasedDbSchemaManager.dbSchemaUpgrade(AbstractSqlScriptBasedDbSchemaManager.java:69) [flowable-engine-common-6.2.0.jar:6.2.0]
at org.flowable.engine.common.impl.db.ServiceSqlScriptBasedDbSchemaManager.dbSchemaUpdate(ServiceSqlScriptBasedDbSchemaManager.java:78) [flowable-engine-common-6.2.0.jar:6.2.0]
at org.flowable.engine.impl.db.ProcessDbSchemaManager.dbSchemaUpdate(ProcessDbSchemaManager.java:172) [flowable-engine-6.2.0.jar:6.2.0]
at org.flowable.engine.impl.db.ProcessDbSchemaManager.performSchemaOperationsProcessEngineBuild(ProcessDbSchemaManager.java:315) [flowable-engine-6.2.0.jar:6.2.0]
at org.flowable.engine.impl.SchemaOperationsProcessEngineBuild.execute(SchemaOperationsProcessEngineBuild.java:28) [flowable-engine-6.2.0.jar:6.2.0]
at org.flowable.engine.impl.interceptor.CommandInvoker$1.run(CommandInvoker.java:51) [flowable-engine-6.2.0.jar:6.2.0]
at org.flowable.engine.impl.interceptor.CommandInvoker.executeOperation(CommandInvoker.java:93) [flowable-engine-6.2.0.jar:6.2.0]
at org.flowable.engine.impl.interceptor.CommandInvoker.executeOperations(CommandInvoker.java:72) [flowable-engine-6.2.0.jar:6.2.0]
at org.flowable.engine.impl.interceptor.CommandInvoker.execute(CommandInvoker.java:56) [flowable-engine-6.2.0.jar:6.2.0]
at org.flowable.engine.impl.interceptor.BpmnOverrideContextInterceptor.execute(BpmnOverrideContextInterceptor.java:25) [flowable-engine-6.2.0.jar:6.2.0]
at org.flowable.engine.common.impl.interceptor.TransactionContextInterceptor.execute(TransactionContextInterceptor.java:53) [flowable-engine-common-6.2.0.jar:6.2.0]
at org.flowable.engine.common.impl.interceptor.CommandContextInterceptor.execute(CommandContextInterceptor.java:72) [flowable-engine-common-6.2.0.jar:6.2.0]
at org.flowable.spring.SpringTransactionInterceptor$1.doInTransaction(SpringTransactionInterceptor.java:49) [flowable-spring-6.2.0.jar:6.2.0]
at org.springframework.transaction.support.TransactionTemplate.execute(TransactionTemplate.java:133) [spring-tx-4.3.12.RELEASE.jar:4.3.12.RELEASE]
at org.flowable.spring.SpringTransactionInterceptor.execute(SpringTransactionInterceptor.java:46) [flowable-spring-6.2.0.jar:6.2.0]
at org.flowable.engine.common.impl.interceptor.LogInterceptor.execute(LogInterceptor.java:30) [flowable-engine-common-6.2.0.jar:6.2.0]
at org.flowable.engine.common.impl.cfg.CommandExecutorImpl.execute(CommandExecutorImpl.java:56) [flowable-engine-common-6.2.0.jar:6.2.0]
at org.flowable.engine.impl.ProcessEngineImpl.(ProcessEngineImpl.java:78) [flowable-engine-6.2.0.jar:6.2.0]
at org.flowable.engine.impl.cfg.ProcessEngineConfigurationImpl.buildProcessEngine(ProcessEngineConfigurationImpl.java:775) [flowable-engine-6.2.0.jar:6.2.0]
at org.flowable.spring.SpringProcessEngineConfiguration.buildProcessEngine(SpringProcessEngineConfiguration.java:68) [flowable-spring-6.2.0.jar:6.2.0]
at org.flowable.spring.ProcessEngineFactoryBean.getObject(ProcessEngineFactoryBean.java:60) [flowable-spring-6.2.0.jar:6.2.0]
at org.flowable.spring.ProcessEngineFactoryBean.getObject(ProcessEngineFactoryBean.java:32) [flowable-spring-6.2.0.jar:6.2.0]
at org.springframework.beans.factory.support.FactoryBeanRegistrySupport.doGetObjectFromFactoryBean(FactoryBeanRegistrySupport.java:168) [spring-beans-4.3.12.RELEASE.jar:4.3.12.RELEASE]
at org.springframework.beans.factory.support.FactoryBeanRegistrySupport.getObjectFromFactoryBean(FactoryBeanRegistrySupport.java:103) [spring-beans-4.3.12.RELEASE.jar:4.3.12.RELEASE]
at org.springframework.beans.factory.support.AbstractBeanFactory.getObjectForBeanInstance(AbstractBeanFactory.java:1634) [spring-beans-4.3.12.RELEASE.jar:4.3.12.RELEASE]
at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:254) [spring-beans-4.3.12.RELEASE.jar:4.3.12.RELEASE]
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:202) [spring-beans-4.3.12.RELEASE.jar:4.3.12.RELEASE]
at org.springframework.beans.factory.config.DependencyDescriptor.resolveCandidate(DependencyDescriptor.java:208) [spring-beans-4.3.12.RELEASE.jar:4.3.12.RELEASE]
at org.springframework.beans.factory.support.DefaultListableBeanFactory.addCandidateEntry(DefaultListableBeanFactory.java:1316) [spring-beans-4.3.12.RELEASE.jar:4.3.12.RELEASE]
at org.springframework.beans.factory.support.DefaultListableBeanFactory.findAutowireCandidates(DefaultListableBeanFactory.java:1282) [spring-beans-4.3.12.RELEASE.jar:4.3.12.RELEASE]
at org.springframework.beans.factory.support.DefaultListableBeanFactory.doResolveDependency(DefaultListableBeanFactory.java:1101) [spring-beans-4.3.12.RELEASE.jar:4.3.12.RELEASE]
at org.springframework.beans.factory.support.DefaultListableBeanFactory.resolveDependency(DefaultListableBeanFactory.java:1066) [spring-beans-4.3.12.RELEASE.jar:4.3.12.RELEASE]
at org.springframework.beans.factory.support.ConstructorResolver.resolveAutowiredArgument(ConstructorResolver.java:835) [spring-beans-4.3.12.RELEASE.jar:4.3.12.RELEASE]
at org.springframework.beans.factory.support.ConstructorResolver.createArgumentArray(ConstructorResolver.java:741) [spring-beans-4.3.12.RELEASE.jar:4.3.12.RELEASE]
at org.springframework.beans.factory.support.ConstructorResolver.instantiateUsingFactoryMethod(ConstructorResolver.java:467) [spring-beans-4.3.12.RELEASE.jar:4.3.12.RELEASE]
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.instantiateUsingFactoryMethod(AbstractAutowireCapableBeanFactory.java:1173) [spring-beans-4.3.12.RELEASE.jar:4.3.12.RELEASE]
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:1067) [spring-beans-4.3.12.RELEASE.jar:4.3.12.RELEASE]
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:513) [spring-beans-4.3.12.RELEASE.jar:4.3.12.RELEASE]
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:483) [spring-beans-4.3.12.RELEASE.jar:4.3.12.RELEASE]
at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:306) [spring-beans-4.3.12.RELEASE.jar:4.3.12.RELEASE]
at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:230) [spring-beans-4.3.12.RELEASE.jar:4.3.12.RELEASE]
at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:302) [spring-beans-4.3.12.RELEASE.jar:4.3.12.RELEASE]
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:197) [spring-beans-4.3.12.RELEASE.jar:4.3.12.RELEASE]
at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:761) [spring-beans-4.3.12.RELEASE.jar:4.3.12.RELEASE]
at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:867) [spring-context-4.3.12.RELEASE.jar:4.3.12.RELEASE]
at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:543) [spring-context-4.3.12.RELEASE.jar:4.3.12.RELEASE]
at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:693) [spring-boot-1.5.8.RELEASE.jar:1.5.8.RELEASE]
at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:360) [spring-boot-1.5.8.RELEASE.jar:1.5.8.RELEASE]
at org.springframework.boot.SpringApplication.run(SpringApplication.java:303) [spring-boot-1.5.8.RELEASE.jar:1.5.8.RELEASE]
at org.springframework.boot.SpringApplication.run(SpringApplication.java:1118) [spring-boot-1.5.8.RELEASE.jar:1.5.8.RELEASE]
at org.springframework.boot.SpringApplication.run(SpringApplication.java:1107) [spring-boot-1.5.8.RELEASE.jar:1.5.8.RELEASE]
at com.fico.om.FlowableAsyncHistoryApplication.main(FlowableAsyncHistoryApplication.java:39) [classes/:na]

Hi,

When you are doing an upgrade the act_ge_property should exist already.

So, can you check why it can’t find this table? Is that table really not there? If you were running Flowable 6.1.2 that table should already have been created.

Best regards,

Tijs

Hi tijs,

Same thing happened with me. Creating a fresh database works but updating from 6.1.2 gives this error.

Also, after updating to 6.2.0 with fresh database, i am not able to log in to idm webapp. it shows 401 unauthorized although i am using kermit creds that are available by default in fresh database.

Thank You
Arpit

Hi Arpit,

When you are already using 6.1.2 I’m surprised you are logging in to the IDM app using kermit. The IDM app has an admin user by default, that was also the case with 6.1.2. We have upgrade tests that show the upgrade from 6.1.2 to 6.2.0 should work, so if it’s not working for you we need more details on how we can reproduce it exactly.

Best regards,

Tijs

Hi tijs,

I was using a fresh database bacause i was also facing the same problem as original post. The exact problem was : Unable to login to Flowable UI applications after a fresh installation . For now i have used the trick mentioned in the comments and i think the issue is still open on github.

As for login using kermit when i was facing this login issue, i checked the database and kermit was the user with access to admin group, thats why i tried using kermit. Later on i realised that admin is the user with privilege to access idm and all other apps.

Thanks
Arpit

Hi Arpit,

Sure I understand. But do you have more details on how we can reproduce the database upgrade issue from this post?

Best regards,

Tijs

Hi Tijs,

I didn’t do anything new. I deployed the version 6.2.0 all apps on my tomcat server with changed database configs and error occured. I just did the same thing again with only idm, modeler and task apps and everything worked i didn’t get any error. Maybe as mentioned in the link i posted in last comment, its because of the flowable-rest getting deployed before the idm or modeler app which might be causing the problem,but i am not sure.

Edit : I just deployed all apps on 6.1.2 version database and no error occured. So i am not sure why the error occured first time.

Edit 2: I just noticed that if i use “mysql-connector-java-6.0.6.jar” upgrade is not happening (but i dont get any error also) but if i use “mysql-connector-java-5.1.41.jar”, upgrade is happpening.

Thanks
Arpit

Hi Arpit,

Issue is mysql-connector-java-6.0.6

flowable 6.2.0 is using <mysql.version>5.1.44</mysql.version> internally.

After i removed the version of mysql dependency from my pom.xml issue got resolved

Thanks,
Manjunath

1 Like