From 3a8c4f178ed33ea3816ea5509dc5b781c148648d Mon Sep 17 00:00:00 2001 From: Gleimar Botelho Baleeiro Date: Wed, 8 Nov 2023 18:08:12 -0300 Subject: [PATCH 1/2] =?UTF-8?q?Atualiza=C3=A7=C3=A3o=20do=20log4j?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pom.xml | 30 ++++++++++++++++--- .../rjconsultores/ventaboletos/FlyWay.java | 7 +++-- 2 files changed, 30 insertions(+), 7 deletions(-) diff --git a/pom.xml b/pom.xml index 31aefc906..c95074058 100644 --- a/pom.xml +++ b/pom.xml @@ -4,7 +4,7 @@ 4.0.0 br.com.rjconsultores Flyway - 1.16.0 + 1.17.0 @@ -54,9 +54,31 @@ - log4j - log4j - 1.2.12 + org.apache.logging.log4j + log4j-core + 2.21.1 + + + org.apache.logging.log4j + log4j-api + 2.21.1 + + + org.apache.logging.log4j + log4j-slf4j-impl + 2.21.1 + test + + + org.apache.logging.log4j + log4j-1.2-api + 2.21.1 + test + + + org.apache.logging.log4j + log4j-jcl + 2.21.1 diff --git a/src/com/rjconsultores/ventaboletos/FlyWay.java b/src/com/rjconsultores/ventaboletos/FlyWay.java index 0fb76c145..1d2b34e83 100644 --- a/src/com/rjconsultores/ventaboletos/FlyWay.java +++ b/src/com/rjconsultores/ventaboletos/FlyWay.java @@ -19,14 +19,15 @@ import java.util.Map; import javax.sql.DataSource; -import org.apache.log4j.Logger; +import org.apache.logging.log4j.LogManager; +import org.apache.logging.log4j.Logger; import org.flywaydb.core.Flyway; import org.flywaydb.core.api.callback.FlywayCallback; import com.rjconsultores.ventaboletos.vo.FlyWayCustomDetail; public class FlyWay { - private static Logger log = Logger.getLogger(FlyWay.class); + private static final Logger log = LogManager.getLogger(FlyWay.class); private static final FlyWay INSTANCE = new FlyWay(); @@ -150,7 +151,7 @@ public class FlyWay { try{ String ambiente = System.getProperty("ambiente") ==null || System.getProperty("ambiente").isEmpty() ? "" : System.getProperty("ambiente"); if( (AMBIENTE_DEV.equalsIgnoreCase(ambiente) && AMBIENTE_CONSULTA.equalsIgnoreCase(ambiente)) && Boolean.FALSE.equals(isReloadFlyway) ) { - log.warn("Flyway não executado. Ambiente = dev ou consulta"); + log.warn("Flyway n�o executado. Ambiente = dev ou consulta"); return true; } From d36fd7852bb546154044c4c151c9f1d5d76c0d99 Mon Sep 17 00:00:00 2001 From: Gleimar Botelho Baleeiro Date: Wed, 8 Nov 2023 18:24:21 -0300 Subject: [PATCH 2/2] =?UTF-8?q?Corre=C3=A7=C3=A3o=20acentua=C3=A7=C3=A3o?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/com/rjconsultores/ventaboletos/FlyWay.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/com/rjconsultores/ventaboletos/FlyWay.java b/src/com/rjconsultores/ventaboletos/FlyWay.java index 1d2b34e83..52a47f605 100644 --- a/src/com/rjconsultores/ventaboletos/FlyWay.java +++ b/src/com/rjconsultores/ventaboletos/FlyWay.java @@ -151,7 +151,7 @@ public class FlyWay { try{ String ambiente = System.getProperty("ambiente") ==null || System.getProperty("ambiente").isEmpty() ? "" : System.getProperty("ambiente"); if( (AMBIENTE_DEV.equalsIgnoreCase(ambiente) && AMBIENTE_CONSULTA.equalsIgnoreCase(ambiente)) && Boolean.FALSE.equals(isReloadFlyway) ) { - log.warn("Flyway n�o executado. Ambiente = dev ou consulta"); + log.warn("Flyway não executado. Ambiente = dev ou consulta"); return true; }