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 d5450a1e564 [IOTDB-6134] Fill statement content in show queries for
inner schema fetch
d5450a1e564 is described below
commit d5450a1e5648699409e1c793035204989d78cfbb
Author: Jackie Tien <[email protected]>
AuthorDate: Thu Aug 31 19:43:29 2023 +0800
[IOTDB-6134] Fill statement content in show queries for inner schema fetch
---
.../plan/analyze/schema/ClusterSchemaFetchExecutor.java | 14 +++++++++-----
1 file changed, 9 insertions(+), 5 deletions(-)
diff --git
a/iotdb-core/datanode/src/main/java/org/apache/iotdb/db/queryengine/plan/analyze/schema/ClusterSchemaFetchExecutor.java
b/iotdb-core/datanode/src/main/java/org/apache/iotdb/db/queryengine/plan/analyze/schema/ClusterSchemaFetchExecutor.java
index 01d4380f306..3bb32279e0a 100644
---
a/iotdb-core/datanode/src/main/java/org/apache/iotdb/db/queryengine/plan/analyze/schema/ClusterSchemaFetchExecutor.java
+++
b/iotdb-core/datanode/src/main/java/org/apache/iotdb/db/queryengine/plan/analyze/schema/ClusterSchemaFetchExecutor.java
@@ -74,17 +74,21 @@ class ClusterSchemaFetchExecutor {
}
private ExecutionResult executionStatement(
- Long queryId, Statement statement, MPPQueryContext context) {
+ long queryId, Statement statement, MPPQueryContext context) {
+
+ long timeout = context == null ? config.getQueryTimeoutThreshold() :
context.getTimeOut();
+ String sql = context == null ? "" : "Fetch Schema for " +
context.getQueryType();
+ if (context != null && context.getQueryType() == QueryType.READ) {
+ sql += ", " + context.getQueryId() + " : " + context.getSql();
+ }
return coordinator.execute(
statement,
queryId,
context == null ? null : context.getSession(),
- "",
+ sql,
ClusterPartitionFetcher.getInstance(),
schemaFetcher,
- context == null || context.getQueryType().equals(QueryType.WRITE)
- ? config.getQueryTimeoutThreshold()
- : context.getTimeOut());
+ timeout);
}
/**