mirror of
https://github.com/postgres/postgres.git
synced 2025-07-09 22:41:56 +03:00
pgstat: stats collector references in comments.
Soon the stats collector will be no more, with statistics instead getting stored in shared memory. There are a lot of references to the stats collector in comments. This commit replaces most of these references with "cumulative statistics system", with the remaining ones getting replaced as part of subsequent commits. This is done separately from the - quite large - shared memory statistics patch to make review easier. Author: Andres Freund <andres@anarazel.de> Reviewed-By: Justin Pryzby <pryzby@telsasoft.com> Reviewed-By: Thomas Munro <thomas.munro@gmail.com> Reviewed-By: Kyotaro Horiguchi <horikyota.ntt@gmail.com> Discussion: https://postgr.es/m/20220303021600.hs34ghqcw6zcokdh@alap3.anarazel.de Discussion: https://postgr.es/m/20220308205351.2xcn6k4x5yivcxyd@alap3.anarazel.de
This commit is contained in:
@ -1089,8 +1089,8 @@ heapam_scan_analyze_next_tuple(TableScanDesc scan, TransactionId OldestXmin,
|
||||
* our own. In this case we should count and sample the row,
|
||||
* to accommodate users who load a table and analyze it in one
|
||||
* transaction. (pgstat_report_analyze has to adjust the
|
||||
* numbers we send to the stats collector to make this come
|
||||
* out right.)
|
||||
* numbers we report to the cumulative stats system to make
|
||||
* this come out right.)
|
||||
*/
|
||||
if (TransactionIdIsCurrentTransactionId(HeapTupleHeaderGetXmin(targtuple->t_data)))
|
||||
{
|
||||
|
@ -609,9 +609,9 @@ heap_vacuum_rel(Relation rel, VacuumParams *params,
|
||||
&frozenxid_updated, &minmulti_updated, false);
|
||||
|
||||
/*
|
||||
* Report results to the stats collector, too.
|
||||
* Report results to the cumulative stats system, too.
|
||||
*
|
||||
* Deliberately avoid telling the stats collector about LP_DEAD items that
|
||||
* Deliberately avoid telling the stats system about LP_DEAD items that
|
||||
* remain in the table due to VACUUM bypassing index and heap vacuuming.
|
||||
* ANALYZE will consider the remaining LP_DEAD items to be dead "tuples".
|
||||
* It seems like a good idea to err on the side of not vacuuming again too
|
||||
@ -2228,10 +2228,10 @@ lazy_vacuum(LVRelState *vacrel)
|
||||
* dead_items space is not CPU cache resident.
|
||||
*
|
||||
* We don't take any special steps to remember the LP_DEAD items (such
|
||||
* as counting them in our final report to the stats collector) when
|
||||
* as counting them in our final update to the stats system) when
|
||||
* the optimization is applied. Though the accounting used in
|
||||
* analyze.c's acquire_sample_rows() will recognize the same LP_DEAD
|
||||
* items as dead rows in its own stats collector report, that's okay.
|
||||
* items as dead rows in its own stats report, that's okay.
|
||||
* The discrepancy should be negligible. If this optimization is ever
|
||||
* expanded to cover more cases then this may need to be reconsidered.
|
||||
*/
|
||||
|
Reference in New Issue
Block a user