mychaow commented on a change in pull request #1854:
URL: https://github.com/apache/iotdb/pull/1854#discussion_r512441727



##########
File path: 
server/src/main/java/org/apache/iotdb/db/qp/executor/PlanExecutor.java
##########
@@ -1070,11 +1075,19 @@ private boolean 
createMultiTimeSeries(CreateMultiTimeSeriesPlan createMultiTimeS
       try {
         createTimeSeries(plan);
       } catch (QueryProcessException e) {
-        results.put(createMultiTimeSeriesPlan.getIndexes().get(i), e);
+        if (results == null) {
+          results = new 
TSStatus[createMultiTimeSeriesPlan.getIndexes().size()];
+          Arrays.fill(results, RpcUtils.SUCCESS_STATUS);
+        }
+        results[i] = RpcUtils.getStatus(TSStatusCode.INTERNAL_SERVER_ERROR, 
e.getMessage());
+        hasFailed = true;
         logger.debug("meet error while processing create timeseries. ", e);
       }
     }
-    createMultiTimeSeriesPlan.setResults(results);
+
+    if (hasFailed) {
+      throw new BatchInsertionException(results);

Review comment:
       ok




----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to