pgsql: vacuumdb: enable parallel mode

Started by Alvaro Herreraover 11 years ago3 messagescomitters
Jump to latest
#1Alvaro Herrera
alvherre@2ndquadrant.com

vacuumdb: enable parallel mode

This mode allows vacuumdb to open several server connections to vacuum
or analyze several tables simultaneously.

Author: Dilip Kumar. Some reworking by Álvaro Herrera
Reviewed by: Jeff Janes, Amit Kapila, Magnus Hagander, Andres Freund

Branch
------
master

Details
-------
http://git.postgresql.org/pg/commitdiff/a17923204736d8842eade3517d6a8ee81290fca4

Modified Files
--------------
doc/src/sgml/ref/vacuumdb.sgml | 24 ++
src/bin/pg_dump/parallel.c | 2 +-
src/bin/scripts/common.c | 23 +-
src/bin/scripts/common.h | 6 +
src/bin/scripts/vacuumdb.c | 797 ++++++++++++++++++++++++++++++++--------
5 files changed, 691 insertions(+), 161 deletions(-)

--
Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-committers

#2Michael Paquier
michael@paquier.xyz
In reply to: Alvaro Herrera (#1)
Re: pgsql: vacuumdb: enable parallel mode

On Sat, Jan 24, 2015 at 3:06 AM, Alvaro Herrera <alvherre@alvh.no-ip.org> wrote:

vacuumdb: enable parallel mode

This mode allows vacuumdb to open several server connections to vacuum
or analyze several tables simultaneously.

Coverity is still complaining about this block of code where the
return code of PQsendQuery() is not checked:
if (async)
{
if (echo)
printf("%s\n", sql);

PQsendQuery(conn, sql);
}
Could it be possible to get that fixed soon? Alvaro, attached is the
patch that you wrote to fix this stuff.
Regards,
--
Michael

Attachments:

vacuumdb-pqsendq.patchtext/x-patch; charset=US-ASCII; name=vacuumdb-pqsendq.patchDownload+9-2
#3Alvaro Herrera
alvherre@2ndquadrant.com
In reply to: Michael Paquier (#2)
Re: pgsql: vacuumdb: enable parallel mode

Michael Paquier wrote:

On Sat, Jan 24, 2015 at 3:06 AM, Alvaro Herrera <alvherre@alvh.no-ip.org> wrote:

vacuumdb: enable parallel mode

This mode allows vacuumdb to open several server connections to vacuum
or analyze several tables simultaneously.

Coverity is still complaining about this block of code where the
return code of PQsendQuery() is not checked:

Should be fixed now, thanks.

--
�lvaro Herrera http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services

--
Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-committers