From ed47eea527d038c934cc26fc3d3873c1429faae8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Deleuze?= Date: Mon, 31 Jul 2023 17:49:16 +0200 Subject: [PATCH] Refine log processing in AwaitApplication This commit removes web server log detection as restart logs are now printed by default. --- .../cr/smoketest/support/junit/AwaitApplication.java | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/cr-smoke-test-support/src/main/java/org/springframework/cr/smoketest/support/junit/AwaitApplication.java b/cr-smoke-test-support/src/main/java/org/springframework/cr/smoketest/support/junit/AwaitApplication.java index cb79f11..1006021 100644 --- a/cr-smoke-test-support/src/main/java/org/springframework/cr/smoketest/support/junit/AwaitApplication.java +++ b/cr-smoke-test-support/src/main/java/org/springframework/cr/smoketest/support/junit/AwaitApplication.java @@ -41,7 +41,6 @@ class AwaitApplication implements BeforeAllCallback { private final Pattern APPLICATION_RE_STARTED = Pattern .compile("Spring-managed lifecycle restart completed in [0-9\\.]+ ms"); - private final Pattern WEB_SERVER_STARTED = Pattern.compile(" started on port"); @Override public void beforeAll(ExtensionContext context) throws Exception { @@ -51,11 +50,7 @@ class AwaitApplication implements BeforeAllCallback { while (System.currentTimeMillis() < end) { lines = output.lines(); for (String line : lines) { - // TODO Either change logging of - // DefaultLifecycleProcessor.CracResourceAdapter.afterRestore to INFO or - // add INFO logging on restore on Spring Boot side - if (this.APPLICATION_STARTED.matcher(line).find() || this.WEB_SERVER_STARTED.matcher(line).find() - || this.APPLICATION_RE_STARTED.matcher(line).find()) { + if (this.APPLICATION_STARTED.matcher(line).find() || this.APPLICATION_RE_STARTED.matcher(line).find()) { return; } }