You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mesos.apache.org by me...@apache.org on 2014/11/12 07:08:58 UTC
mesos git commit: Check for non-zero status code and hadoop client
not found.
Repository: mesos
Updated Branches:
refs/heads/master 8adb36e3f -> 6712eefd1
Check for non-zero status code and hadoop client not found.
The fetcher would detect the condition where hadoop returns a success in
case of a success non zero value.
Review: https://reviews.apache.org/r/27670
Project: http://git-wip-us.apache.org/repos/asf/mesos/repo
Commit: http://git-wip-us.apache.org/repos/asf/mesos/commit/6712eefd
Tree: http://git-wip-us.apache.org/repos/asf/mesos/tree/6712eefd
Diff: http://git-wip-us.apache.org/repos/asf/mesos/diff/6712eefd
Branch: refs/heads/master
Commit: 6712eefd17259f1241fc8b75bfd0d5e47b687aff
Parents: 8adb36e
Author: Ankur Chauhan <an...@malloc64.com>
Authored: Tue Nov 11 21:14:13 2014 -0800
Committer: Adam B <ad...@mesosphere.io>
Committed: Tue Nov 11 21:14:13 2014 -0800
----------------------------------------------------------------------
src/launcher/fetcher.cpp | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/mesos/blob/6712eefd/src/launcher/fetcher.cpp
----------------------------------------------------------------------
diff --git a/src/launcher/fetcher.cpp b/src/launcher/fetcher.cpp
index 400fadf..6894d87 100644
--- a/src/launcher/fetcher.cpp
+++ b/src/launcher/fetcher.cpp
@@ -82,7 +82,9 @@ Try<string> fetchWithHadoopClient(
const string& directory)
{
HDFS hdfs;
- if (hdfs.available().isError()) {
+ Try<bool> available = hdfs.available();
+
+ if (available.isError() || !available.get()) {
LOG(INFO) << "Hadoop Client not available, "
<< "skipping fetch with Hadoop Client";
return Error("Hadoop Client unavailable");