Skip to content

Conversation

@olavloite
Copy link
Collaborator

@olavloite olavloite commented Oct 30, 2024

Spanner requires that all UPDATE and DELETE statements contain a WHERE clause as safety precaution against accidental updates and deletes. Liquibase however by default generates UPDATE and DELETE statements without a WHERE clause if none has been specified. The Spanner Liquibase provider therefore now adds custom generators for those statements that automatically add a WHERE true clause to statements that do not have a WHERE clause.

The clear-checksums command (https://docs.liquibase.com/commands/utility/clear-checksums.html) generated such an update statement, and would therefore fail with an error like this:

INVALID_ARGUMENT: com.google.api.gax.rpc.InvalidArgumentException: io.grpc.StatusRuntimeException:  
INVALID_ARGUMENT: UPDATE must have a WHERE clause [at 1:1]
UPDATE DATABASECHANGELOG SET MD5SUM = NULL

Spanner requires that all UPDATE and DELETE statements contain
a WHERE clause as safety precaution against accidental updates
and deletes. Liquibase however by default generates UPDATE and
DELETE statements without a WHERE clause if none has been
specified. The Spanner Liquibase provider therefore now adds
custom generators for those statements that automatically add
a `WHERE true` clause to statements that do not have a WHERE
clause.
@olavloite olavloite merged commit 97eb380 into master Oct 31, 2024
6 checks passed
@olavloite olavloite deleted the clear-checksums branch October 31, 2024 15:37
@thejeff77
Copy link

Awesome thanks! We're on a production incident now, and would appreciate an expedited tagging of this release so we can resolve the new build.

@olavloite
Copy link
Collaborator Author

@thejeff77

Awesome thanks! We're on a production incident now, and would appreciate an expedited tagging of this release so we can resolve the new build.

https://github.com/cloudspannerecosystem/liquibase-spanner/releases/tag/4.29.2.1

@thejeff77
Copy link

@olavloite We're wondering what causes clear-checksum to run in the first place. We hadn't checked in any changes to any of the scripts. We verified they remained un-modified. We also hadn't deployed any new scripts.

Are there other events that may trigger clear-checksum to try to run, other than a checksum mismatch? Or is it possible to have a checksum-mismatch triggered erroneously?

Thanks for any additional insight you could provide us on this issue.

@patiramyadav
Copy link

patiramyadav commented Oct 31, 2024

More context, 4.29.2 was running in prod since 7 days, we tried to deploy new spring boot update. We have canary deployment, which runs extra pod before it prompt to primary one. After canary failure, primary pod which was created 7 days ago was also starting to fail to scale because of same reason.

I verified and reported issue to google immediately through DoIT. I checked all the DATABASECHANGELOG and LOCK, there were nothing modified.

As @thejeff77 mentioned, I think some other library is triggering this, I am able to re-produce in my local. Is it side effect of spanner-jdbc?

I can explain more in details if you need.

@patiramyadav
Copy link

`
15:32:55.099 | WARN | o.s.b.w.s.c.AnnotationConfigServletWebServerApplicationContext | Exception encountered during context initialization - cancelling refresh attempt: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'liquibase' defined in class path resource [org/springframework/boot/autoconfigure/liquibase/LiquibaseAutoConfiguration$LiquibaseConfiguration.class]: INVALID_ARGUMENT: com.google.api.gax.rpc.InvalidArgumentException: io.grpc.StatusRuntimeException: INVALID_ARGUMENT: UPDATE must have a WHERE clause [at 1:1]
UPDATE DATABASECHANGELOG SET MD5SUM = NULL
^ [Failed SQL: (3) UPDATE DATABASECHANGELOG SET MD5SUM = NULL]
15:32:55.099 | INFO | c.z.h.HikariDataSource | HikariPool-1 - Shutdown initiated...
15:32:55.105 | INFO | c.z.h.HikariDataSource | HikariPool-1 - Shutdown completed.
15:32:55.106 | INFO | o.a.c.c.StandardService | Stopping service [Tomcat]
15:32:55.117 | INFO | o.s.b.a.l.ConditionEvaluationReportLogger |

Error starting ApplicationContext. To display the condition evaluation report re-run your application with 'debug' enabled.
15:32:55.129 | ERROR | o.s.b.SpringApplication | Application run failed
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'liquibase' defined in class path resource [org/springframework/boot/autoconfigure/liquibase/LiquibaseAutoConfiguration$LiquibaseConfiguration.class]: INVALID_ARGUMENT: com.google.api.gax.rpc.InvalidArgumentException: io.grpc.StatusRuntimeException: INVALID_ARGUMENT: UPDATE must have a WHERE clause [at 1:1]
UPDATE DATABASECHANGELOG SET MD5SUM = NULL
^ [Failed SQL: (3) UPDATE DATABASECHANGELOG SET MD5SUM = NULL]
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1770)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:598)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:520)
at org.springframework.beans.factory.support.AbstractBeanFactory.lambda$doGetBean$0(AbstractBeanFactory.java:326)
at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:234)
at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:324)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:200)
at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:313)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:200)
at org.springframework.context.support.AbstractApplicationContext.getBean(AbstractApplicationContext.java:1132)
at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:907)
at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:584)
at org.springframework.boot.web.servlet.context.ServletWebServerApplicationContext.refresh(ServletWebServerApplicationContext.java:146)
at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:732)
at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:434)
at org.springframework.boot.SpringApplication.run(SpringApplication.java:310)
at org.springframework.boot.SpringApplication.run(SpringApplication.java:1304)
at org.springframework.boot.SpringApplication.run(SpringApplication.java:1293)
at pckagage.ApplicationKt.main(Application.kt:29)
Caused by: liquibase.exception.DatabaseException: INVALID_ARGUMENT: com.google.api.gax.rpc.InvalidArgumentException: io.grpc.StatusRuntimeException: INVALID_ARGUMENT: UPDATE must have a WHERE clause [at 1:1]
UPDATE DATABASECHANGELOG SET MD5SUM = NULL
^ [Failed SQL: (3) UPDATE DATABASECHANGELOG SET MD5SUM = NULL]
at liquibase.executor.jvm.JdbcExecutor$ExecuteStatementCallback.doInStatement(JdbcExecutor.java:447)
at liquibase.executor.jvm.JdbcExecutor.execute(JdbcExecutor.java:78)
at liquibase.executor.jvm.JdbcExecutor.execute(JdbcExecutor.java:161)
at liquibase.executor.jvm.JdbcExecutor.execute(JdbcExecutor.java:126)
at liquibase.changelog.StandardChangeLogHistoryService.init(StandardChangeLogHistoryService.java:282)
at liquibase.Liquibase.checkLiquibaseTables(Liquibase.java:1953)
at liquibase.Liquibase.lambda$update$1(Liquibase.java:251)
at liquibase.Scope.lambda$child$0(Scope.java:180)
at liquibase.Scope.child(Scope.java:189)
at liquibase.Scope.child(Scope.java:179)
at liquibase.Scope.child(Scope.java:158)
at liquibase.Liquibase.runInScope(Liquibase.java:2447)
at liquibase.Liquibase.update(Liquibase.java:236)
at liquibase.Liquibase.update(Liquibase.java:221)
at liquibase.integration.spring.SpringLiquibase.performUpdate(SpringLiquibase.java:328)
at liquibase.integration.spring.SpringLiquibase.afterPropertiesSet(SpringLiquibase.java:283)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1816)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1766)
... 18 common frames omitted
Caused by: com.google.cloud.spanner.jdbc.JdbcSqlExceptionFactory$JdbcSqlExceptionImpl: INVALID_ARGUMENT: com.google.api.gax.rpc.InvalidArgumentException: io.grpc.StatusRuntimeException: INVALID_ARGUMENT: UPDATE must have a WHERE clause [at 1:1]
UPDATE DATABASECHANGELOG SET MD5SUM = NULL
^
at com.google.cloud.spanner.jdbc.JdbcSqlExceptionFactory.of(JdbcSqlExceptionFactory.java:221)
at com.google.cloud.spanner.jdbc.AbstractJdbcStatement.execute(AbstractJdbcStatement.java:263)
at com.google.cloud.spanner.jdbc.JdbcStatement.executeStatement(JdbcStatement.java:108)
at com.google.cloud.spanner.jdbc.JdbcStatement.execute(JdbcStatement.java:104)
at com.zaxxer.hikari.pool.ProxyStatement.execute(ProxyStatement.java:94)
at com.zaxxer.hikari.pool.HikariProxyStatement.execute(HikariProxyStatement.java)
at liquibase.executor.jvm.JdbcExecutor$ExecuteStatementCallback.doInStatement(JdbcExecutor.java:443)
... 35 common frames omitted
Caused by: com.google.cloud.spanner.SpannerException: INVALID_ARGUMENT: com.google.api.gax.rpc.InvalidArgumentException: io.grpc.StatusRuntimeException: INVALID_ARGUMENT: UPDATE must have a WHERE clause [at 1:1]
UPDATE DATABASECHANGELOG SET MD5SUM = NULL
^
at com.google.cloud.spanner.SpannerExceptionFactory.newSpannerExceptionPreformatted(SpannerExceptionFactory.java:291)
at com.google.cloud.spanner.SpannerExceptionFactory.newSpannerExceptionPreformatted(SpannerExceptionFactory.java:297)
at com.google.cloud.spanner.SpannerExceptionFactory.newSpannerException(SpannerExceptionFactory.java:61)
at com.google.cloud.spanner.SpannerExceptionFactory.newSpannerException(SpannerExceptionFactory.java:181)
at com.google.cloud.spanner.spi.v1.GapicSpannerRpc.get(GapicSpannerRpc.java:1883)
at com.google.cloud.spanner.spi.v1.GapicSpannerRpc.executeQuery(GapicSpannerRpc.java:1662)
at com.google.cloud.spanner.TransactionRunnerImpl$TransactionContextImpl.internalExecuteUpdate(TransactionRunnerImpl.java:720)
at com.google.cloud.spanner.TransactionRunnerImpl$TransactionContextImpl.executeUpdate(TransactionRunnerImpl.java:704)
at com.google.cloud.spanner.connection.SingleUseTransaction.lambda$executeTransactionalUpdateAsync$4(SingleUseTransaction.java:433)
at com.google.cloud.spanner.TransactionRunnerImpl.lambda$runInternal$0(TransactionRunnerImpl.java:996)
at com.google.api.gax.retrying.DirectRetryingExecutor.submit(DirectRetryingExecutor.java:103)
at com.google.cloud.RetryHelper.run(RetryHelper.java:76)
at com.google.cloud.RetryHelper.runWithRetries(RetryHelper.java:50)
at com.google.cloud.spanner.SpannerRetryHelper.runTxWithRetriesOnAborted(SpannerRetryHelper.java:79)
at com.google.cloud.spanner.SpannerRetryHelper.runTxWithRetriesOnAborted(SpannerRetryHelper.java:68)
at com.google.cloud.spanner.TransactionRunnerImpl.runInternal(TransactionRunnerImpl.java:1053)
at com.google.cloud.spanner.TransactionRunnerImpl.run(TransactionRunnerImpl.java:958)
at com.google.cloud.spanner.SessionPool$SessionPoolTransactionRunner.run(SessionPool.java:951)
at com.google.cloud.spanner.connection.SingleUseTransaction.lambda$executeTransactionalUpdateAsync$5(SingleUseTransaction.java:429)
at io.grpc.Context$2.call(Context.java:583)
at com.google.common.util.concurrent.TrustedListenableFutureTask$TrustedFutureInterruptibleTask.runInterruptibly(TrustedListenableFutureTask.java:131)
at com.google.common.util.concurrent.InterruptibleTask.run(InterruptibleTask.java:74)
at com.google.common.util.concurrent.TrustedListenableFutureTask.run(TrustedListenableFutureTask.java:82)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635)
at java.base/java.lang.Thread.run(Thread.java:840)
Suppressed: com.google.cloud.spanner.connection.AbstractBaseUnitOfWork$SpannerAsyncExecutionException: Execution failed for statement: UPDATE DATABASECHANGELOG SET MD5SUM = NULL
at com.google.cloud.spanner.connection.AbstractBaseUnitOfWork.executeStatementAsync(AbstractBaseUnitOfWork.java:242)
at com.google.cloud.spanner.connection.AbstractBaseUnitOfWork.executeStatementAsync(AbstractBaseUnitOfWork.java:167)
at com.google.cloud.spanner.connection.SingleUseTransaction.executeTransactionalUpdateAsync(SingleUseTransaction.java:447)
at com.google.cloud.spanner.connection.SingleUseTransaction.executeUpdateAsync(SingleUseTransaction.java:343)
at com.google.cloud.spanner.connection.ConnectionImpl.internalExecuteUpdateAsync(ConnectionImpl.java:1245)
at com.google.cloud.spanner.connection.ConnectionImpl.execute(ConnectionImpl.java:859)
at com.google.cloud.spanner.jdbc.AbstractJdbcStatement.execute(AbstractJdbcStatement.java:254)
at com.google.cloud.spanner.jdbc.JdbcStatement.executeStatement(JdbcStatement.java:108)
at com.google.cloud.spanner.jdbc.JdbcStatement.execute(JdbcStatement.java:104)
at com.zaxxer.hikari.pool.ProxyStatement.execute(ProxyStatement.java:94)
at com.zaxxer.hikari.pool.HikariProxyStatement.execute(HikariProxyStatement.java)
at liquibase.executor.jvm.JdbcExecutor$ExecuteStatementCallback.doInStatement(JdbcExecutor.java:443)
at liquibase.executor.jvm.JdbcExecutor.execute(JdbcExecutor.java:78)
at liquibase.executor.jvm.JdbcExecutor.execute(JdbcExecutor.java:161)
at liquibase.executor.jvm.JdbcExecutor.execute(JdbcExecutor.java:126)
at liquibase.changelog.StandardChangeLogHistoryService.init(StandardChangeLogHistoryService.java:282)
at liquibase.Liquibase.checkLiquibaseTables(Liquibase.java:1953)
at liquibase.Liquibase.lambda$update$1(Liquibase.java:251)
at liquibase.Scope.lambda$child$0(Scope.java:180)
at liquibase.Scope.child(Scope.java:189)
at liquibase.Scope.child(Scope.java:179)
at liquibase.Scope.child(Scope.java:158)
at liquibase.Liquibase.runInScope(Liquibase.java:2447)
at liquibase.Liquibase.update(Liquibase.java:236)
at liquibase.Liquibase.update(Liquibase.java:221)
at liquibase.integration.spring.SpringLiquibase.performUpdate(SpringLiquibase.java:328)
at liquibase.integration.spring.SpringLiquibase.afterPropertiesSet(SpringLiquibase.java:283)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1816)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1766)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:598)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:520)
at org.springframework.beans.factory.support.AbstractBeanFactory.lambda$doGetBean$0(AbstractBeanFactory.java:326)
at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:234)
at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:324)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:200)
at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:313)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:200)
at org.springframework.context.support.AbstractApplicationContext.getBean(AbstractApplicationContext.java:1132)
at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:907)
at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:584)
at org.springframework.boot.web.servlet.context.ServletWebServerApplicationContext.refresh(ServletWebServerApplicationContext.java:146)
at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:732)
at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:434)
at org.springframework.boot.SpringApplication.run(SpringApplication.java:310)
at org.springframework.boot.SpringApplication.run(SpringApplication.java:1304)
at org.springframework.boot.SpringApplication.run(SpringApplication.java:1293)
at pckagage.ApplicationKt.main(Application.kt:29)
Caused by: java.util.concurrent.ExecutionException: com.google.api.gax.rpc.InvalidArgumentException: io.grpc.StatusRuntimeException: INVALID_ARGUMENT: UPDATE must have a WHERE clause [at 1:1]
UPDATE DATABASECHANGELOG SET MD5SUM = NULL
^
at com.google.common.util.concurrent.AbstractFuture.getDoneValue(AbstractFuture.java:588)
at com.google.common.util.concurrent.AbstractFuture.get(AbstractFuture.java:567)
at com.google.cloud.spanner.spi.v1.GapicSpannerRpc.get(GapicSpannerRpc.java:1877)
... 21 common frames omitted
Caused by: com.google.api.gax.rpc.InvalidArgumentException: io.grpc.StatusRuntimeException: INVALID_ARGUMENT: UPDATE must have a WHERE clause [at 1:1]
UPDATE DATABASECHANGELOG SET MD5SUM = NULL
^
at com.google.api.gax.rpc.ApiExceptionFactory.createException(ApiExceptionFactory.java:92)
at com.google.api.gax.grpc.GrpcApiExceptionFactory.create(GrpcApiExceptionFactory.java:98)
at com.google.api.gax.grpc.GrpcApiExceptionFactory.create(GrpcApiExceptionFactory.java:66)
at com.google.api.gax.grpc.GrpcExceptionCallable$ExceptionTransformingFuture.onFailure(GrpcExceptionCallable.java:97)
at com.google.api.core.ApiFutures$1.onFailure(ApiFutures.java:67)
at com.google.common.util.concurrent.Futures$CallbackListener.run(Futures.java:1132)
at com.google.common.util.concurrent.DirectExecutor.execute(DirectExecutor.java:31)
at com.google.common.util.concurrent.AbstractFuture.executeListener(AbstractFuture.java:1270)
at com.google.common.util.concurrent.AbstractFuture.complete(AbstractFuture.java:1038)
at com.google.common.util.concurrent.AbstractFuture.setException(AbstractFuture.java:808)
at io.grpc.stub.ClientCalls$GrpcFuture.setException(ClientCalls.java:574)
at io.grpc.stub.ClientCalls$UnaryStreamToFuture.onClose(ClientCalls.java:544)
at io.grpc.PartialForwardingClientCallListener.onClose(PartialForwardingClientCallListener.java:39)
at io.grpc.ForwardingClientCallListener.onClose(ForwardingClientCallListener.java:23)
at io.grpc.ForwardingClientCallListener$SimpleForwardingClientCallListener.onClose(ForwardingClientCallListener.java:40)
at com.google.api.gax.grpc.ChannelPool$ReleasingClientCall$1.onClose(ChannelPool.java:541)
at io.grpc.PartialForwardingClientCallListener.onClose(PartialForwardingClientCallListener.java:39)
at io.grpc.ForwardingClientCallListener.onClose(ForwardingClientCallListener.java:23)
at io.grpc.ForwardingClientCallListener$SimpleForwardingClientCallListener.onClose(ForwardingClientCallListener.java:40)
at io.grpc.PartialForwardingClientCallListener.onClose(PartialForwardingClientCallListener.java:39)
at io.grpc.ForwardingClientCallListener.onClose(ForwardingClientCallListener.java:23)
at io.grpc.ForwardingClientCallListener$SimpleForwardingClientCallListener.onClose(ForwardingClientCallListener.java:40)
at com.google.cloud.spanner.spi.v1.SpannerErrorInterceptor$1$1.onClose(SpannerErrorInterceptor.java:100)
at io.grpc.internal.ClientCallImpl.closeObserver(ClientCallImpl.java:576)
at io.grpc.internal.ClientCallImpl.access$300(ClientCallImpl.java:70)
at io.grpc.internal.ClientCallImpl$ClientStreamListenerImpl$1StreamClosed.runInternal(ClientCallImpl.java:757)
at io.grpc.internal.ClientCallImpl$ClientStreamListenerImpl$1StreamClosed.runInContext(ClientCallImpl.java:736)
at io.grpc.internal.ContextRunnable.run(ContextRunnable.java:37)
at io.grpc.internal.SerializingExecutor.run(SerializingExecutor.java:133)
at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:539)
at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
at java.base/java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:304)
... 3 common frames omitted
Caused by: io.grpc.StatusRuntimeException: INVALID_ARGUMENT: UPDATE must have a WHERE clause [at 1:1]
UPDATE DATABASECHANGELOG SET MD5SUM = NULL
^
at io.grpc.Status.asRuntimeException(Status.java:539)
... 24 common frames omitted

Process finished with exit code 1

`

@olavloite
Copy link
Collaborator Author

@patiramyadav I don't know what triggers Liquibase to run clear-checksums in this case, but I think that the interesting line from the stacktrace that you shared is this one:

at liquibase.changelog.StandardChangeLogHistoryService.init(StandardChangeLogHistoryService.java:282)

If you look at the Liquibase source code for version 4.29.2 (https://github.com/liquibase/liquibase/blob/v4.29.2/liquibase-standard/src/main/java/liquibase/changelog/StandardChangeLogHistoryService.java), then you'll see that this looks impossible, as line 282 is empty. Could it be that Spring or some of the other dependencies in your application are pulling in a different version of Liquibase? Could you otherwise check what that line is in the version of Liquibase that you are using?

@patiramyadav
Copy link

image image

It is referring to liquibase core 4.17.2, The line 282 is still empty.

@patiramyadav
Copy link

at liquibase.changelog.StandardChangeLogHistoryService.init(StandardChangeLogHistoryService.java:282)
		at liquibase.Liquibase.checkLiquibaseTables(Liquibase.java:1953)

@olavloite
Copy link
Collaborator Author

@patiramyadav
Liquibase core 4.17.2 line 282 is not empty: https://github.com/liquibase/liquibase/blob/v4.17.2/liquibase-core/src/main/java/liquibase/changelog/StandardChangeLogHistoryService.java#L282

But one possible reason for this problem here is that you seem to have conflicting Liquibase versions on your classpath. The Spanner Liquibase versions are kept in sync with the Liquibase versions. Meaning that Liquibase Spanner v4.29.2 should be used with Liquibase 4.29.2. If you add Liquibase core 4.17.2 to the classpath, and at the same time also use Liquibase Spanner 4.29.2, then the two might not be compatible. Exactly which version will be picked up by your application can then then also be rather arbitrary, meaning that completely unrelated changes (or even just building on a different machine) could trigger the other version to be picked up. That again can trigger this check to nullify all existing checksums: https://github.com/liquibase/liquibase/blob/347c33d055305df45b5df8ba70f0ed03cdb1ce20/liquibase-core/src/main/java/liquibase/changelog/StandardChangeLogHistoryService.java#L250

@patiramyadav
Copy link

Thanks, We also forced to use exact version.

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

Successfully merging this pull request may close these issues.

3 participants