System.Threading.TThreadPoolStats

From RAD Studio API Documentation
Jump to: navigation, search

Delphi

TThreadPoolStats = record

C++

struct DECLSPEC_DRECORD TThreadPoolStats
{
private:
    int FWorkerThreadCount;
    int FMinLimitWorkerThreadCount;
    int FMaxLimitWorkerThreadCount;
    int FIdleWorkerThreadCount;
    int FQueuedRequestCount;
    int FRetiredWorkerThreadCount;
    int FAverageCPUUsage;
    int FCurrentCPUUsage;
    int FThreadSuspended;
    unsigned __int64 FLastSuspendTick;
    unsigned __int64 FLastThreadCreationTick;
    int FLastQueuedRequestCount;
    static TThreadPoolStats __fastcall GetCurrent();
    static TThreadPoolStats __fastcall GetDefault();
public:
    __property int WorkerThreadCount = {read=FWorkerThreadCount};
    __property int MinLimitWorkerThreadCount = {read=FMinLimitWorkerThreadCount};
    __property int MaxLimitWorkerThreadCount = {read=FMaxLimitWorkerThreadCount};
    __property int IdleWorkerThreadCount = {read=FIdleWorkerThreadCount};
    __property int QueuedRequestCount = {read=FQueuedRequestCount};
    __property int RetiredWorkerThreadCount = {read=FRetiredWorkerThreadCount};
    __property int AverageCPUUsage = {read=FAverageCPUUsage};
    __property int CurrentCPUUsage = {read=FCurrentCPUUsage};
    __property int ThreadSuspended = {read=FThreadSuspended};
    __property unsigned __int64 LastSuspendTick = {read=FLastSuspendTick};
    __property unsigned __int64 LastThreadCreationTick = {read=FLastThreadCreationTick};
    __property int LastQueuedRequestCount = {read=FLastQueuedRequestCount};
    static TThreadPoolStats __fastcall Get(TThreadPool* const Pool);
    /* static */ __property TThreadPoolStats Current = {read=GetCurrent};
    /* static */ __property TThreadPoolStats Default = {read=GetDefault};
};

Properties

Type Visibility Source Unit Parent
record
struct
public
System.Threading.pas
System.Threading.hpp
System.Threading System.Threading

Description

This record is used to grab a "snapshot" of a threadpool's internal state.

This is useful in peering into the inner workings of a threadpool for diagnostic purposes. This snapshot may not be strictly accurate because the accessed threadpool continues to run.

Do not depend on this structure for anything other than simply hinting at the internal state.