Return-Path: Delivered-To: apmail-hadoop-common-user-archive@www.apache.org Received: (qmail 53604 invoked from network); 31 Dec 2010 02:13:48 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 31 Dec 2010 02:13:48 -0000 Received: (qmail 70109 invoked by uid 500); 31 Dec 2010 02:13:45 -0000 Delivered-To: apmail-hadoop-common-user-archive@hadoop.apache.org Received: (qmail 70075 invoked by uid 500); 31 Dec 2010 02:13:45 -0000 Mailing-List: contact common-user-help@hadoop.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: common-user@hadoop.apache.org Delivered-To: mailing list common-user@hadoop.apache.org Received: (qmail 70067 invoked by uid 99); 31 Dec 2010 02:13:45 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 31 Dec 2010 02:13:45 +0000 X-ASF-Spam-Status: No, hits=1.5 required=10.0 tests=FREEMAIL_FROM,HTML_MESSAGE,RCVD_IN_DNSWL_LOW,RFC_ABUSE_POST,SPF_PASS,T_TO_NO_BRKTS_FREEMAIL X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of li.j2ee@gmail.com designates 209.85.214.48 as permitted sender) Received: from [209.85.214.48] (HELO mail-bw0-f48.google.com) (209.85.214.48) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 31 Dec 2010 02:13:39 +0000 Received: by bwz8 with SMTP id 8so11634698bwz.35 for ; Thu, 30 Dec 2010 18:13:18 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:received:in-reply-to :references:date:message-id:subject:from:to:content-type; bh=Kew0B23LvjUeycgmqZsehLFTNwchTA/jDUoyKPJFsoU=; b=tgPl1p8eAo/sAXYtwWd2HeWywllF0HDze57ywPEmP/aHX6GSjlfVhZUx3K69feHQaV gCOMyS+/Skko4g4WHVOFb08UM75umReaRxfJt/v5pYYAK4p+td+J19WSQuwXca1hjLPZ n6B6TRCyxZYNnTPBBlMinPRE0bK6QbqyGJar4= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; b=wx91JdFtaSuYsEUnhVvpXCttoWDlUOW6JjY/NEwrxWGbJqYn9teXoR9YRuWOCPI18m aRA7G28i4yit87a9ICdyHdbBctRpVLwRwmLm7sJd35gbRAWRA1pb7aTCqH4On1Eu6FQ4 F8sHD64Jx1SufZhkKLM3IU9bty3Oonq+9GGPg= MIME-Version: 1.0 Received: by 10.204.60.17 with SMTP id n17mr6343579bkh.190.1293761597983; Thu, 30 Dec 2010 18:13:17 -0800 (PST) Received: by 10.204.52.72 with HTTP; Thu, 30 Dec 2010 18:13:17 -0800 (PST) In-Reply-To: <59AD6C61-0038-4936-B2A4-1E60C1FF8196@umail.ucsb.edu> References: <59AD6C61-0038-4936-B2A4-1E60C1FF8196@umail.ucsb.edu> Date: Fri, 31 Dec 2010 10:13:17 +0800 Message-ID: Subject: Re: Flow of control From: li ping To: common-user@hadoop.apache.org Content-Type: multipart/alternative; boundary=001636c5a9ab78ccf90498ab5877 X-Virus-Checked: Checked by ClamAV on apache.org --001636c5a9ab78ccf90498ab5877 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable On Fri, Dec 31, 2010 at 9:28 AM, maha wrote: > Hi, > > (1) I declared a global variable in my hadoop mainClass which gets > initialized in the 'run' function of this mainClass. When I try to access > this global static variable from the MapperClass, it appears to be > uninitialized. > > Why is that? Is it because of the parallel execution of Hadoop > functions ? but , isn't the 'run' function supposed to be the one to run > first and prepare all the job configurations before the Maps even start? > The Mapper will run on a remote machine, in other JVM, so the variable you set in Main class can not be shared with other VM. > > (2) Fig 4.5 in http://developer.yahoo.com/hadoop/tutorial/module4.html s= hows the inputFormat to be the one running before the maps. My question is > in which node? The JobTracker node? > I think it should run on JobTracker, The inputFormat will split the file > and the map function will read the every splited file. > Thank you, > Maha --=20 -----=E6=9D=8E=E5=B9=B3 --001636c5a9ab78ccf90498ab5877--