You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@celeborn.apache.org by "FMX (via GitHub)" <gi...@apache.org> on 2023/04/12 06:30:47 UTC

[GitHub] [incubator-celeborn] FMX commented on a diff in pull request #1415: [CELEBORN-511][IMPROVE] Move onTrim tag to StorageManager to avoid frequent trim action

FMX commented on code in PR #1415:
URL: https://github.com/apache/incubator-celeborn/pull/1415#discussion_r1163679621


##########
worker/src/main/scala/org/apache/celeborn/service/deploy/worker/storage/StorageManager.scala:
##########
@@ -677,11 +678,18 @@ final private[worker] class StorageManager(conf: CelebornConf, workerSource: Abs
   override def onResume(moduleName: String): Unit = {}
 
   override def onTrim(): Unit = {
-    actionService.submit(new Runnable {
-      override def run(): Unit = {
-        flushFileWriters()
-      }
-    })
+    if (trimInProcess.compareAndSet(false, true)) {

Review Comment:
   ChannelLimiter's onTrim isn't blocking operation.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@celeborn.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org