You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mesos.apache.org by ha...@apache.org on 2017/01/25 18:14:09 UTC
mesos git commit: Renamed `taskID` to `taskId` in `HealthChecker`.
Repository: mesos
Updated Branches:
refs/heads/master 4e70ccfa7 -> 636866c54
Renamed `taskID` to `taskId` in `HealthChecker`.
We normally use `taskId` for variables that hold a `TaskID`, so I
renamed the attribute/parameters to be consistent with the rest of the
codebase.
Review: https://reviews.apache.org/r/55899/
Project: http://git-wip-us.apache.org/repos/asf/mesos/repo
Commit: http://git-wip-us.apache.org/repos/asf/mesos/commit/636866c5
Tree: http://git-wip-us.apache.org/repos/asf/mesos/tree/636866c5
Diff: http://git-wip-us.apache.org/repos/asf/mesos/diff/636866c5
Branch: refs/heads/master
Commit: 636866c540c696ec99785fd27328f93201e88d3d
Parents: 4e70ccf
Author: Gast�n Kleiman <ga...@mesosphere.com>
Authored: Thu Jan 26 02:11:13 2017 +0800
Committer: Haosdent Huang <ha...@apache.org>
Committed: Thu Jan 26 02:11:13 2017 +0800
----------------------------------------------------------------------
src/checks/health_checker.cpp | 12 ++++++------
src/checks/health_checker.hpp | 8 ++++----
2 files changed, 10 insertions(+), 10 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/mesos/blob/636866c5/src/checks/health_checker.cpp
----------------------------------------------------------------------
diff --git a/src/checks/health_checker.cpp b/src/checks/health_checker.cpp
index 50aa285..e70bd79 100644
--- a/src/checks/health_checker.cpp
+++ b/src/checks/health_checker.cpp
@@ -122,7 +122,7 @@ Try<Owned<HealthChecker>> HealthChecker::create(
const HealthCheck& check,
const string& launcherDir,
const lambda::function<void(const TaskHealthStatus&)>& callback,
- const TaskID& taskID,
+ const TaskID& taskId,
Option<pid_t> taskPid,
const vector<string>& namespaces)
{
@@ -136,7 +136,7 @@ Try<Owned<HealthChecker>> HealthChecker::create(
check,
launcherDir,
callback,
- taskID,
+ taskId,
taskPid,
namespaces));
@@ -171,14 +171,14 @@ HealthCheckerProcess::HealthCheckerProcess(
const HealthCheck& _check,
const string& _launcherDir,
const lambda::function<void(const TaskHealthStatus&)>& _callback,
- const TaskID& _taskID,
+ const TaskID& _taskId,
Option<pid_t> _taskPid,
const vector<string>& _namespaces)
: ProcessBase(process::ID::generate("health-checker")),
check(_check),
launcherDir(_launcherDir),
healthUpdateCallback(_callback),
- taskID(_taskID),
+ taskId(_taskId),
taskPid(_taskPid),
namespaces(_namespaces),
consecutiveFailures(0),
@@ -241,7 +241,7 @@ void HealthCheckerProcess::failure(const string& message)
taskHealthStatus.set_healthy(false);
taskHealthStatus.set_consecutive_failures(consecutiveFailures);
taskHealthStatus.set_kill_task(killTask);
- taskHealthStatus.mutable_task_id()->CopyFrom(taskID);
+ taskHealthStatus.mutable_task_id()->CopyFrom(taskId);
// We assume this is a local send, i.e. the health checker library
// is not used in a binary external to the executor and hence can
@@ -264,7 +264,7 @@ void HealthCheckerProcess::success()
if (initializing || consecutiveFailures > 0) {
TaskHealthStatus taskHealthStatus;
taskHealthStatus.set_healthy(true);
- taskHealthStatus.mutable_task_id()->CopyFrom(taskID);
+ taskHealthStatus.mutable_task_id()->CopyFrom(taskId);
healthUpdateCallback(taskHealthStatus);
initializing = false;
}
http://git-wip-us.apache.org/repos/asf/mesos/blob/636866c5/src/checks/health_checker.hpp
----------------------------------------------------------------------
diff --git a/src/checks/health_checker.hpp b/src/checks/health_checker.hpp
index 6e558f2..95da1ff 100644
--- a/src/checks/health_checker.hpp
+++ b/src/checks/health_checker.hpp
@@ -55,7 +55,7 @@ public:
* @param launcherDir A directory where Mesos helper binaries are located.
* @param callback A callback HealthChecker uses to send health status
* updates to its owner (usually an executor).
- * @param taskID The TaskID of the target task.
+ * @param taskId The TaskID of the target task.
* @param taskPid The target task's pid used to enter the specified
* namespaces.
* @param namespaces The namespaces to enter prior performing a single health
@@ -69,7 +69,7 @@ public:
const HealthCheck& check,
const std::string& launcherDir,
const lambda::function<void(const TaskHealthStatus&)>& callback,
- const TaskID& taskID,
+ const TaskID& taskId,
Option<pid_t> taskPid,
const std::vector<std::string>& namespaces);
@@ -94,7 +94,7 @@ public:
const HealthCheck& _check,
const std::string& _launcherDir,
const lambda::function<void(const TaskHealthStatus&)>& _callback,
- const TaskID& _taskID,
+ const TaskID& _taskId,
Option<pid_t> _taskPid,
const std::vector<std::string>& _namespaces);
@@ -142,7 +142,7 @@ private:
const std::string launcherDir;
const lambda::function<void(const TaskHealthStatus&)> healthUpdateCallback;
- const TaskID taskID;
+ const TaskID taskId;
const Option<pid_t> taskPid;
const std::vector<std::string> namespaces;
Option<lambda::function<pid_t(const lambda::function<int()>&)>> clone;