You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mesos.apache.org by ji...@apache.org on 2016/03/01 23:33:51 UTC
[1/2] mesos git commit: Added FS_DEFAULT case in rmdir.
Repository: mesos
Updated Branches:
refs/heads/master 4f59f9804 -> 12de94803
Added FS_DEFAULT case in rmdir.
We currently dont handle special files like device files in rmdir. This
change adds FS_DEFAULT as one of the cases where we try to unlink a
file. Reference: http://man7.org/linux/man-pages/man3/fts.3.html
Review: https://reviews.apache.org/r/44230/
Project: http://git-wip-us.apache.org/repos/asf/mesos/repo
Commit: http://git-wip-us.apache.org/repos/asf/mesos/commit/f8b7ac28
Tree: http://git-wip-us.apache.org/repos/asf/mesos/tree/f8b7ac28
Diff: http://git-wip-us.apache.org/repos/asf/mesos/diff/f8b7ac28
Branch: refs/heads/master
Commit: f8b7ac28b1a918864a06b3f99f45b0257c7b6f68
Parents: 4f59f98
Author: Jojy Varghese <jo...@mesosphere.io>
Authored: Tue Mar 1 14:32:13 2016 -0800
Committer: Jie Yu <yu...@gmail.com>
Committed: Tue Mar 1 14:32:13 2016 -0800
----------------------------------------------------------------------
.../libprocess/3rdparty/stout/include/stout/os/posix/rmdir.hpp | 4 ++++
1 file changed, 4 insertions(+)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/mesos/blob/f8b7ac28/3rdparty/libprocess/3rdparty/stout/include/stout/os/posix/rmdir.hpp
----------------------------------------------------------------------
diff --git a/3rdparty/libprocess/3rdparty/stout/include/stout/os/posix/rmdir.hpp b/3rdparty/libprocess/3rdparty/stout/include/stout/os/posix/rmdir.hpp
index bc420c9..3da85dd 100644
--- a/3rdparty/libprocess/3rdparty/stout/include/stout/os/posix/rmdir.hpp
+++ b/3rdparty/libprocess/3rdparty/stout/include/stout/os/posix/rmdir.hpp
@@ -52,6 +52,10 @@ inline Try<Nothing> rmdir(const std::string& directory, bool recursive = true)
return error;
}
break;
+ // `FTS_DEFAULT` would include any file type which is not
+ // explicitly described by any of the other `fts_info` values.
+ // TODO(jojy): Consider adding the case for `FTS_SLNONE`.
+ case FTS_DEFAULT:
case FTS_F:
case FTS_SL:
if (::unlink(node->fts_path) < 0 && errno != ENOENT) {
[2/2] mesos git commit: Added rmdir error string to Appc store fetch.
Posted by ji...@apache.org.
Added rmdir error string to Appc store fetch.
Review: https://reviews.apache.org/r/44231/
Project: http://git-wip-us.apache.org/repos/asf/mesos/repo
Commit: http://git-wip-us.apache.org/repos/asf/mesos/commit/12de9480
Tree: http://git-wip-us.apache.org/repos/asf/mesos/tree/12de9480
Diff: http://git-wip-us.apache.org/repos/asf/mesos/diff/12de9480
Branch: refs/heads/master
Commit: 12de948035e1d1aea38c41f25ba7f3acbebe14f1
Parents: f8b7ac2
Author: Jojy Varghese <jo...@mesosphere.io>
Authored: Tue Mar 1 14:33:31 2016 -0800
Committer: Jie Yu <yu...@gmail.com>
Committed: Tue Mar 1 14:33:31 2016 -0800
----------------------------------------------------------------------
src/slave/containerizer/mesos/provisioner/appc/store.cpp | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/mesos/blob/12de9480/src/slave/containerizer/mesos/provisioner/appc/store.cpp
----------------------------------------------------------------------
diff --git a/src/slave/containerizer/mesos/provisioner/appc/store.cpp b/src/slave/containerizer/mesos/provisioner/appc/store.cpp
index 955647d..1e893da 100644
--- a/src/slave/containerizer/mesos/provisioner/appc/store.cpp
+++ b/src/slave/containerizer/mesos/provisioner/appc/store.cpp
@@ -281,7 +281,8 @@ Future<string> StoreProcess::_fetchImage(const Image::Appc& appc)
if (rmdir.isError()) {
return Failure(
"Failed to remove temporary fetch directory '" +
- tmpFetchDir + "' for image '" + appc.name() + "'");
+ tmpFetchDir + "' for image '" + appc.name() + "': " +
+ rmdir.error());
}
return imageId;