From 187f17c216dccfbe0b487558f6a5ef8a0d2e37d6 Mon Sep 17 00:00:00 2001 From: Wei Zhou Date: Tue, 13 Feb 2024 11:07:59 +0100 Subject: [PATCH] fix build errors with DRS plugins after merge-forward --- .../main/java/org/apache/cloudstack/cluster/Balanced.java | 5 +++-- .../main/java/org/apache/cloudstack/cluster/Condensed.java | 5 +++-- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/plugins/drs/cluster/balanced/src/main/java/org/apache/cloudstack/cluster/Balanced.java b/plugins/drs/cluster/balanced/src/main/java/org/apache/cloudstack/cluster/Balanced.java index ea234c2b794e..c799ac872c00 100644 --- a/plugins/drs/cluster/balanced/src/main/java/org/apache/cloudstack/cluster/Balanced.java +++ b/plugins/drs/cluster/balanced/src/main/java/org/apache/cloudstack/cluster/Balanced.java @@ -24,7 +24,8 @@ import com.cloud.utils.Ternary; import com.cloud.utils.component.AdapterBase; import com.cloud.vm.VirtualMachine; -import org.apache.log4j.Logger; +import org.apache.logging.log4j.LogManager; +import org.apache.logging.log4j.Logger; import javax.naming.ConfigurationException; import java.util.ArrayList; @@ -35,7 +36,7 @@ public class Balanced extends AdapterBase implements ClusterDrsAlgorithm { - private static final Logger logger = Logger.getLogger(Balanced.class); + private static final Logger logger = LogManager.getLogger(Balanced.class); @Override public boolean needsDrs(long clusterId, List> cpuList, diff --git a/plugins/drs/cluster/condensed/src/main/java/org/apache/cloudstack/cluster/Condensed.java b/plugins/drs/cluster/condensed/src/main/java/org/apache/cloudstack/cluster/Condensed.java index dc1546f9f6af..3a8befa628b1 100644 --- a/plugins/drs/cluster/condensed/src/main/java/org/apache/cloudstack/cluster/Condensed.java +++ b/plugins/drs/cluster/condensed/src/main/java/org/apache/cloudstack/cluster/Condensed.java @@ -24,7 +24,8 @@ import com.cloud.utils.Ternary; import com.cloud.utils.component.AdapterBase; import com.cloud.vm.VirtualMachine; -import org.apache.log4j.Logger; +import org.apache.logging.log4j.LogManager; +import org.apache.logging.log4j.Logger; import javax.naming.ConfigurationException; import java.util.ArrayList; @@ -36,7 +37,7 @@ public class Condensed extends AdapterBase implements ClusterDrsAlgorithm { - private static final Logger logger = Logger.getLogger(Condensed.class); + private static final Logger logger = LogManager.getLogger(Condensed.class); @Override public boolean needsDrs(long clusterId, List> cpuList,