From commits-return-1600-archive-asf-public=cust-asf.ponee.io@superset.incubator.apache.org Thu Oct 4 20:13:51 2018 Return-Path: X-Original-To: archive-asf-public@cust-asf.ponee.io Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by mx-eu-01.ponee.io (Postfix) with SMTP id B5119180658 for ; Thu, 4 Oct 2018 20:13:50 +0200 (CEST) Received: (qmail 83077 invoked by uid 500); 4 Oct 2018 18:13:49 -0000 Mailing-List: contact commits-help@superset.incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@superset.incubator.apache.org Delivered-To: mailing list commits@superset.incubator.apache.org Received: (qmail 83068 invoked by uid 99); 4 Oct 2018 18:13:49 -0000 Received: from ec2-52-202-80-70.compute-1.amazonaws.com (HELO gitbox.apache.org) (52.202.80.70) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 04 Oct 2018 18:13:49 +0000 Received: by gitbox.apache.org (ASF Mail Server at gitbox.apache.org, from userid 33) id 3908B85B59; Thu, 4 Oct 2018 18:13:49 +0000 (UTC) Date: Thu, 04 Oct 2018 18:13:49 +0000 To: "commits@superset.apache.org" Subject: [incubator-superset] branch master updated: log query fetch time (#6033) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Message-ID: <153867682898.16348.10756295441067898406@gitbox.apache.org> From: timi@apache.org X-Git-Host: gitbox.apache.org X-Git-Repo: incubator-superset X-Git-Refname: refs/heads/master X-Git-Reftype: branch X-Git-Oldrev: ab5c9108017d0ce519cc518ffb04a83fb73f4ccc X-Git-Newrev: e12d00ae717534a442a12aee1e9f8151d9563242 X-Git-Rev: e12d00ae717534a442a12aee1e9f8151d9563242 X-Git-NotificationType: ref_changed_plus_diff X-Git-Multimail-Version: 1.5.dev Auto-Submitted: auto-generated This is an automated email from the ASF dual-hosted git repository. timi pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/incubator-superset.git The following commit(s) were added to refs/heads/master by this push: new e12d00a log query fetch time (#6033) e12d00a is described below commit e12d00ae717534a442a12aee1e9f8151d9563242 Author: timifasubaa <30888507+timifasubaa@users.noreply.github.com> AuthorDate: Thu Oct 4 11:13:32 2018 -0700 log query fetch time (#6033) --- superset/sql_lab.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/superset/sql_lab.py b/superset/sql_lab.py index a2732d1..4db788b 100644 --- a/superset/sql_lab.py +++ b/superset/sql_lab.py @@ -186,10 +186,14 @@ def execute_sql( logging.info('Handling cursor') db_engine_spec.handle_cursor(cursor, query, session) logging.info('Fetching data: {}'.format(query.to_dict())) - data = db_engine_spec.fetch_data(cursor, query.limit) stats_logger.timing( 'sqllab.query.time_executing_query', now_as_float() - query_start_time) + fetching_start_time = now_as_float() + data = db_engine_spec.fetch_data(cursor, query.limit) + stats_logger.timing( + 'sqllab.query.time_fetching_results', + now_as_float() - fetching_start_time) except SoftTimeLimitExceeded as e: logging.exception(e) if conn is not None: