summaryrefslogtreecommitdiff
path: root/src/backend/commands/analyze.c
diff options
context:
space:
mode:
authorPeter Geoghegan <pg@bowt.ie>2021-08-27 13:08:39 -0700
committerPeter Geoghegan <pg@bowt.ie>2021-08-27 13:08:39 -0700
commitfd134f374ef7a8cc0b2d878a92dfe2c7088e084b (patch)
tree44927b96eecac71bd0baeea0fbe855d5b33fd884 /src/backend/commands/analyze.c
parent3068e45799327298a3f4c22b03db2aa48e2ab0da (diff)
Reorder log_autovacuum_min_duration log output.
This order seems more natural. It starts with details that are particular to heap and index data structures, and ends with system-level costs incurred during the autovacuum worker's VACUUM/ANALYZE operation. Author: Peter Geoghegan <pg@bowt.ie> Discussion: https://postgr.es/m/CAH2-WzkzxK6ahA9xxsOftRtBX_R0swuHZsvo4QUbak1Bz7hb7Q@mail.gmail.com Backpatch: 14-, which enhanced the log output in various ways.
Diffstat (limited to 'src/backend/commands/analyze.c')
-rw-r--r--src/backend/commands/analyze.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/backend/commands/analyze.c b/src/backend/commands/analyze.c
index 8d7b38d1707..a17349bcd6c 100644
--- a/src/backend/commands/analyze.c
+++ b/src/backend/commands/analyze.c
@@ -777,12 +777,6 @@ do_analyze_rel(Relation onerel, VacuumParams *params,
get_database_name(MyDatabaseId),
get_namespace_name(RelationGetNamespace(onerel)),
RelationGetRelationName(onerel));
- appendStringInfo(&buf, _("buffer usage: %lld hits, %lld misses, %lld dirtied\n"),
- (long long) AnalyzePageHit,
- (long long) AnalyzePageMiss,
- (long long) AnalyzePageDirty);
- appendStringInfo(&buf, _("avg read rate: %.3f MB/s, avg write rate: %.3f MB/s\n"),
- read_rate, write_rate);
if (track_io_timing)
{
appendStringInfoString(&buf, _("I/O timings:"));
@@ -796,6 +790,12 @@ do_analyze_rel(Relation onerel, VacuumParams *params,
(double) (pgStatBlockWriteTime - startwritetime) / 1000);
appendStringInfoChar(&buf, '\n');
}
+ appendStringInfo(&buf, _("avg read rate: %.3f MB/s, avg write rate: %.3f MB/s\n"),
+ read_rate, write_rate);
+ appendStringInfo(&buf, _("buffer usage: %lld hits, %lld misses, %lld dirtied\n"),
+ (long long) AnalyzePageHit,
+ (long long) AnalyzePageMiss,
+ (long long) AnalyzePageDirty);
appendStringInfo(&buf, _("system usage: %s"), pg_rusage_show(&ru0));
ereport(LOG,