You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@iotdb.apache.org by ja...@apache.org on 2024/10/20 06:12:05 UTC
(iotdb) branch master updated: Update GeneralRegionAttributeSecurityService.java
This is an automated email from the ASF dual-hosted git repository.
jackietien pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/iotdb.git
The following commit(s) were added to refs/heads/master by this push:
new daf178ed3e7 Update GeneralRegionAttributeSecurityService.java
daf178ed3e7 is described below
commit daf178ed3e72cbfd6e0fa1ac732c961dd059d4a0
Author: Caideyipi <87...@users.noreply.github.com>
AuthorDate: Sun Oct 20 14:12:00 2024 +0800
Update GeneralRegionAttributeSecurityService.java
---
.../attribute/update/GeneralRegionAttributeSecurityService.java | 9 ++++++---
1 file changed, 6 insertions(+), 3 deletions(-)
diff --git a/iotdb-core/datanode/src/main/java/org/apache/iotdb/db/schemaengine/schemaregion/attribute/update/GeneralRegionAttributeSecurityService.java b/iotdb-core/datanode/src/main/java/org/apache/iotdb/db/schemaengine/schemaregion/attribute/update/GeneralRegionAttributeSecurityService.java
index 07f075a7dd1..58dbb0142f8 100644
--- a/iotdb-core/datanode/src/main/java/org/apache/iotdb/db/schemaengine/schemaregion/attribute/update/GeneralRegionAttributeSecurityService.java
+++ b/iotdb-core/datanode/src/main/java/org/apache/iotdb/db/schemaengine/schemaregion/attribute/update/GeneralRegionAttributeSecurityService.java
@@ -43,6 +43,7 @@ import org.apache.iotdb.db.queryengine.execution.executor.RegionWriteExecutor;
import org.apache.iotdb.db.queryengine.plan.planner.plan.node.PlanNodeId;
import org.apache.iotdb.db.queryengine.plan.relational.planner.node.schema.TableDeviceAttributeCommitUpdateNode;
import org.apache.iotdb.db.schemaengine.schemaregion.ISchemaRegion;
+import org.apache.iotdb.db.schemaengine.schemaregion.impl.SchemaRegionMemoryImpl;
import org.apache.iotdb.mpp.rpc.thrift.TAttributeUpdateReq;
import org.apache.iotdb.mpp.rpc.thrift.TSchemaRegionAttributeInfo;
import org.apache.iotdb.rpc.TSStatusCode;
@@ -92,9 +93,11 @@ public class GeneralRegionAttributeSecurityService implements IService {
private volatile boolean allowSubmitListen = false;
public void startBroadcast(final ISchemaRegion schemaRegion) {
- regionLeaders.add(schemaRegion);
- regionId2DatabaseMap.put(
- schemaRegion.getSchemaRegionId(), schemaRegion.getDatabaseFullPath().substring(5));
+ if (schemaRegion instanceof SchemaRegionMemoryImpl) {
+ regionLeaders.add(schemaRegion);
+ regionId2DatabaseMap.put(
+ schemaRegion.getSchemaRegionId(), schemaRegion.getDatabaseFullPath().substring(5));
+ }
}
public void stopBroadcast(final ISchemaRegion schemaRegion) {