Skip to content

Runtime Status

ZjzMisaka edited this page May 24, 2024 · 5 revisions

Many fields in the PowerPool class represent the current state of the thread pool, such as the number of active threads. [Get only]
Thread pool is running or not

bool PoolRunning;

[Get only]
Thread pool is stopping (when user call Stop(...)) or not.
When thread pool idled, PoolStopping becomes false.

bool PoolStopping;

[Get only]
Idle worker count

int IdleWorkerCount;

[Get only]
Waiting work count

int WaitingWorkCount;

[Get only]
ID list of waiting works

IEnumerable<string> WaitingWorkList;

[Get only]
Failed work count
Will be reset to zero when the thread pool starts again

int FailedWorkCount;

[Get only]
ID list of failed works
Will be cleared when the thread pool starts again

IEnumerable<string> FailedWorkList;

[Get only]
Running worker count

int RunningWorkerCount;

[Get only]
Alive worker count

int AliveWorkerCount;

[Get only]
Long running worker count

int LongRunningWorkerCount;

[Get only]
The total time spent in the queue (ms).
Will be reset when the thread pool starts again.

long TotalQueueTime;

[Get only]
The total time taken for execution (ms).
Will be reset when the thread pool starts again.

long TotalExecuteTime;

[Get only]
The average time spent in the queue (ms).
Will be reset when the thread pool starts again.

long AverageQueueTime;

[Get only]
The average time taken for execution (ms).
Will be reset when the thread pool starts again.

long AverageExecuteTime;

[Get only]
The average elapsed time from start queue to finish (ms).
Will be reset when the thread pool starts again.

long AverageElapsedTime;

[Get only]
The total elapsed time from start queue to finish (ms).
Will be reset when the thread pool starts again.

long TotalElapsedTime;