Skip to content

pg_stat_resqueues

Note The pg_stat_resqueues view is valid only when resource queue-based resource management is active.

The pg_stat_resqueues view allows administrators to view metrics about a resource queue's workload over time. To allow statistics to be collected for this view, you must enable the stats_queue_level server configuration parameter on the WarehousePG coordinator instance. Enabling the collection of these metrics does incur a small performance penalty, as each statement submitted through a resource queue must be logged in the system catalog tables.

columntypereferencesdescription
queueidoidThe OID of the resource queue.
queuenamenameThe name of the resource queue.
n_queries_execbigintNumber of queries submitted for execution from this resource queue.
n_queries_waitbigintNumber of queries submitted to this resource queue that had to wait before they could run.
elapsed_execbigintTotal elapsed execution time for statements submitted through this resource queue.
elapsed_waitbigintTotal elapsed time that statements submitted through this resource queue had to wait before they were run.

Parent topic: System Catalogs Definitions