Quantcast
Channel: Liquibase Forums
Viewing all articles
Browse latest Browse all 2993

Re : check migration status without locking

$
0
0
some more info from me. I just digged through the code. I simply dont understand why a read-only operation like "listUnrunChangeSets" calls this method:

    public void checkLiquibaseTables(boolean updateExistingNullChecksums, DatabaseChangeLog databaseChangeLog, Contexts contexts) throws LiquibaseException {
        ChangeLogHistoryService changeLogHistoryService = ChangeLogHistoryServiceFactory.getInstance().getChangeLogService(getDatabase());
        changeLogHistoryService.init();
        if (updateExistingNullChecksums) {
            changeLogHistoryService.upgradeChecksums(databaseChangeLog, contexts);
        }
        LockServiceFactory.getInstance().getLockService(getDatabase()).init();
    }

Or differently asked, why does this method includes "creating" a lock? Is there any reason someone needs to create a lock only for "getting" unrun changesets? I mean, i understand that you need to protected "update()" method calls, but why this read-only call?

Marc

Viewing all articles
Browse latest Browse all 2993

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>