Re: [HACKERS] GSOC'17 project introduction: Parallel COPY execution with errors handling

From: Michael Paquier <michael(dot)paquier(at)gmail(dot)com>
To: Alex K <kondratov(dot)aleksey(at)gmail(dot)com>
Cc: "pgsql-hackers(at)postgresql(dot)org" <pgsql-hackers(at)postgresql(dot)org>, Peter Geoghegan <pg(at)bowt(dot)ie>, Stas Kelvich <s(dot)kelvich(at)postgrespro(dot)ru>, Robert Haas <robertmhaas(at)gmail(dot)com>, Nicolas Barbier <nicolas(dot)barbier(at)gmail(dot)com>, Alexander Korotkov <a(dot)korotkov(at)postgrespro(dot)ru>, Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>, Craig Ringer <craig(at)2ndquadrant(dot)com>, Alvaro Herrera <alvherre(at)alvh(dot)no-ip(dot)org>, Anastasia Lubennikova <lubennikovaAV(at)gmail(dot)com>
Subject: Re: [HACKERS] GSOC'17 project introduction: Parallel COPY execution with errors handling
Date: 2017-11-30 04:31:48
Message-ID: CAB7nPqQ5ULbitq8tuecDm3cpB-4zw5fdBhMiX0uS=-NLO=y2rA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Wed, Jun 21, 2017 at 11:37 PM, Alex K <kondratov(dot)aleksey(at)gmail(dot)com> wrote:
>> On 16 Jun 2017, at 21:30, Alexey Kondratov <kondratov(dot)aleksey(at)gmail(dot)com> wrote:
>
>> > On 13 Jun 2017, at 01:44, Peter Geoghegan <pg(at)bowt(dot)ie> wrote:
>
>
>> > Speculative insertion has the following special entry points to
>> > heapam.c and execIndexing.c, currently only called within
>> > nodeModifyTable.c
>
>> > Offhand, it doesn't seem like it would be that hard to teach another
>> > heap_insert() caller the same tricks.
>
>
>> I went through the nodeModifyTable.c code and it seems not to be so
>> difficult to do the same inside COPY.
>
> After a more precise look, I have figured out at least one difficulty, COPY
> and INSERT follow the different execution paths: INSERT goes through
> the Planner, while COPY does not. It leads to the absence of some required
> attributes like arbiterIndexes, which are available during INSERT via
> PlanState/ModifyTableState. Probably it is possible to get the same in the
> COPY, but it is not clear for me how.
>
> Anyway, adding of the 'speculative insertion' into the COPY is worth of a
> separated patch; and I would be glad to try implementing it.
>
> In the same time I have prepared a complete working patch with:
>
> - ignoring of the input data formatting errors
> - IGNORE_ERRORS parameter in the COPY options
> - updated regression tests
>
> Please, find the patch attached or check the web UI diff on GitHub as always:
> https://github.com/ololobus/postgres/pull/1/files

"git diff master --check" complains heavily, and the patch does not
apply anymore. The last patch is 5-month old as well, so I am marking
the patch as returned with feedback.
--
Michael

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Michael Paquier 2017-11-30 04:34:39 Re: [HACKERS] INSERT .. ON CONFLICT DO SELECT [FOR ..]
Previous Message Michael Paquier 2017-11-30 04:28:28 Re: [HACKERS] [PROPOSAL] Temporal query processing with range types