From fb29de4f28070099055defff30910744fba126d1 Mon Sep 17 00:00:00 2001 From: Guillaume Smet Date: Tue, 1 Sep 2020 15:53:38 +0200 Subject: [PATCH] Normalize migration paths in Flyway extension Fixes #11780 --- .../src/main/java/io/quarkus/flyway/FlywayProcessor.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/extensions/flyway/deployment/src/main/java/io/quarkus/flyway/FlywayProcessor.java b/extensions/flyway/deployment/src/main/java/io/quarkus/flyway/FlywayProcessor.java index 1344f7e53426a..000729c1541e1 100644 --- a/extensions/flyway/deployment/src/main/java/io/quarkus/flyway/FlywayProcessor.java +++ b/extensions/flyway/deployment/src/main/java/io/quarkus/flyway/FlywayProcessor.java @@ -252,7 +252,7 @@ private Set getApplicationMigrationsFromPath(final String location, fina try (final Stream pathStream = Files.walk(rootPath)) { return pathStream.filter(Files::isRegularFile) - .map(it -> Paths.get(location, rootPath.relativize(it).toString()).toString()) + .map(it -> Paths.get(location, rootPath.relativize(it).toString()).normalize().toString()) // we don't want windows paths here since the paths are going to be used as classpath paths anyway .map(it -> it.replace('\\', '/')) .peek(it -> LOGGER.debugf("Discovered path: %s", it))