From 4d1f6f6161c2ac055428473264cc92113dd6c46d Mon Sep 17 00:00:00 2001 From: Rob Bygrave Date: Fri, 3 Nov 2023 17:00:05 +1300 Subject: [PATCH] Add split timing for reading resources for fast check mode --- .../main/java/io/ebean/migration/runner/MigrationEngine.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ebean-migration/src/main/java/io/ebean/migration/runner/MigrationEngine.java b/ebean-migration/src/main/java/io/ebean/migration/runner/MigrationEngine.java index 7547dc1..55562aa 100644 --- a/ebean-migration/src/main/java/io/ebean/migration/runner/MigrationEngine.java +++ b/ebean-migration/src/main/java/io/ebean/migration/runner/MigrationEngine.java @@ -44,11 +44,12 @@ public List run(Connection connection) { log.log(DEBUG, "no migrations to check"); return emptyList(); } + long splitMs = System.currentTimeMillis() - startMs; final var platform = derivePlatform(migrationConfig, connection); final var firstCheck = new FirstCheck(migrationConfig, connection, platform); if (fastMode && firstCheck.fastModeCheck(resources.versions())) { long checkMs = System.currentTimeMillis() - startMs; - log.log(INFO, "DB migrations completed in {0}ms - totalMigrations:{1}", checkMs, firstCheck.count()); + log.log(INFO, "DB migrations completed in {0}ms - totalMigrations:{1} readResources:{2}ms", checkMs, firstCheck.count(), splitMs); return emptyList(); } // ensure running with autoCommit false