Re: insert/update performance
От | Jinhua Luo |
---|---|
Тема | Re: insert/update performance |
Дата | |
Msg-id | CAAc9rOywTRm4CSAGST8w5q5xqou2HX7E+r1AL8poBPprb1PL3Q@mail.gmail.com обсуждение исходный текст |
Ответ на | Re: insert/update performance (Jinhua Luo <luajit.io@gmail.com>) |
Ответы |
Re: insert/update performance
|
Список | pgsql-hackers |
Ok, I found the vaccum output is correct. I check the codes of lazy_scan_heap(), the rows to be removed are reported in two parts, one is return of heap_page_prune(), the other is ItemIdIsDead() when scanning the page. After scanning all pages of the relation, those rows would be clean up in: if (vacrelstats->num_dead_tuples > 0) { ... lazy_vacuum_heap() ... } It would then output > INFO: "test": removed 6 row versions in 1 pages The number of rows is correct. But what kind of rows would satisfy heap_page_prune() and what would not? In my case all updates are doing the same thing (there is no HOT updates, obviously), but why some updated rows are reported by heap_page_prune() but the others are not? And it's also a random issue. That means sometimes heap_page_prune() would report all removable rows, and sometimes it reports no rows. Regards, Jinhua Luo
В списке pgsql-hackers по дате отправления: