@@ -355,6 +355,7 @@ lazy_vacuum_rel(Relation onerel, int options, VacuumParams *params,
355
355
params -> log_min_duration ))
356
356
{
357
357
StringInfoData buf ;
358
+ char * msgfmt ;
358
359
359
360
TimestampDifference (starttime , endtime , & secs , & usecs );
360
361
@@ -373,7 +374,11 @@ lazy_vacuum_rel(Relation onerel, int options, VacuumParams *params,
373
374
* emitting individual parts of the message when not applicable.
374
375
*/
375
376
initStringInfo (& buf );
376
- appendStringInfo (& buf , _ ("automatic vacuum of table \"%s.%s.%s\": index scans: %d\n" ),
377
+ if (aggressive )
378
+ msgfmt = _ ("automatic aggressive vacuum of table \"%s.%s.%s\": index scans: %d\n" );
379
+ else
380
+ msgfmt = _ ("automatic vacuum of table \"%s.%s.%s\": index scans: %d\n" );
381
+ appendStringInfo (& buf , msgfmt ,
377
382
get_database_name (MyDatabaseId ),
378
383
get_namespace_name (RelationGetNamespace (onerel )),
379
384
RelationGetRelationName (onerel ),
@@ -486,10 +491,16 @@ lazy_scan_heap(Relation onerel, int options, LVRelStats *vacrelstats,
486
491
pg_rusage_init (& ru0 );
487
492
488
493
relname = RelationGetRelationName (onerel );
489
- ereport (elevel ,
490
- (errmsg ("vacuuming \"%s.%s\"" ,
491
- get_namespace_name (RelationGetNamespace (onerel )),
492
- relname )));
494
+ if (aggressive )
495
+ ereport (elevel ,
496
+ (errmsg ("aggressively vacuuming \"%s.%s\"" ,
497
+ get_namespace_name (RelationGetNamespace (onerel )),
498
+ relname )));
499
+ else
500
+ ereport (elevel ,
501
+ (errmsg ("vacuuming \"%s.%s\"" ,
502
+ get_namespace_name (RelationGetNamespace (onerel )),
503
+ relname )));
493
504
494
505
empty_pages = vacuumed_pages = 0 ;
495
506
num_tuples = tups_vacuumed = nkeep = nunused = 0 ;
0 commit comments