Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id EC048200BC1 for ; Wed, 2 Nov 2016 00:31:15 +0100 (CET) Received: by cust-asf.ponee.io (Postfix) id EAA73160B02; Tue, 1 Nov 2016 23:31:15 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id 3CDF6160AF7 for ; Wed, 2 Nov 2016 00:31:15 +0100 (CET) Received: (qmail 69255 invoked by uid 500); 1 Nov 2016 23:31:14 -0000 Mailing-List: contact reviews-help@impala.incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Delivered-To: mailing list reviews@impala.incubator.apache.org Received: (qmail 69244 invoked by uid 99); 1 Nov 2016 23:31:14 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd4-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 01 Nov 2016 23:31:14 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd4-us-west.apache.org (ASF Mail Server at spamd4-us-west.apache.org) with ESMTP id BC894C07CC for ; Tue, 1 Nov 2016 23:31:13 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd4-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: 0.363 X-Spam-Level: X-Spam-Status: No, score=0.363 tagged_above=-999 required=6.31 tests=[RDNS_DYNAMIC=0.363, SPF_PASS=-0.001, URIBL_BLOCKED=0.001] autolearn=disabled Received: from mx1-lw-us.apache.org ([10.40.0.8]) by localhost (spamd4-us-west.apache.org [10.40.0.11]) (amavisd-new, port 10024) with ESMTP id Z42nAiqjz7sM for ; Tue, 1 Nov 2016 23:31:12 +0000 (UTC) Received: from ip-10-146-233-104.ec2.internal (ec2-75-101-130-251.compute-1.amazonaws.com [75.101.130.251]) by mx1-lw-us.apache.org (ASF Mail Server at mx1-lw-us.apache.org) with ESMTPS id CC2505FB04 for ; Tue, 1 Nov 2016 23:31:11 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by ip-10-146-233-104.ec2.internal (8.14.4/8.14.4) with ESMTP id uA1NVBe3023199; Tue, 1 Nov 2016 23:31:11 GMT Date: Tue, 1 Nov 2016 23:31:11 +0000 From: "Henry Robinson (Code Review)" To: impala-cr@cloudera.com, reviews@impala.incubator.apache.org Message-ID: Reply-To: henry@cloudera.com X-Gerrit-MessageType: newchange Subject: =?UTF-8?Q?=5BImpala-ASF-CR=5D_IMPALA-4415=3A_Fix_unassigned_scan_range_of_size_1=0A?= X-Gerrit-Change-Id: Id3af767ee9d121ca62ac383ef9e696a18dc903d6 X-Gerrit-ChangeURL: X-Gerrit-Commit: a8f44e8a821c52620ec8d1b4f8a016c98622a013 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Content-Disposition: inline User-Agent: Gerrit/2.12.2 archived-at: Tue, 01 Nov 2016 23:31:16 -0000 Henry Robinson has uploaded a new change for review. http://gerrit.cloudera.org:8080/4907 Change subject: IMPALA-4415: Fix unassigned scan range of size 1 ...................................................................... IMPALA-4415: Fix unassigned scan range of size 1 ComputeScanRangeAssignment() computes the per-node scan-range load as the total number of bytes to be scanned / number of nodes, and casts that to a float. However, that computation suffers from a precision issue where the average * num_nodes may be 1 byte less than the total. The scan range assignment loop continues until at least average * num_nodes bytes have been assigned. If the last scan range has only 1 byte, it will not be assigned (if it has 2 or more bytes, it will be considered for assignment before the loop exit condition is met). The fix is to make sure that all instances are assigned in the last iteration of the assignment loop, even if the per-node threshold is already met. Testing: No local repro was found - only S3 and LocalFS builds have it. A unit test requires a lot of infrastructure from simple-scheduler-util that doesn't exist yet (e.g. ComputeScanRangeAssignment() is not called). S3 and LocalFS full test builds are in progress. Change-Id: Id3af767ee9d121ca62ac383ef9e696a18dc903d6 --- M be/src/scheduling/simple-scheduler.cc 1 file changed, 14 insertions(+), 7 deletions(-) git pull ssh://gerrit.cloudera.org:29418/Impala-ASF refs/changes/07/4907/1 -- To view, visit http://gerrit.cloudera.org:8080/4907 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Id3af767ee9d121ca62ac383ef9e696a18dc903d6 Gerrit-PatchSet: 1 Gerrit-Project: Impala-ASF Gerrit-Branch: master Gerrit-Owner: Henry Robinson