You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@iotdb.apache.org by ju...@apache.org on 2026/03/30 04:20:22 UTC
(iotdb) branch opc-large-fix updated (3386c4bfeab -> cf1b13c7f1a)
This is an automated email from the ASF dual-hosted git repository.
justinchen pushed a change to branch opc-large-fix
in repository https://gitbox.apache.org/repos/asf/iotdb.git
from 3386c4bfeab fix
new 53ec096b457 partial
add e4fad59a809 Optimize IoTDBRestServiceIT errorInsertRecords (#17371)
new cf1b13c7f1a Merge branch 'master' of https://github.com/apache/iotdb into opc-large-fix
The 2 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.
Summary of changes:
.../org/apache/iotdb/db/it/IoTDBRestServiceIT.java | 133 ++++++++-------------
.../db/pipe/sink/protocol/opcua/OpcUaSink.java | 13 ++
.../iotdb/db/service/ExternalRPCService.java | 4 +
3 files changed, 65 insertions(+), 85 deletions(-)
(iotdb) 01/02: partial
Posted by ju...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
justinchen pushed a commit to branch opc-large-fix
in repository https://gitbox.apache.org/repos/asf/iotdb.git
commit 53ec096b457ac7f3cf266d7679c3d77ccd35b65d
Author: Caideyipi <87...@users.noreply.github.com>
AuthorDate: Mon Mar 30 12:20:06 2026 +0800
partial
---
.../apache/iotdb/db/pipe/sink/protocol/opcua/OpcUaSink.java | 13 +++++++++++++
.../org/apache/iotdb/db/service/ExternalRPCService.java | 4 ++++
2 files changed, 17 insertions(+)
diff --git a/iotdb-core/datanode/src/main/java/org/apache/iotdb/db/pipe/sink/protocol/opcua/OpcUaSink.java b/iotdb-core/datanode/src/main/java/org/apache/iotdb/db/pipe/sink/protocol/opcua/OpcUaSink.java
index ac0c10d287f..91b959b229c 100644
--- a/iotdb-core/datanode/src/main/java/org/apache/iotdb/db/pipe/sink/protocol/opcua/OpcUaSink.java
+++ b/iotdb-core/datanode/src/main/java/org/apache/iotdb/db/pipe/sink/protocol/opcua/OpcUaSink.java
@@ -31,9 +31,13 @@ import org.apache.iotdb.db.pipe.sink.protocol.opcua.client.IoTDBOpcUaClient;
import org.apache.iotdb.db.pipe.sink.protocol.opcua.server.OpcUaNameSpace;
import org.apache.iotdb.db.pipe.sink.protocol.opcua.server.OpcUaServerBuilder;
import org.apache.iotdb.db.pipe.sink.protocol.writeback.WriteBackSink;
+import org.apache.iotdb.db.protocol.session.IClientSession;
import org.apache.iotdb.db.protocol.session.InternalClientSession;
import org.apache.iotdb.db.protocol.session.SessionManager;
+import org.apache.iotdb.db.protocol.thrift.impl.ClientRPCServiceImpl;
+import org.apache.iotdb.db.protocol.thrift.impl.IClientRPCServiceWithHandler;
import org.apache.iotdb.db.queryengine.plan.Coordinator;
+import org.apache.iotdb.db.service.ExternalRPCService;
import org.apache.iotdb.db.storageengine.StorageEngine;
import org.apache.iotdb.db.storageengine.dataregion.DataRegion;
import org.apache.iotdb.pipe.api.PipeConnector;
@@ -47,6 +51,7 @@ import org.apache.iotdb.pipe.api.event.Event;
import org.apache.iotdb.pipe.api.event.dml.insertion.TabletInsertionEvent;
import org.apache.iotdb.pipe.api.exception.PipeException;
+import org.apache.iotdb.service.rpc.thrift.TSLastDataQueryReq;
import org.apache.tsfile.common.conf.TSFileConfig;
import org.apache.tsfile.utils.Pair;
import org.apache.tsfile.write.record.Tablet;
@@ -64,6 +69,7 @@ import javax.annotation.Nullable;
import java.io.File;
import java.time.ZoneId;
import java.util.Arrays;
+import java.util.Collections;
import java.util.Map;
import java.util.Objects;
import java.util.Set;
@@ -387,10 +393,16 @@ public class OpcUaSink implements PipeConnector {
|| Objects.isNull(environment.getSourceParameters())) {
return;
}
+ final IClientRPCServiceWithHandler clientRPCServiceImpl =
+ ExternalRPCService.getInstance().getImpl();
+ if (!(clientRPCServiceImpl instanceof ClientRPCServiceImpl)) {
+ return;
+ }
markInitializing(true);
try {
initializeSession();
+ clientRPCServiceImpl.executeLastDataQueryV2(new TSLastDataQueryReq(session.getId(), Collections.emptyList(), ));
initialized = true;
if (Objects.nonNull(session)) {
@@ -427,6 +439,7 @@ public class OpcUaSink implements PipeConnector {
session.setClientVersion(IoTDBConstant.ClientVersion.V_1_0);
session.setZoneId(ZoneId.systemDefault());
session.setUsername(usernameString);
+ session.setSqlDialect(IClientSession.SqlDialect.TREE);
}
if (SESSION_MANAGER.getCurrSession() == null) {
diff --git a/iotdb-core/datanode/src/main/java/org/apache/iotdb/db/service/ExternalRPCService.java b/iotdb-core/datanode/src/main/java/org/apache/iotdb/db/service/ExternalRPCService.java
index dcc8690de8a..b4d576874e0 100644
--- a/iotdb-core/datanode/src/main/java/org/apache/iotdb/db/service/ExternalRPCService.java
+++ b/iotdb-core/datanode/src/main/java/org/apache/iotdb/db/service/ExternalRPCService.java
@@ -118,6 +118,10 @@ public class ExternalRPCService extends ThriftService implements ExternalRPCServ
return getBindPort();
}
+ public IClientRPCServiceWithHandler getImpl() {
+ return impl;
+ }
+
private static class RPCServiceHolder {
private static final ExternalRPCService INSTANCE = new ExternalRPCService();
(iotdb) 02/02: Merge branch 'master' of https://github.com/apache/iotdb into opc-large-fix
Posted by ju...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
justinchen pushed a commit to branch opc-large-fix
in repository https://gitbox.apache.org/repos/asf/iotdb.git
commit cf1b13c7f1a75386c75389c75d17e247a0054e49
Merge: 53ec096b457 e4fad59a809
Author: Caideyipi <87...@users.noreply.github.com>
AuthorDate: Mon Mar 30 12:20:11 2026 +0800
Merge branch 'master' of https://github.com/apache/iotdb into opc-large-fix
.../org/apache/iotdb/db/it/IoTDBRestServiceIT.java | 133 ++++++++-------------
1 file changed, 48 insertions(+), 85 deletions(-)