diff --git a/platform/testFramework/src/com/intellij/testFramework/ThreadTracker.java b/platform/testFramework/src/com/intellij/testFramework/ThreadTracker.java index 298338d8e58b..5ed6d1a04b94 100644 --- a/platform/testFramework/src/com/intellij/testFramework/ThreadTracker.java +++ b/platform/testFramework/src/com/intellij/testFramework/ThreadTracker.java @@ -15,6 +15,7 @@ */ package com.intellij.testFramework; +import com.intellij.execution.process.ProcessIOExecutorService; import com.intellij.openapi.Disposable; import com.intellij.openapi.application.ApplicationManager; import com.intellij.openapi.project.ProjectManager; @@ -92,7 +93,10 @@ public class ThreadTracker { wellKnownOffenders.add("VM Thread"); wellKnownOffenders.add("YJPAgent-Telemetry"); - longRunningThreadCreated(ApplicationManager.getApplication(), "Periodic tasks thread", "ApplicationImpl pooled thread"); + longRunningThreadCreated(ApplicationManager.getApplication(), + "Periodic tasks thread", + "ApplicationImpl pooled thread ", + ProcessIOExecutorService.POOLED_THREAD_PREFIX); } // marks Thread with this name as long-running, which should be ignored from the thread-leaking checks diff --git a/platform/util/src/com/intellij/execution/process/ProcessIOExecutorService.java b/platform/util/src/com/intellij/execution/process/ProcessIOExecutorService.java index c9425c581ebe..fbeb01979199 100644 --- a/platform/util/src/com/intellij/execution/process/ProcessIOExecutorService.java +++ b/platform/util/src/com/intellij/execution/process/ProcessIOExecutorService.java @@ -16,6 +16,7 @@ import java.util.concurrent.atomic.AtomicInteger; * @author peter */ public class ProcessIOExecutorService extends ThreadPoolExecutor { + public static final String POOLED_THREAD_PREFIX = "Process I/O pool "; public static final ProcessIOExecutorService INSTANCE = new ProcessIOExecutorService(); /** @@ -30,7 +31,7 @@ public class ProcessIOExecutorService extends ThreadPoolExecutor { @NotNull @Override public Thread newThread(@NotNull final Runnable r) { - Thread thread = new Thread(r, "Process I/O pool " + counter.incrementAndGet()); + Thread thread = new Thread(r, POOLED_THREAD_PREFIX + counter.incrementAndGet()); thread.setPriority(Thread.NORM_PRIORITY - 1); return thread; }