Is there any way to monitor the task queue of scala.concurrent.ExecutionContext.Implicits.global
? ie., see the number of tasks waiting for a thread to be released?
Asked
Active
Viewed 626 times
0

RAGHHURAAMM
- 1,099
- 7
- 15

Chris W.
- 2,266
- 20
- 40
1 Answers
1
JDK comes along with jconsole
and jmc
. You can use them to see thread usage. You can see,
- Thread state,
- blocked count
- thread allocated bytes etc
scala implicit threads name start with scala-execution-context-global-n
.
jmc
screenshot:
Related: what is the best way to get the number of futures running in background in an execution context?

prayagupa
- 30,204
- 14
- 155
- 192
-
1Thanks, lead me to the solution. I used jstack -l which needs no front end and the actual naming of the threads is "ForkJoinPool-x-worker-y" – Chris W. Oct 11 '18 at 12:21
-
1The question was about tasks - i.e. Futures. How does information about threads help count the number of pending tasks? – pdxleif Sep 16 '21 at 04:35