This is an automated email from the ASF dual-hosted git repository.

tanxinyu pushed a commit to branch dev/1.3
in repository https://gitbox.apache.org/repos/asf/iotdb.git


The following commit(s) were added to refs/heads/dev/1.3 by this push:
     new 820ed079bc7 [to dev/1.3] Fix IT names & Fix region operation related 
IT (#14925)
820ed079bc7 is described below

commit 820ed079bc79f237ac3cf1ca7c7f096840c0c93d
Author: Li Yu Heng <[email protected]>
AuthorDate: Sat Feb 22 23:17:12 2025 +0800

    [to dev/1.3] Fix IT names & Fix region operation related IT (#14925)
    
    * try
    
    * revert
---
 .../{AbstractScript.java => AbstractScriptIT.java} |  2 +-
 .../apache/iotdb/cli/it/StartClientScriptIT.java   |  2 +-
 ....java => IoTDBAutoRegionGroupExtension2IT.java} |  4 ++--
 ...st.java => IoTDBPartitionTableAutoCleanIT.java} |  2 +-
 .../IoTDBRegionGroupExpandAndShrinkForIoTV1IT.java | 20 ++++++++++++++++++--
 .../apache/iotdb/tools/it/ExportDataTestIT.java    |  4 ++--
 .../apache/iotdb/tools/it/ExportSchemaTestIT.java  |  4 ++--
 .../apache/iotdb/tools/it/ExportTsFileTestIT.java  |  4 ++--
 .../apache/iotdb/tools/it/ImportDataTestIT.java    |  4 ++--
 .../apache/iotdb/tools/it/ImportSchemaTestIT.java  |  4 ++--
 .../src/test/resources/logback-test.xml            |  2 +-
 .../db/protocol/rest/impl/PingApiServiceImpl.java  |  4 ++--
 .../java/org/apache/iotdb/db/service/DataNode.java |  2 +-
 .../iotdb/db/service/DataNodeShutdownHook.java     | 22 ++++++++++------------
 .../{RPCService.java => ExternalRPCService.java}   |  6 +++---
 .../db/protocol/rest/IoTDBRestServiceTest.java     |  6 +++---
 .../datanode/src/test/resources/logback-test.xml   |  2 +-
 17 files changed, 54 insertions(+), 40 deletions(-)

diff --git 
a/integration-test/src/test/java/org/apache/iotdb/cli/it/AbstractScript.java 
b/integration-test/src/test/java/org/apache/iotdb/cli/it/AbstractScriptIT.java
similarity index 98%
rename from 
integration-test/src/test/java/org/apache/iotdb/cli/it/AbstractScript.java
rename to 
integration-test/src/test/java/org/apache/iotdb/cli/it/AbstractScriptIT.java
index 53f51cb81a6..a0a25a2e12e 100644
--- a/integration-test/src/test/java/org/apache/iotdb/cli/it/AbstractScript.java
+++ 
b/integration-test/src/test/java/org/apache/iotdb/cli/it/AbstractScriptIT.java
@@ -34,7 +34,7 @@ import static org.junit.Assert.assertTrue;
 import static org.junit.Assert.fail;
 
 @RunWith(IoTDBTestRunner.class)
-public abstract class AbstractScript {
+public abstract class AbstractScriptIT {
 
   protected void testOutput(ProcessBuilder builder, @Nullable String[] output, 
int statusCode)
       throws IOException {
diff --git 
a/integration-test/src/test/java/org/apache/iotdb/cli/it/StartClientScriptIT.java
 
b/integration-test/src/test/java/org/apache/iotdb/cli/it/StartClientScriptIT.java
index 18973720b3e..0385071e2ad 100644
--- 
a/integration-test/src/test/java/org/apache/iotdb/cli/it/StartClientScriptIT.java
+++ 
b/integration-test/src/test/java/org/apache/iotdb/cli/it/StartClientScriptIT.java
@@ -35,7 +35,7 @@ import java.io.IOException;
 
 @RunWith(IoTDBTestRunner.class)
 @Category({LocalStandaloneIT.class, ClusterIT.class})
-public class StartClientScriptIT extends AbstractScript {
+public class StartClientScriptIT extends AbstractScriptIT {
 
   private static String ip;
 
diff --git 
a/integration-test/src/test/java/org/apache/iotdb/confignode/it/partition/IoTDBAutoRegionGroupExtensionIT2.java
 
b/integration-test/src/test/java/org/apache/iotdb/confignode/it/partition/IoTDBAutoRegionGroupExtension2IT.java
similarity index 98%
rename from 
integration-test/src/test/java/org/apache/iotdb/confignode/it/partition/IoTDBAutoRegionGroupExtensionIT2.java
rename to 
integration-test/src/test/java/org/apache/iotdb/confignode/it/partition/IoTDBAutoRegionGroupExtension2IT.java
index f091bafd542..5d00ef023eb 100644
--- 
a/integration-test/src/test/java/org/apache/iotdb/confignode/it/partition/IoTDBAutoRegionGroupExtensionIT2.java
+++ 
b/integration-test/src/test/java/org/apache/iotdb/confignode/it/partition/IoTDBAutoRegionGroupExtension2IT.java
@@ -56,10 +56,10 @@ import java.util.concurrent.atomic.AtomicInteger;
 
 @RunWith(IoTDBTestRunner.class)
 @Category({ClusterIT.class})
-public class IoTDBAutoRegionGroupExtensionIT2 {
+public class IoTDBAutoRegionGroupExtension2IT {
 
   private static final Logger LOGGER =
-      LoggerFactory.getLogger(IoTDBAutoRegionGroupExtensionIT2.class);
+      LoggerFactory.getLogger(IoTDBAutoRegionGroupExtension2IT.class);
 
   private static final String testDataRegionGroupExtensionPolicy = "AUTO";
   private static final String testConsensusProtocolClass = 
ConsensusFactory.IOT_CONSENSUS;
diff --git 
a/integration-test/src/test/java/org/apache/iotdb/confignode/it/partition/IoTDBPartitionTableAutoCleanTest.java
 
b/integration-test/src/test/java/org/apache/iotdb/confignode/it/partition/IoTDBPartitionTableAutoCleanIT.java
similarity index 99%
rename from 
integration-test/src/test/java/org/apache/iotdb/confignode/it/partition/IoTDBPartitionTableAutoCleanTest.java
rename to 
integration-test/src/test/java/org/apache/iotdb/confignode/it/partition/IoTDBPartitionTableAutoCleanIT.java
index a958cb9b48c..6cad5508316 100644
--- 
a/integration-test/src/test/java/org/apache/iotdb/confignode/it/partition/IoTDBPartitionTableAutoCleanTest.java
+++ 
b/integration-test/src/test/java/org/apache/iotdb/confignode/it/partition/IoTDBPartitionTableAutoCleanIT.java
@@ -43,7 +43,7 @@ import java.util.concurrent.TimeUnit;
 
 @RunWith(IoTDBTestRunner.class)
 @Category({ClusterIT.class})
-public class IoTDBPartitionTableAutoCleanTest {
+public class IoTDBPartitionTableAutoCleanIT {
 
   private static final int TEST_REPLICATION_FACTOR = 1;
   private static final long TEST_TIME_PARTITION_INTERVAL = 604800000;
diff --git 
a/integration-test/src/test/java/org/apache/iotdb/confignode/it/regionmigration/pass/commit/IoTDBRegionGroupExpandAndShrinkForIoTV1IT.java
 
b/integration-test/src/test/java/org/apache/iotdb/confignode/it/regionmigration/pass/commit/IoTDBRegionGroupExpandAndShrinkForIoTV1IT.java
index 7897fded074..3c4aa16a401 100644
--- 
a/integration-test/src/test/java/org/apache/iotdb/confignode/it/regionmigration/pass/commit/IoTDBRegionGroupExpandAndShrinkForIoTV1IT.java
+++ 
b/integration-test/src/test/java/org/apache/iotdb/confignode/it/regionmigration/pass/commit/IoTDBRegionGroupExpandAndShrinkForIoTV1IT.java
@@ -27,6 +27,7 @@ import org.apache.iotdb.it.env.EnvFactory;
 import org.apache.iotdb.it.framework.IoTDBTestRunner;
 import org.apache.iotdb.itbase.category.ClusterIT;
 
+import org.awaitility.Awaitility;
 import org.junit.Assert;
 import org.junit.Test;
 import org.junit.experimental.categories.Category;
@@ -39,6 +40,7 @@ import java.sql.Statement;
 import java.util.Map;
 import java.util.Optional;
 import java.util.Set;
+import java.util.concurrent.TimeUnit;
 import java.util.function.Predicate;
 
 import static org.apache.iotdb.util.MagicUtils.makeItCloseQuietly;
@@ -119,7 +121,14 @@ public class IoTDBRegionGroupExpandAndShrinkForIoTV1IT
       int selectedRegion,
       int targetDataNode)
       throws Exception {
-    statement.execute(String.format(EXPAND_FORMAT, selectedRegion, 
targetDataNode));
+    Awaitility.await()
+        .atMost(10, TimeUnit.SECONDS)
+        .pollInterval(1, TimeUnit.SECONDS)
+        .until(
+            () -> {
+              statement.execute(String.format(EXPAND_FORMAT, selectedRegion, 
targetDataNode));
+              return true;
+            });
 
     Predicate<TShowRegionResp> expandRegionPredicate =
         tShowRegionResp -> {
@@ -140,7 +149,14 @@ public class IoTDBRegionGroupExpandAndShrinkForIoTV1IT
       int selectedRegion,
       int targetDataNode)
       throws Exception {
-    statement.execute(String.format(SHRINK_FORMAT, selectedRegion, 
targetDataNode));
+    Awaitility.await()
+        .atMost(10, TimeUnit.SECONDS)
+        .pollInterval(1, TimeUnit.SECONDS)
+        .until(
+            () -> {
+              statement.execute(String.format(SHRINK_FORMAT, selectedRegion, 
targetDataNode));
+              return true;
+            });
 
     Predicate<TShowRegionResp> shrinkRegionPredicate =
         tShowRegionResp -> {
diff --git 
a/integration-test/src/test/java/org/apache/iotdb/tools/it/ExportDataTestIT.java
 
b/integration-test/src/test/java/org/apache/iotdb/tools/it/ExportDataTestIT.java
index f323c5e6485..f082391769d 100644
--- 
a/integration-test/src/test/java/org/apache/iotdb/tools/it/ExportDataTestIT.java
+++ 
b/integration-test/src/test/java/org/apache/iotdb/tools/it/ExportDataTestIT.java
@@ -18,7 +18,7 @@
  */
 package org.apache.iotdb.tools.it;
 
-import org.apache.iotdb.cli.it.AbstractScript;
+import org.apache.iotdb.cli.it.AbstractScriptIT;
 import org.apache.iotdb.isession.ISession;
 import org.apache.iotdb.it.env.EnvFactory;
 import org.apache.iotdb.it.framework.IoTDBTestRunner;
@@ -40,7 +40,7 @@ import java.util.List;
 
 @RunWith(IoTDBTestRunner.class)
 @Category({LocalStandaloneIT.class, ClusterIT.class})
-public class ExportDataTestIT extends AbstractScript {
+public class ExportDataTestIT extends AbstractScriptIT {
   private static String ip;
 
   private static String port;
diff --git 
a/integration-test/src/test/java/org/apache/iotdb/tools/it/ExportSchemaTestIT.java
 
b/integration-test/src/test/java/org/apache/iotdb/tools/it/ExportSchemaTestIT.java
index f8a4cdae171..cc520b5e809 100644
--- 
a/integration-test/src/test/java/org/apache/iotdb/tools/it/ExportSchemaTestIT.java
+++ 
b/integration-test/src/test/java/org/apache/iotdb/tools/it/ExportSchemaTestIT.java
@@ -18,7 +18,7 @@
  */
 package org.apache.iotdb.tools.it;
 
-import org.apache.iotdb.cli.it.AbstractScript;
+import org.apache.iotdb.cli.it.AbstractScriptIT;
 import org.apache.iotdb.isession.ISession;
 import org.apache.iotdb.it.env.EnvFactory;
 import org.apache.iotdb.it.framework.IoTDBTestRunner;
@@ -41,7 +41,7 @@ import java.io.IOException;
 
 @RunWith(IoTDBTestRunner.class)
 @Category({LocalStandaloneIT.class, ClusterIT.class})
-public class ExportSchemaTestIT extends AbstractScript {
+public class ExportSchemaTestIT extends AbstractScriptIT {
   private static String ip;
 
   private static String port;
diff --git 
a/integration-test/src/test/java/org/apache/iotdb/tools/it/ExportTsFileTestIT.java
 
b/integration-test/src/test/java/org/apache/iotdb/tools/it/ExportTsFileTestIT.java
index 7701bb1f973..57b76e55e81 100644
--- 
a/integration-test/src/test/java/org/apache/iotdb/tools/it/ExportTsFileTestIT.java
+++ 
b/integration-test/src/test/java/org/apache/iotdb/tools/it/ExportTsFileTestIT.java
@@ -19,7 +19,7 @@
 
 package org.apache.iotdb.tools.it;
 
-import org.apache.iotdb.cli.it.AbstractScript;
+import org.apache.iotdb.cli.it.AbstractScriptIT;
 import org.apache.iotdb.isession.ISession;
 import org.apache.iotdb.it.env.EnvFactory;
 import org.apache.iotdb.it.framework.IoTDBTestRunner;
@@ -41,7 +41,7 @@ import java.util.List;
 
 @RunWith(IoTDBTestRunner.class)
 @Category({LocalStandaloneIT.class, ClusterIT.class})
-public class ExportTsFileTestIT extends AbstractScript {
+public class ExportTsFileTestIT extends AbstractScriptIT {
   private static String ip;
 
   private static String port;
diff --git 
a/integration-test/src/test/java/org/apache/iotdb/tools/it/ImportDataTestIT.java
 
b/integration-test/src/test/java/org/apache/iotdb/tools/it/ImportDataTestIT.java
index 38c83a83375..d2f7c95aacd 100644
--- 
a/integration-test/src/test/java/org/apache/iotdb/tools/it/ImportDataTestIT.java
+++ 
b/integration-test/src/test/java/org/apache/iotdb/tools/it/ImportDataTestIT.java
@@ -19,7 +19,7 @@
 
 package org.apache.iotdb.tools.it;
 
-import org.apache.iotdb.cli.it.AbstractScript;
+import org.apache.iotdb.cli.it.AbstractScriptIT;
 import org.apache.iotdb.it.env.EnvFactory;
 import org.apache.iotdb.it.framework.IoTDBTestRunner;
 import org.apache.iotdb.itbase.category.ClusterIT;
@@ -36,7 +36,7 @@ import java.io.IOException;
 
 @RunWith(IoTDBTestRunner.class)
 @Category({LocalStandaloneIT.class, ClusterIT.class})
-public class ImportDataTestIT extends AbstractScript {
+public class ImportDataTestIT extends AbstractScriptIT {
 
   private static String ip;
 
diff --git 
a/integration-test/src/test/java/org/apache/iotdb/tools/it/ImportSchemaTestIT.java
 
b/integration-test/src/test/java/org/apache/iotdb/tools/it/ImportSchemaTestIT.java
index ea7e1ba07f1..06eb3f4eb34 100644
--- 
a/integration-test/src/test/java/org/apache/iotdb/tools/it/ImportSchemaTestIT.java
+++ 
b/integration-test/src/test/java/org/apache/iotdb/tools/it/ImportSchemaTestIT.java
@@ -19,7 +19,7 @@
 
 package org.apache.iotdb.tools.it;
 
-import org.apache.iotdb.cli.it.AbstractScript;
+import org.apache.iotdb.cli.it.AbstractScriptIT;
 import org.apache.iotdb.it.env.EnvFactory;
 import org.apache.iotdb.it.framework.IoTDBTestRunner;
 import org.apache.iotdb.itbase.category.ClusterIT;
@@ -36,7 +36,7 @@ import java.io.IOException;
 
 @RunWith(IoTDBTestRunner.class)
 @Category({LocalStandaloneIT.class, ClusterIT.class})
-public class ImportSchemaTestIT extends AbstractScript {
+public class ImportSchemaTestIT extends AbstractScriptIT {
 
   private static String ip;
 
diff --git a/integration-test/src/test/resources/logback-test.xml 
b/integration-test/src/test/resources/logback-test.xml
index 95a4d1c5c9c..ba595ff9752 100644
--- a/integration-test/src/test/resources/logback-test.xml
+++ b/integration-test/src/test/resources/logback-test.xml
@@ -49,7 +49,7 @@
     <logger name="org.apache.iotdb.db.integration.IoTDBCompactionIT" 
level="INFO"/>
     <logger name="org.apache.iotdb.commons.service.RegisterManager" 
level="INFO"/>
     <logger name="org.apache.iotdb.db.service.DataNode" level="WARN"/>
-    <logger name="org.apache.iotdb.db.service.RPCService" level="INFO"/>
+    <logger name="org.apache.iotdb.db.service.ExternalRPCService" 
level="INFO"/>
     <logger name="org.apache.iotdb.db.service.MQTTService" level="INFO"/>
     <logger name="org.apache.iotdb.db.conf.IoTDBDescriptor" level="WARN"/>
     <logger name="org.apache.tsfile.common.conf.TSFileDescriptor" 
level="WARN"/>
diff --git 
a/iotdb-core/datanode/src/main/java/org/apache/iotdb/db/protocol/rest/impl/PingApiServiceImpl.java
 
b/iotdb-core/datanode/src/main/java/org/apache/iotdb/db/protocol/rest/impl/PingApiServiceImpl.java
index d16988e4312..f85de024b47 100644
--- 
a/iotdb-core/datanode/src/main/java/org/apache/iotdb/db/protocol/rest/impl/PingApiServiceImpl.java
+++ 
b/iotdb-core/datanode/src/main/java/org/apache/iotdb/db/protocol/rest/impl/PingApiServiceImpl.java
@@ -20,7 +20,7 @@ package org.apache.iotdb.db.protocol.rest.impl;
 import org.apache.iotdb.commons.service.ThriftService;
 import org.apache.iotdb.db.protocol.rest.PingApiService;
 import org.apache.iotdb.db.protocol.rest.model.ExecutionStatus;
-import org.apache.iotdb.db.service.RPCService;
+import org.apache.iotdb.db.service.ExternalRPCService;
 import org.apache.iotdb.rpc.TSStatusCode;
 
 import javax.ws.rs.core.Response;
@@ -32,7 +32,7 @@ public class PingApiServiceImpl extends PingApiService {
 
   @Override
   public Response tryPing(SecurityContext securityContext) {
-    if 
(RPCService.getInstance().getRPCServiceStatus().equals(ThriftService.STATUS_DOWN))
 {
+    if 
(ExternalRPCService.getInstance().getRPCServiceStatus().equals(ThriftService.STATUS_DOWN))
 {
       return Response.status(Response.Status.SERVICE_UNAVAILABLE)
           .entity(
               new ExecutionStatus()
diff --git 
a/iotdb-core/datanode/src/main/java/org/apache/iotdb/db/service/DataNode.java 
b/iotdb-core/datanode/src/main/java/org/apache/iotdb/db/service/DataNode.java
index 7ba42f6f5b7..d5c59907362 100644
--- 
a/iotdb-core/datanode/src/main/java/org/apache/iotdb/db/service/DataNode.java
+++ 
b/iotdb-core/datanode/src/main/java/org/apache/iotdb/db/service/DataNode.java
@@ -834,7 +834,7 @@ public class DataNode extends ServerCommandLine implements 
DataNodeMBean {
         .getConfig()
         .setRpcImplClassName(ClientRPCServiceImpl.class.getName());
     if (config.isEnableRpcService()) {
-      registerManager.register(RPCService.getInstance());
+      registerManager.register(ExternalRPCService.getInstance());
     }
     // init service protocols
     initProtocols();
diff --git 
a/iotdb-core/datanode/src/main/java/org/apache/iotdb/db/service/DataNodeShutdownHook.java
 
b/iotdb-core/datanode/src/main/java/org/apache/iotdb/db/service/DataNodeShutdownHook.java
index 96eda557489..28940c48138 100644
--- 
a/iotdb-core/datanode/src/main/java/org/apache/iotdb/db/service/DataNodeShutdownHook.java
+++ 
b/iotdb-core/datanode/src/main/java/org/apache/iotdb/db/service/DataNodeShutdownHook.java
@@ -56,7 +56,7 @@ public class DataNodeShutdownHook extends Thread {
   public void run() {
     logger.info("DataNode exiting...");
     // Stop external rpc service firstly.
-    RPCService.getInstance().stop();
+    ExternalRPCService.getInstance().stop();
 
     // Reject write operations to make sure all tsfiles will be sealed
     CommonDescriptor.getInstance().getConfig().setStopping(true);
@@ -85,26 +85,24 @@ public class DataNodeShutdownHook extends Thread {
       triggerSnapshotForAllDataRegion();
     }
 
+    // Actually stop all services started by the DataNode.
+    // If we don't call this, services like the RestService are not stopped 
and I can't re-start
+    // it.
+    DataNode.getInstance().stop();
+
     // Set and report shutdown to cluster ConfigNode-leader
     if (!reportShutdownToConfigNodeLeader()) {
       logger.warn(
           "Failed to report DataNode's shutdown to ConfigNode. The cluster 
will still take the current DataNode as Running for a few seconds.");
     }
 
-    // Actually stop all services started by the DataNode.
-    // If we don't call this, services like the RestService are not stopped 
and I can't re-start
-    // it.
-    DataNode.getInstance().stop();
-
     // Clear lock file. All services should be shutdown before this line.
     DirectoryChecker.getInstance().deregisterAll();
 
-    if (logger.isInfoEnabled()) {
-      logger.info(
-          "DataNode exits. Jvm memory usage: {}",
-          MemUtils.bytesCntToStr(
-              Runtime.getRuntime().totalMemory() - 
Runtime.getRuntime().freeMemory()));
-    }
+    logger.info(
+        "DataNode exits. Jvm memory usage: {}",
+        MemUtils.bytesCntToStr(
+            Runtime.getRuntime().totalMemory() - 
Runtime.getRuntime().freeMemory()));
   }
 
   private void triggerSnapshotForAllDataRegion() {
diff --git 
a/iotdb-core/datanode/src/main/java/org/apache/iotdb/db/service/RPCService.java 
b/iotdb-core/datanode/src/main/java/org/apache/iotdb/db/service/ExternalRPCService.java
similarity index 95%
rename from 
iotdb-core/datanode/src/main/java/org/apache/iotdb/db/service/RPCService.java
rename to 
iotdb-core/datanode/src/main/java/org/apache/iotdb/db/service/ExternalRPCService.java
index 3a032263732..1ad0bcb61d9 100644
--- 
a/iotdb-core/datanode/src/main/java/org/apache/iotdb/db/service/RPCService.java
+++ 
b/iotdb-core/datanode/src/main/java/org/apache/iotdb/db/service/ExternalRPCService.java
@@ -35,11 +35,11 @@ import org.apache.iotdb.rpc.ZeroCopyRpcTransportFactory;
 import java.lang.reflect.InvocationTargetException;
 
 /** A service to handle RPC request from client. */
-public class RPCService extends ThriftService implements RPCServiceMBean {
+public class ExternalRPCService extends ThriftService implements 
RPCServiceMBean {
 
   private IClientRPCServiceWithHandler impl;
 
-  public static RPCService getInstance() {
+  public static ExternalRPCService getInstance() {
     return RPCServiceHolder.INSTANCE;
   }
 
@@ -122,7 +122,7 @@ public class RPCService extends ThriftService implements 
RPCServiceMBean {
 
   private static class RPCServiceHolder {
 
-    private static final RPCService INSTANCE = new RPCService();
+    private static final ExternalRPCService INSTANCE = new 
ExternalRPCService();
 
     private RPCServiceHolder() {}
   }
diff --git 
a/iotdb-core/datanode/src/test/java/org/apache/iotdb/db/protocol/rest/IoTDBRestServiceTest.java
 
b/iotdb-core/datanode/src/test/java/org/apache/iotdb/db/protocol/rest/IoTDBRestServiceTest.java
index e87bfa58335..4c15d3635ac 100644
--- 
a/iotdb-core/datanode/src/test/java/org/apache/iotdb/db/protocol/rest/IoTDBRestServiceTest.java
+++ 
b/iotdb-core/datanode/src/test/java/org/apache/iotdb/db/protocol/rest/IoTDBRestServiceTest.java
@@ -19,7 +19,7 @@
 package org.apache.iotdb.db.protocol.rest;
 
 import org.apache.iotdb.commons.exception.StartupException;
-import org.apache.iotdb.db.service.RPCService;
+import org.apache.iotdb.db.service.ExternalRPCService;
 import org.apache.iotdb.db.utils.EnvironmentUtils;
 
 import com.fasterxml.jackson.databind.ObjectMapper;
@@ -86,14 +86,14 @@ public class IoTDBRestServiceTest {
       assertEquals(200, Integer.parseInt(result.get("code").toString()));
 
       // Shutdown RPCService to test
-      RPCService.getInstance().stop();
+      ExternalRPCService.getInstance().stop();
       response = httpClient.execute(httpGet);
       responseEntity = response.getEntity();
       message = EntityUtils.toString(responseEntity, "utf-8");
       result = JsonParser.parseString(message).getAsJsonObject();
       assertEquals(503, response.getStatusLine().getStatusCode());
       assertEquals(500, Integer.parseInt(result.get("code").toString()));
-      RPCService.getInstance().start();
+      ExternalRPCService.getInstance().start();
 
     } catch (IOException | StartupException e) {
       e.printStackTrace();
diff --git a/iotdb-core/datanode/src/test/resources/logback-test.xml 
b/iotdb-core/datanode/src/test/resources/logback-test.xml
index 6dd4a262e61..f6c690d6ff7 100644
--- a/iotdb-core/datanode/src/test/resources/logback-test.xml
+++ b/iotdb-core/datanode/src/test/resources/logback-test.xml
@@ -53,7 +53,7 @@
     <logger name="org.apache.iotdb.db.queryengine.common.schematree" 
level="INFO"/>
     <logger name="org.apache.iotdb.commons.service.RegisterManager" 
level="INFO"/>
     <logger name="org.apache.iotdb.db.service.DataNode" level="WARN"/>
-    <logger name="org.apache.iotdb.db.service.RPCService" level="INFO"/>
+    <logger name="org.apache.iotdb.db.service.ExternalRPCService" 
level="INFO"/>
     <logger name="org.apache.iotdb.db.service.MQTTService" level="INFO"/>
     <logger 
name="org.apache.iotdb.db.storageengine.compaction.cross.rewrite.task" 
level="ERROR"/>
     <logger name="io.moquette.broker.metrics.MQTTMessageLogger" level="ERROR"/>

Reply via email to