Peter Eisentraut wrote:
> Bruce Momjian wrote:
>>I have added this patch plus your later comments to the patch queue.
>
> The autovacuum process still uses libpq to send its queries, which is
> not the idea behind backend integration.
Actually, I intentionally had pg_autovacuum continue to use libpq based
Tom's advise. Please see this thread:
http://archives.postgresql.org/pgsql-hackers/2004-03/msg00931.php
And more specifically, these follow ups:
http://archives.postgresql.org/pgsql-hackers/2004-03/msg00989.php
http://archives.postgresql.org/pgsql-hackers/2004-03/msg00992.php
The short of it is that Tom felt having the autovac daemon continue to
use libpq keeps "autovac control code still at arms length from the backend"
To me the main benifit of having pg_autovacuum integrated in as a
backend process is not eliminating libpq from the process, but rather:
* access to GUC, elog (and other things)
* allows autovac to be started and shutdown by the backend based on a
GUC variable
* allows autovac to have it's own system table to maintain it's data
across restarts
* eventually should allow vacuum decisions to be based on factors beyond
the stats system (FSM etc...)
IMHO, the use of libpq is not a bug, it's a feature.
Thoughts?
Matthew