You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@iotdb.apache.org by qi...@apache.org on 2019/12/10 13:55:52 UTC

[incubator-iotdb] branch master updated: try to fix the batch error. (#639)

This is an automated email from the ASF dual-hosted git repository.

qiaojialin pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-iotdb.git


The following commit(s) were added to refs/heads/master by this push:
     new 025653a  try to fix the batch error. (#639)
025653a is described below

commit 025653a45957c5956ffecc05d182b942a4ee0c03
Author: Boris <zh...@gmail.com>
AuthorDate: Tue Dec 10 21:55:42 2019 +0800

    try to fix the batch error. (#639)
    
    * cache exception in Antlr
---
 server/src/main/java/org/apache/iotdb/db/service/TSServiceImpl.java | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/server/src/main/java/org/apache/iotdb/db/service/TSServiceImpl.java b/server/src/main/java/org/apache/iotdb/db/service/TSServiceImpl.java
index 5af019f..4eeb357 100644
--- a/server/src/main/java/org/apache/iotdb/db/service/TSServiceImpl.java
+++ b/server/src/main/java/org/apache/iotdb/db/service/TSServiceImpl.java
@@ -512,6 +512,11 @@ public class TSServiceImpl implements TSIService.Iface, ServerContext {
         batchErrorMessage.append(resp.getStatus().getStatusType().getCode()).append("\n");
         return false;
       }
+    } catch (ParseCancellationException e) {
+      logger.debug(e.getMessage());
+      result.add(Statement.EXECUTE_FAILED);
+      batchErrorMessage.append(TSStatusCode.SQL_PARSE_ERROR.getStatusCode()).append("\n");
+      return false;
     } catch (SQLParserException e) {
       logger.error("Error occurred when executing {}, check metadata error: ", statement, e);
       result.add(Statement.EXECUTE_FAILED);