You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@iotdb.apache.org by li...@apache.org on 2019/05/24 13:17:17 UTC

[incubator-iotdb] branch zc_test created (now 1d7c8ea)

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

liurui pushed a change to branch zc_test
in repository https://gitbox.apache.org/repos/asf/incubator-iotdb.git.


      at 1d7c8ea  add log in TSServiceImpl

This branch includes the following new commits:

     new 1d7c8ea  add log in TSServiceImpl

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



[incubator-iotdb] 01/01: add log in TSServiceImpl

Posted by li...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

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

commit 1d7c8ea66a85b359c81c9d8309799545d44f1792
Author: liuruiyiyang <24...@qq.com>
AuthorDate: Fri May 24 21:07:57 2019 +0800

    add log in TSServiceImpl
---
 iotdb/src/main/java/org/apache/iotdb/db/service/TSServiceImpl.java | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/iotdb/src/main/java/org/apache/iotdb/db/service/TSServiceImpl.java b/iotdb/src/main/java/org/apache/iotdb/db/service/TSServiceImpl.java
index b02f1c2..e4b8f61 100644
--- a/iotdb/src/main/java/org/apache/iotdb/db/service/TSServiceImpl.java
+++ b/iotdb/src/main/java/org/apache/iotdb/db/service/TSServiceImpl.java
@@ -484,6 +484,7 @@ public class TSServiceImpl implements TSIService.Iface, ServerContext {
 
   @Override
   public TSExecuteStatementResp executeStatement(TSExecuteStatementReq req) throws TException {
+    long start = System.currentTimeMillis();
     try {
       if (!checkLogin()) {
         LOGGER.info(INFO_NOT_LOGIN, IoTDBConstant.GLOBAL_DB_NAME);
@@ -524,6 +525,8 @@ public class TSServiceImpl implements TSIService.Iface, ServerContext {
       if (physicalPlan.isQuery()) {
         return executeQueryStatement(req);
       } else {
+        long elapse = System.currentTimeMillis() - start;
+        LOGGER.info("executeStatement() start to executeUpdateStatement() cost ,{}, ms", elapse);
         return executeUpdateStatement(physicalPlan);
       }
     } catch (Exception e) {
@@ -737,6 +740,7 @@ public class TSServiceImpl implements TSIService.Iface, ServerContext {
   }
 
   private TSExecuteStatementResp executeUpdateStatement(PhysicalPlan plan) {
+    long start = System.currentTimeMillis();
     List<Path> paths = plan.getPaths();
 
     try {
@@ -768,6 +772,8 @@ public class TSServiceImpl implements TSIService.Iface, ServerContext {
     TSOperationHandle operationHandle;
     operationHandle = new TSOperationHandle(operationId, false);
     resp.setOperationHandle(operationHandle);
+    long elapse = System.currentTimeMillis() - start;
+    LOGGER.info("executeUpdateStatement(PhysicalPlan) cost ,{}, ms", elapse);
     return resp;
   }