This is an automated email from the ASF dual-hosted git repository.
zhouky pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/incubator-celeborn.git
The following commit(s) were added to refs/heads/main by this push:
new 5a3d3977 [CELEBORN-130] Correct CommitFilesTime metric (#1073)
5a3d3977 is described below
commit 5a3d397781db57a7381e2ba648eef04b0aa6e505
Author: Keyong Zhou <[email protected]>
AuthorDate: Tue Dec 13 20:02:21 2022 +0800
[CELEBORN-130] Correct CommitFilesTime metric (#1073)
---
.../celeborn/service/deploy/worker/Controller.scala | 19 ++++++++++---------
1 file changed, 10 insertions(+), 9 deletions(-)
diff --git
a/worker/src/main/scala/org/apache/celeborn/service/deploy/worker/Controller.scala
b/worker/src/main/scala/org/apache/celeborn/service/deploy/worker/Controller.scala
index 4290db04..8e2faffe 100644
---
a/worker/src/main/scala/org/apache/celeborn/service/deploy/worker/Controller.scala
+++
b/worker/src/main/scala/org/apache/celeborn/service/deploy/worker/Controller.scala
@@ -108,15 +108,13 @@ private[deploy] class Controller(
case CommitFiles(applicationId, shuffleId, masterIds, slaveIds,
mapAttempts, epoch) =>
val shuffleKey = Utils.makeShuffleKey(applicationId, shuffleId)
- workerSource.sample(WorkerSource.CommitFilesTime, shuffleKey) {
- logDebug(s"Received CommitFiles request, $shuffleKey, master files" +
- s" ${masterIds.asScala.mkString(",")}; slave files
${slaveIds.asScala.mkString(",")}.")
- val commitFilesTimeMs = Utils.timeIt({
- handleCommitFiles(context, shuffleKey, masterIds, slaveIds,
mapAttempts, epoch)
- })
- logDebug(s"Done processed CommitFiles request with shuffleKey
$shuffleKey, in " +
- s"$commitFilesTimeMs ms.")
- }
+ logDebug(s"Received CommitFiles request, $shuffleKey, master files" +
+ s" ${masterIds.asScala.mkString(",")}; slave files
${slaveIds.asScala.mkString(",")}.")
+ val commitFilesTimeMs = Utils.timeIt({
+ handleCommitFiles(context, shuffleKey, masterIds, slaveIds,
mapAttempts, epoch)
+ })
+ logDebug(s"Done processed CommitFiles request with shuffleKey
$shuffleKey, in " +
+ s"$commitFilesTimeMs ms.")
case GetWorkerInfos =>
handleGetWorkerInfos(context)
@@ -380,6 +378,7 @@ private[deploy] class Controller(
} else {
logInfo(s"Start commitFiles for ${shuffleKey}")
commitInfo.status = CommitInfo.COMMIT_INPROCESS
+ workerSource.startTimer(WorkerSource.CommitFilesTime, shuffleKey)
}
}
@@ -498,6 +497,8 @@ private[deploy] class Controller(
commitInfo.status = CommitInfo.COMMIT_FINISHED
}
context.reply(response)
+
+ workerSource.stopTimer(WorkerSource.CommitFilesTime, shuffleKey)
}
if (future != null) {