Return-Path: X-Original-To: apmail-hadoop-common-user-archive@www.apache.org Delivered-To: apmail-hadoop-common-user-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 7267F9F3B for ; Mon, 12 Mar 2012 21:39:09 +0000 (UTC) Received: (qmail 73151 invoked by uid 500); 12 Mar 2012 21:39:05 -0000 Delivered-To: apmail-hadoop-common-user-archive@hadoop.apache.org Received: (qmail 73106 invoked by uid 500); 12 Mar 2012 21:39:05 -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 73097 invoked by uid 99); 12 Mar 2012 21:39:05 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 12 Mar 2012 21:39:05 +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 (nike.apache.org: domain of kwiley@keithwiley.com designates 69.93.243.27 as permitted sender) Received: from [69.93.243.27] (HELO gateway04.websitewelcome.com) (69.93.243.27) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 12 Mar 2012 21:38:56 +0000 Received: by gateway04.websitewelcome.com (Postfix, from userid 5007) id 309B6768C379; Mon, 12 Mar 2012 16:38:35 -0500 (CDT) Received: from gator542.hostgator.com (gator542.hostgator.com [74.54.187.114]) by gateway04.websitewelcome.com (Postfix) with ESMTP id 24518768C33C for ; Mon, 12 Mar 2012 16:38:35 -0500 (CDT) Received: from [24.19.6.8] (port=43349 helo=[192.168.10.2]) by gator542.hostgator.com with esmtpsa (TLSv1:AES128-SHA:128) (Exim 4.69) (envelope-from ) id 1S7Cws-0003dA-Si for common-user@hadoop.apache.org; Mon, 12 Mar 2012 16:38:35 -0500 Content-Type: text/plain; charset=us-ascii Mime-Version: 1.0 (Apple Message framework v1084) Subject: Re: Is there a way to get an absolute HDFS path? From: Keith Wiley In-Reply-To: Date: Mon, 12 Mar 2012 14:38:33 -0700 Content-Transfer-Encoding: quoted-printable Message-Id: References: To: common-user@hadoop.apache.org X-Mailer: Apple Mail (2.1084) X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - gator542.hostgator.com X-AntiAbuse: Original Domain - hadoop.apache.org X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12] X-AntiAbuse: Sender Address Domain - keithwiley.com X-BWhitelist: no X-Source: X-Source-Args: X-Source-Dir: X-Source-Sender: c-24-19-6-8.hsd1.wa.comcast.net ([192.168.10.2]) [24.19.6.8]:43349 X-Source-Auth: kwiley+keithwiley.com X-Email-Count: 1 X-Source-Cap: a2J3aWxleTtrYndpbGV5O2dhdG9yNTQyLmhvc3RnYXRvci5jb20= X-Virus-Checked: Checked by ClamAV on apache.org In the first example you want it to chop off the /sub/ directory. Why? = What is the indicator as to how many lower directories you want chopped = off? In the second example, how can it turn a relative path into an = absolute path considering that there may be multiple "top" directories = scattered all over the file system? How should it know which "top" you = want it to build an absolute path to? For example, why not /top/sub or = /user/top/sub? On Mar 12, 2012, at 14:20 , W.P. McNeill wrote: > Is there an API that returns absolute HDFS paths? So something that = would > turn "/user/myname/top/sub/.." into "/user/myname/top" and "top/sub" = into > "/user/mynname/top/sub"? I've been looking for this functionality = where I > think it would be (e.g. FileSystem or Path) but can't find it. = __________________________________________________________________________= ______ Keith Wiley kwiley@keithwiley.com keithwiley.com = music.keithwiley.com "You can scratch an itch, but you can't itch a scratch. Furthermore, an = itch can itch but a scratch can't scratch. Finally, a scratch can itch, but an = itch can't scratch. All together this implies: He scratched the itch from the = scratch that itched but would never itch the scratch from the itch that scratched." -- Keith Wiley = __________________________________________________________________________= ______