Re: postgres_fdw bug in 9.6
Tom Lane <tgl@sss.pgh.pa.us>
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Etsuro Fujita <fujita.etsuro@lab.ntt.co.jp>
Cc: Robert Haas <robertmhaas@gmail.com>, Jeff Janes <jeff.janes@gmail.com>,
David Steele <david@pgmasters.net>,
Ashutosh Bapat <ashutosh.bapat@enterprisedb.com>,
pgsql-hackers <pgsql-hackers@postgresql.org>
Date: 2017-08-29T21:14:31Z
Lists: pgsql-hackers
Etsuro Fujita <fujita.etsuro@lab.ntt.co.jp> writes: > [ epqpath-for-foreignjoin-11.patch ] I started looking at this. I've not yet wrapped my head around what CreateLocalJoinPath() is doing, but I noted that Robert's concerns about ABI breakage in the back branches would not be very difficult to satisfy. What we'd need to do is (1) In the back-branch patch, add the new fields of JoinPathExtraData at the end, rather than in their more natural locations. This should avoid any ABI break for uses of that struct, since there's no reason why an FDW would be creating its own variables of that type rather than just using what the core code passes it. (2) In the back branches, just leave GetExistingLocalJoinPath in place rather than deleting it. Existing FDWs would still be subject to the bug until they were updated, but given how hard it is to trigger, that doesn't seem like a huge problem. A variant of (2) is to install a hack fix in GetExistingLocalJoinPath rather than leaving it unchanged. I'm not very excited about that though; it doesn't seem unlikely that we might introduce new bugs that way, and it would certainly be a distraction from getting the real fix finished. We'd definitely need to do things that way in 9.6. I'm not quite sure whether it's too late to adopt the clean solution in v10. regards, tom lane
Commits
-
Fix test case for 'outer pathkeys do not match mergeclauses' fix.
- d397f558d555 9.6.7 landed
- 92123c6ea212 10.2 landed
- 99f6a17dd62a 11.0 landed
-
postgres_fdw: Avoid 'outer pathkeys do not match mergeclauses' error.
- 4a81c022975e 9.6.7 landed
- 3f05a30b50a7 10.2 landed
- 4bbf6edfbd5d 11.0 landed
-
postgres_fdw: Consider foreign joining and foreign sorting together.
- aa09cd242fa7 9.6.0 cited
-
Allow foreign and custom joins to handle EvalPlanQual rechecks.
- 385f337c9f39 9.6.0 cited
-
Allow FDWs to push down quals without breaking EvalPlanQual rechecks.
- 5fc4c26db512 9.6.0 cited