This extension for LightDB add lt_stat_activity view.
This extension provides the lt_stat_activity view, which contains all pg_stat_activity
fields
and adds the query_id field, which is consistent with the query_id in pg_stat_statements.
When waiting events occur, lt_stat_activity and pg_stat_statements can be used to analyze together by query_id.
lt_stat_activity extension depends on extension lt_stat_statements.
you must add lt_stat_activity in shared_preload_libraries, and restart server is needed after modify shared_preload_libraries.
# lightdb.conf shared_preload_libraries = 'lt_stat_statements,lt_stat_activity' lightdb@postgres=# CREATE EXTENSION lt_stat_statements; lightdb@postgres=# CREATE EXTENSION lt_stat_activity;
You can define extension parameters in lightdb.conf.
lt_stat_activity.track = top - default, track top level query.
lt_stat_activity.track = none - query_id field in lt_stat_activity is always null.