I need to display all running tasks to the user. Every task is associated with a specific id. To execute tasks I use a ThreadPoolExecutor
. Each thread has the same name as the id.
So I just have to get list of all running and and waiting in queue threads. And then get there names and display them.
How can I do this?