Return-Path: X-Original-To: apmail-hadoop-hdfs-user-archive@minotaur.apache.org Delivered-To: apmail-hadoop-hdfs-user-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id BD974108DA for ; Sat, 6 Jul 2013 02:02:11 +0000 (UTC) Received: (qmail 41228 invoked by uid 500); 6 Jul 2013 02:02:06 -0000 Delivered-To: apmail-hadoop-hdfs-user-archive@hadoop.apache.org Received: (qmail 40963 invoked by uid 500); 6 Jul 2013 02:02:06 -0000 Mailing-List: contact user-help@hadoop.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@hadoop.apache.org Delivered-To: mailing list user@hadoop.apache.org Received: (qmail 40956 invoked by uid 99); 6 Jul 2013 02:02:06 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 06 Jul 2013 02:02:06 +0000 X-ASF-Spam-Status: No, hits=-0.0 required=5.0 tests=RCVD_IN_DNSWL_NONE,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of harsh@cloudera.com designates 209.85.192.173 as permitted sender) Received: from [209.85.192.173] (HELO mail-pd0-f173.google.com) (209.85.192.173) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 06 Jul 2013 02:02:02 +0000 Received: by mail-pd0-f173.google.com with SMTP id v14so2414093pde.18 for ; Fri, 05 Jul 2013 19:01:42 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :content-type:content-transfer-encoding:x-gm-message-state; bh=1lqbmUIvP/pXRb5ruydBQozNk46EPjQxt0FC1bg/LKg=; b=k5hseD52eSO7XMfQABOyl2QdLoNY/NGNOj9h3+4xrGmfa2lru2SNv3M1tVW1l4y6ox 0UfA0vuT7HWC8SeBLxMywRgxl/BI08vTz7F4UUoZjm5BiCiCJ4XErgmxwn96Re3KTG0V EXZnd/OPCQ20vJdc9LKlKgP5a4Rh5hVN43IEo7fTPOJcHUcWHhPbpFdgk4m85ypLSt/U j0v3XDvdDh5LJQEvaECQrHPgwSqaDS/742qcQClYQpjULxrvZQKDFsDiIms/bXR5/MRU JuWzJdBkSks4wj41IxdmJu27Ma3Dvt1CpCdlvQNcCm3erGQ564Y0+yZgiGpB422C1V6w DyOA== X-Received: by 10.68.36.230 with SMTP id t6mr12126318pbj.15.1373076102213; Fri, 05 Jul 2013 19:01:42 -0700 (PDT) MIME-Version: 1.0 Received: by 10.70.75.168 with HTTP; Fri, 5 Jul 2013 19:01:22 -0700 (PDT) In-Reply-To: <869970D71E26D7498BDAC4E1CA92226B658DA8B1@MBX021-E3-NJ-2.exch021.domain.local> References: <869970D71E26D7498BDAC4E1CA92226B658DA8B1@MBX021-E3-NJ-2.exch021.domain.local> From: Harsh J Date: Sat, 6 Jul 2013 07:31:22 +0530 Message-ID: Subject: Re: Accessing HDFS To: "" Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: quoted-printable X-Gm-Message-State: ALoCoQkQzSSd8wR56HQXwU53hqsC6daeERjlNLWPFeH9zPmLvuJvtkZuS7bu01T0XYxDkh1v/9Se X-Virus-Checked: Checked by ClamAV on apache.org These APIs (ClientProtocol, DFSClient) are not for Public access. Please do not use them in production. The only API we care not to change incompatibly are the FileContext and the FileSystem APIs. They provide much of what you want - if not, log a JIRA. On Fri, Jul 5, 2013 at 11:40 PM, John Lilley wro= te: > I=92ve seen mentioned that you can access HDFS via ClientProtocol, as in: > > ClientProtocol namenode =3D DFSClient.createNamenode(conf); > LocatedBlocks lbs =3D namenode.getBlockLocations(path, start, length); > > > > But we use: > > fs =3D FileSystem.get(URI, conf); > > filestatus =3D fs.getFileStatus(path); > > fs.getFileBlockLocations(filestatus, start, length); > > > > As a YARN application and/or DFS client, are there times when I should us= e > the ClientProtocol directly? > > > > Thanks > > John > > --=20 Harsh J