Search code examples
javaoraclespring-bootliquibaserds

Spring-Boot application is failing to start due to Liquibase issue on Oracle in StandardLockService


Running spring-boot 2.1.3.RELEASE and using liquibase 3.6.3 on Oracle 12.1.0.2.v15, I get exception on startup:

Did not update change log lock correctly.\n\n 0 rows were updated instead of the expected 1 row using executor oracle there are 0 rows in the table

This:

Investigating, I suspect it might be related to some missing right of my user as it works fine on a database created with AWS RDS 12.1.0.2.v15 but not on the on premise database.

The only noticeable difference is that the user for on premise has no access to v$parameter so I get:

Could not set check compatibility mode on OracleDatabase, assuming not running in any sort of compatibility mode: Cannot read from v$parameter: ..

Has anybody an idea ?

Can it be related to autocommit default value ?

Any link to requirements for Oracle user when using liquibase ?


Solution

  • So the issue ended up being an Oracle user misconfiguration by DBA, he had no privileges on tablespace.

    But this issue didn't appear in logs.

    Once I removed liquibase context:

    spring.liquibase.contexts

    The issue appeared clearly:

    ORA-01950 : no privileges on tablespace ....