Add statistics for INSERT/UPDATE/DELETE etc. SQL commands.
We already allow to collect stats for SELECT, but it would be useful
to collect stats for other types of SQL commands. APIs to fetch stats
data is also added. No UI is added yet. Currently, any SQL commands
(besides SELECT/INSERT/UPDATE/DELETE) other than:
case(T_CheckPointStmt):
case(T_DeallocateStmt):
case(T_DiscardStmt):
case(T_ExecuteStmt):
case(T_ExplainStmt):
case(T_ListenStmt):
case(T_LoadStmt):
case(T_LockStmt):
case(T_NotifyStmt):
case(T_PrepareStmt):
case(T_TransactionStmt):
case(T_UnlistenStmt):
case(T_VacuumStmt):
case(T_VariableSetStmt):
case(T_VariableShowStmt):
are counted as DDL commands.
Discussion: https://www.pgpool.net/pipermail/pgpool-hackers/2020-July/003754.html