Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update Liquibase version #2179

Closed
nazarimilad opened this issue Feb 19, 2020 · 5 comments
Closed

Update Liquibase version #2179

nazarimilad opened this issue Feb 19, 2020 · 5 comments

Comments

@nazarimilad
Copy link

nazarimilad commented Feb 19, 2020

When using Flowable 6.5.0, I'm getting a NullpointerException from LiquibaseUtil (see https://liquibase.jira.com/browse/CORE-3468 & liquibase/liquibase#919 ).

This issue has been resolved in Liquibase 3.8.1. The current latest version of Liquibase is 3.8.6, hoewever Flowable 6.5.0 is still using Liquibase 3.8.0

Will there be an update?

@filiphr
Copy link
Contributor

filiphr commented Feb 19, 2020

Can you please share the stacktrace where you are getting the NPE? We have extensive test suites and we haven't seen any NPEs.

Currently I am a bit reluctant to upgrade the Lqiuibase version due to the decision from Liquibase to include obfuscate Liquibase Pro code in their liquibase-core jars available on Maven Central. This is from being done from 3.8.1. This also means that https://github.com/liquibase/liquibase is no longer the source for the liquibase-core jar (it is a partial source).

You can have a deeper look at this Twitter thread, CORE-3537. The new packaging of liquibase-core has also lead to other issues:

@nazarimilad
Copy link
Author

That's completely understandable. Here is the stacktrace:

Exception in thread "main" org.flowable.common.engine.api.FlowableException: Error initialising eventregistry data model

at org.flowable.common.engine.impl.db.LiquibaseBasedSchemaManager.initSchema(LiquibaseBasedSchemaManager.java:68)

at org.flowable.eventregistry.impl.db.EventDbSchemaManager.initSchema(EventDbSchemaManager.java:36)

at org.flowable.eventregistry.impl.cmd.SchemaOperationsEventRegistryEngineBuild.execute(SchemaOperationsEventRegistryEngineBuild.java:29)

at org.flowable.eventregistry.impl.cmd.SchemaOperationsEventRegistryEngineBuild.execute(SchemaOperationsEventRegistryEngineBuild.java:24)

at org.flowable.common.engine.impl.interceptor.DefaultCommandInvoker.execute(DefaultCommandInvoker.java:22)

at org.flowable.common.engine.impl.interceptor.TransactionContextInterceptor.execute(TransactionContextInterceptor.java:53)

at org.flowable.common.engine.impl.interceptor.CommandContextInterceptor.execute(CommandContextInterceptor.java:72)

at org.flowable.common.engine.impl.interceptor.LogInterceptor.execute(LogInterceptor.java:35)

at org.flowable.common.engine.impl.cfg.CommandExecutorImpl.execute(CommandExecutorImpl.java:56)

at org.flowable.eventregistry.impl.EventRegistryEngineImpl.<init>(EventRegistryEngineImpl.java:47)

at org.flowable.eventregistry.impl.EventRegistryEngineConfiguration.buildEventRegistryEngine(EventRegistryEngineConfiguration.java:189)

at org.flowable.eventregistry.impl.configurator.EventRegistryEngineConfigurator.initEventRegistryEngine(EventRegistryEngineConfigurator.java:87)

at org.flowable.eventregistry.impl.configurator.EventRegistryEngineConfigurator.configure(EventRegistryEngineConfigurator.java:64)

at org.flowable.common.engine.impl.AbstractEngineConfiguration.configuratorsAfterInit(AbstractEngineConfiguration.java:1006)

at org.flowable.engine.impl.cfg.ProcessEngineConfigurationImpl.init(ProcessEngineConfigurationImpl.java:1065)

at org.flowable.engine.impl.cfg.ProcessEngineConfigurationImpl.buildProcessEngine(ProcessEngineConfigurationImpl.java:957)

 at xxxxxxxxx (company code)

Caused by: org.flowable.common.engine.api.FlowableException: Error updating eventregistry engine tables

at org.flowable.common.engine.impl.db.LiquibaseBasedSchemaManager.schemaUpdate(LiquibaseBasedSchemaManager.java:105)

at org.flowable.eventregistry.impl.db.EventDbSchemaManager.schemaUpdate(EventDbSchemaManager.java:63)

at org.flowable.common.engine.impl.db.LiquibaseBasedSchemaManager.initSchema(LiquibaseBasedSchemaManager.java:61)

... 20 more

Caused by: java.lang.NullPointerException

at liquibase.util.LiquibaseUtil.getBuildInfo(LiquibaseUtil.java:45)

at liquibase.util.LiquibaseUtil.getBuildVersion(LiquibaseUtil.java:17)

at liquibase.sqlgenerator.core.MarkChangeSetRanGenerator.generateSql(MarkChangeSetRanGenerator.java:91)

at liquibase.sqlgenerator.core.MarkChangeSetRanGenerator.generateSql(MarkChangeSetRanGenerator.java:25)

at liquibase.sqlgenerator.SqlGeneratorChain.generateSql(SqlGeneratorChain.java:30)

at liquibase.sqlgenerator.SqlGeneratorFactory.generateSql(SqlGeneratorFactory.java:222)

at liquibase.executor.AbstractExecutor.applyVisitors(AbstractExecutor.java:25)

at liquibase.executor.jvm.JdbcExecutor.access$600(JdbcExecutor.java:40)

at liquibase.executor.jvm.JdbcExecutor$ExecuteStatementCallback.doInStatement(JdbcExecutor.java:384)

at liquibase.executor.jvm.JdbcExecutor.execute(JdbcExecutor.java:59)

at liquibase.executor.jvm.JdbcExecutor.execute(JdbcExecutor.java:131)

at liquibase.executor.jvm.JdbcExecutor.execute(JdbcExecutor.java:111)

at liquibase.changelog.StandardChangeLogHistoryService.setExecType(StandardChangeLogHistoryService.java:388)

at liquibase.database.AbstractJdbcDatabase.markChangeSetExecStatus(AbstractJdbcDatabase.java:1130)

at liquibase.changelog.visitor.UpdateVisitor.visit(UpdateVisitor.java:64)

at liquibase.changelog.ChangeLogIterator.run(ChangeLogIterator.java:83)

at liquibase.Liquibase.update(Liquibase.java:202)

at liquibase.Liquibase.update(Liquibase.java:179)

at liquibase.Liquibase.update(Liquibase.java:175)

at liquibase.Liquibase.update(Liquibase.java:168)

at org.flowable.common.engine.impl.db.LiquibaseBasedSchemaManager.schemaUpdate(LiquibaseBasedSchemaManager.java:103)

... 22 more

@filiphr
Copy link
Contributor

filiphr commented Feb 19, 2020

Since you are building your own application you have 2 options:

  1. Upgrade liquibase to a newer version in your own application
  2. Make sure that the manifest from liquibase is within the shaded application

@filiphr
Copy link
Contributor

filiphr commented Feb 19, 2020

I forgot to add a 3rd option. We need to discuss within the team whether there is something that we can do about this, by using Liquibase in a different manner or not using it at all. My personal opinion is too keep using liquibase since it is quite powerful and allows us to easily support different databases.

@nazarimilad
Copy link
Author

I agree, it's unfortunate to hear that Liquidbase's team decided to include obfuscate Liquibase Pro code though. But thanks for the tips, I appreciate it!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants