Re: review: FDW API - Mailing list pgsql-hackers

From Tom Lane
Subject Re: review: FDW API
Date
Msg-id 14451.1298060167@sss.pgh.pa.us
Whole thread Raw
In response to Re: review: FDW API  (Heikki Linnakangas <heikki.linnakangas@enterprisedb.com>)
Responses Re: review: FDW API  (Heikki Linnakangas <heikki.linnakangas@enterprisedb.com>)
List pgsql-hackers
Heikki Linnakangas <heikki.linnakangas@enterprisedb.com> writes:
> Another version, rebased against master branch and with a bunch of small 
> cosmetic fixes.

> I guess this is as good as this is going to get for 9.1.

This is *badly* in need of another cleanup pass; it's full of typos,
contradictory comments, #ifdef NOT_USED stuff, etc etc.  And the
documentation is really inadequate.  If you're out of energy to go
over it, I guess I should step up.

Question after first look: what is the motivation for passing
estate->es_param_list_info to BeginScan?  AFAICS, even if there is a
reason for that function to need that, it isn't receiving any info that
would be sufficient to let it know what's in there.  What seems more
likely to be useful is to pass in the EState pointer, as for example
being able to look at es_query_cxt seems like a good idea.

BTW, I see no particularly good reason to let the FDW omit ReScan.
If it wants to implement that as end-and-begin, it can do so internally.
It would be a lot clearer to just insist that all the function pointers
be valid, as indeed some (not all) of the comments say already.
        regards, tom lane


pgsql-hackers by date:

Previous
From: Alvaro Herrera
Date:
Subject: Re: Snapshot synchronization, again...
Next
From: Dimitri Fontaine
Date:
Subject: Re: contrib loose ends: 9.0 to 9.1 incompatibilities