You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@iotdb.apache.org by ha...@apache.org on 2024/03/18 08:55:24 UTC
(iotdb) branch fix_ratis_flush_failed created (now fab51f48084)
This is an automated email from the ASF dual-hosted git repository.
haonan pushed a change to branch fix_ratis_flush_failed
in repository https://gitbox.apache.org/repos/asf/iotdb.git
at fab51f48084 Fix flush command failed when dataregion using ratis consensus
This branch includes the following new commits:
new fab51f48084 Fix flush command failed when dataregion using ratis consensus
The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails. The revisions
listed as "add" were already present in the repository and have only
been added to this reference.
(iotdb) 01/01: Fix flush command failed when dataregion using ratis consensus
Posted by ha...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
haonan pushed a commit to branch fix_ratis_flush_failed
in repository https://gitbox.apache.org/repos/asf/iotdb.git
commit fab51f4808417a9bb11379120ce35a770321648e
Author: HTHou <hh...@outlook.com>
AuthorDate: Mon Mar 18 16:55:07 2024 +0800
Fix flush command failed when dataregion using ratis consensus
---
.../main/java/org/apache/iotdb/confignode/conf/ConfigNodeConfig.java | 2 +-
.../org/apache/iotdb/db/storageengine/dataregion/wal/WALManager.java | 3 +++
2 files changed, 4 insertions(+), 1 deletion(-)
diff --git a/iotdb-core/confignode/src/main/java/org/apache/iotdb/confignode/conf/ConfigNodeConfig.java b/iotdb-core/confignode/src/main/java/org/apache/iotdb/confignode/conf/ConfigNodeConfig.java
index 6ed563ec137..993c23498eb 100644
--- a/iotdb-core/confignode/src/main/java/org/apache/iotdb/confignode/conf/ConfigNodeConfig.java
+++ b/iotdb-core/confignode/src/main/java/org/apache/iotdb/confignode/conf/ConfigNodeConfig.java
@@ -66,7 +66,7 @@ public class ConfigNodeConfig {
private int schemaReplicationFactor = 1;
/** Data region consensus protocol. */
- private String dataRegionConsensusProtocolClass = ConsensusFactory.IOT_CONSENSUS;
+ private String dataRegionConsensusProtocolClass = ConsensusFactory.RATIS_CONSENSUS;
/** Default number of DataRegion replicas. */
private int dataReplicationFactor = 1;
diff --git a/iotdb-core/datanode/src/main/java/org/apache/iotdb/db/storageengine/dataregion/wal/WALManager.java b/iotdb-core/datanode/src/main/java/org/apache/iotdb/db/storageengine/dataregion/wal/WALManager.java
index 111de369213..aa4ad28bb57 100644
--- a/iotdb-core/datanode/src/main/java/org/apache/iotdb/db/storageengine/dataregion/wal/WALManager.java
+++ b/iotdb-core/datanode/src/main/java/org/apache/iotdb/db/storageengine/dataregion/wal/WALManager.java
@@ -273,6 +273,9 @@ public class WALManager implements IService {
}
public void syncDeleteOutdatedFilesInWALNodes() {
+ if (config.getWalMode() == WALMode.DISABLE || walDeleteThread == null) {
+ return;
+ }
Future<?> future = walDeleteThread.submit(this::deleteOutdatedFilesInWALNodes);
try {
future.get();