You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@iotdb.apache.org by GitBox <gi...@apache.org> on 2022/09/02 07:50:35 UTC

[GitHub] [iotdb] MrQuansy commented on a diff in pull request #7212: [IOTDB-4300] writing data with benchmark then remove a datanode, there are some errors

MrQuansy commented on code in PR #7212:
URL: https://github.com/apache/iotdb/pull/7212#discussion_r961383644


##########
server/src/main/java/org/apache/iotdb/db/mpp/plan/execution/QueryExecution.java:
##########
@@ -478,10 +478,19 @@ private ExecutionResult getExecutionResult(QueryState state) {
 
     // collect redirect info to client for writing
     if (analysis.getStatement() instanceof InsertBaseStatement) {
+      if (state != QueryState.FINISHED) {
+        //if insert not finished, then before redirect to client: clean partition cache and re analyse to get the current
+        // region locations, so the redirect node is available. maybe region migrated when writing.
+        partitionFetcher.invalidAllCache();

Review Comment:
   This will cause drastic decrease of writing and reading performance. You should invalid specific cache entries instead of all cache. 



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: reviews-unsubscribe@iotdb.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org