From d97ab376d2d2c5ae1173141037c2c5eb85dd7f18 Mon Sep 17 00:00:00 2001 From: Thomas White Date: Mon, 28 Feb 2011 21:48:49 +0000 Subject: [PATCH] HADOOP-7112. Issue a warning when GenericOptionsParser libjars are not on local filesystem. git-svn-id: https://svn.apache.org/repos/asf/hadoop/common/trunk@1075554 13f79535-47bb-0310-9956-ffa450edef68 --- CHANGES.txt | 3 +++ src/java/org/apache/hadoop/util/GenericOptionsParser.java | 3 +++ 2 files changed, 6 insertions(+) diff --git a/CHANGES.txt b/CHANGES.txt index 7ea50ec80fa..03fd1916d8d 100644 --- a/CHANGES.txt +++ b/CHANGES.txt @@ -60,6 +60,9 @@ Trunk (unreleased changes) HADOOP-7151. Document need for stable hashCode() in WritableComparable. (Dmitriy V. Ryaboy via todd) + HADOOP-7112. Issue a warning when GenericOptionsParser libjars are not on + local filesystem. (tomwhite) + OPTIMIZATIONS BUG FIXES diff --git a/src/java/org/apache/hadoop/util/GenericOptionsParser.java b/src/java/org/apache/hadoop/util/GenericOptionsParser.java index 4eb280d9d4d..5189e8e0535 100644 --- a/src/java/org/apache/hadoop/util/GenericOptionsParser.java +++ b/src/java/org/apache/hadoop/util/GenericOptionsParser.java @@ -342,6 +342,9 @@ public static URL[] getLibJars(Configuration conf) throws IOException { Path tmp = new Path(file); if (tmp.getFileSystem(conf).equals(FileSystem.getLocal(conf))) { cp.add(FileSystem.getLocal(conf).pathToFile(tmp).toURI().toURL()); + } else { + LOG.warn("The libjars file " + tmp + " is not on the local " + + "filesystem. Ignoring."); } } return cp.toArray(new URL[0]);