Additional logging for blocked thread pools.

This commit is contained in:
Greyson Parrelli 2021-10-22 20:48:55 -04:00
parent 7d49c77d1a
commit 8fcce9fba5

View file

@ -60,6 +60,13 @@ class DeadlockDetector(private val handler: Handler, private val pollingInterval
val executor: ThreadPoolExecutor = executorInfo.executor as ThreadPoolExecutor
Log.w(TAG, buildLogString("Found a full executor! ${executor.activeCount}/${executor.corePoolSize} threads active with ${executor.queue.size} tasks queued.", fullMap))
val runnableStringBuilder = StringBuilder()
executor.queue.forEach { runnable ->
runnableStringBuilder.append(runnable.toString()).append("\n")
}
Log.w(TAG, "Queue:\n${runnableStringBuilder}")
}
}