Return-Path: X-Original-To: apmail-hadoop-common-issues-archive@minotaur.apache.org Delivered-To: apmail-hadoop-common-issues-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 9D6EB10CB6 for ; Fri, 22 Nov 2013 22:34:35 +0000 (UTC) Received: (qmail 81753 invoked by uid 500); 22 Nov 2013 22:34:35 -0000 Delivered-To: apmail-hadoop-common-issues-archive@hadoop.apache.org Received: (qmail 81725 invoked by uid 500); 22 Nov 2013 22:34:35 -0000 Mailing-List: contact common-issues-help@hadoop.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: common-issues@hadoop.apache.org Delivered-To: mailing list common-issues@hadoop.apache.org Received: (qmail 81715 invoked by uid 99); 22 Nov 2013 22:34:35 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 22 Nov 2013 22:34:35 +0000 Date: Fri, 22 Nov 2013 22:34:35 +0000 (UTC) From: "Mike Liddell (JIRA)" To: common-issues@hadoop.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Created] (HADOOP-10124) Option to shuffle splits of equal size MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 Mike Liddell created HADOOP-10124: ------------------------------------- Summary: Option to shuffle splits of equal size Key: HADOOP-10124 URL: https://issues.apache.org/jira/browse/HADOOP-10124 Project: Hadoop Common Issue Type: Improvement Reporter: Mike Liddell Mapreduce split calculation has the following base logic (via JobClient and= the major InputFormat implementations ): =E2=97=BEenumerate input files in natural (aka linear) order. =E2=97=BEcreate one split for each 'block-size' of each input. Apart from r= ack-awareness, combining and so on, the input file order remains in its nat= ural order. =E2=97=BEsort the splits by size using a stable sort based on splitsize. When data from multiple storage services are used in a single hadoop job, w= e get better I/O utilization if the list of splits does round-robin or rand= om-access across the services.=20 The particular scenario arises in Azure HDInsight where jobs can easily rea= d from many storage accounts and each storage account has hard limits on th= roughtput. Concurrent access to the accounts is substantially better than= =20 =20 Two common scenarios can cause non-ideal access pattern: 1. many/all input files are the same size 2. files have different sizes, but many/all input files have size>blocksiz= e. In the second scenario, for each file will have one or more splits with si= ze exactly equal to block size so it basically degenerates to the first sce= nario. There are various ways to solve the problem but the simplest is to alter th= e mapreduce JobClient to sort splits by size _and_ randomize the order of s= plits with equal size. This keeps the old behavior effectively unchanged wh= ile also fixing both common problematic scenarios. Some rare scenarios will still suffer bad access patterns due. For example = if two storage accounts are used and the files from one storage account are= all smaller than from the other then problems can arise. Addressing these = scenarios would be further work, perhaps by completely randomizing the spli= t order. These problematic scenarios are considered rare and not requiring = immediate attention. If further algorithms for split ordering are necessary, the implementation = in JobClient will change to being interface-based (eg interface splitOrdere= r) with various standard implementations. At this time there is only the n= eed for two implementations and so simple Boolean flag and if/then logic is= used. -- This message was sent by Atlassian JIRA (v6.1#6144)