postgresql/contrib/dblink
Joe Conway c444868389 Protect dblink from invalid options when using postgres_fdw server
When dblink uses a postgres_fdw server name for its connection, it
is possible for the connection to have options that are invalid
with dblink (e.g. "updatable"). The recommended way to avoid this
problem is to use dblink_fdw servers instead. However there are use
cases for using postgres_fdw, and possibly other FDWs, for dblink
connection options, therefore protect against trying to use any
options that do not apply by using is_valid_dblink_option() when
building the connection string from the options.

Back-patch to 9.3. Although 9.2 supports FDWs for connection info,
is_valid_dblink_option() did not yet exist, and neither did
postgres_fdw, at least in the postgres source tree. Given the lack
of previous complaints, fixing that seems too invasive/not worth it.

Author: Corey Huinker
Reviewed-By: Joe Conway
Discussion: https://postgr.es/m/CADkLM%3DfWyXVEyYcqbcRnxcHutkP45UHU9WD7XpdZaMfe7S%3DRwA%40mail.gmail.com
2016-12-22 09:20:35 -08:00
..
expected Establish conventions about global object names used in regression tests. 2016-07-17 18:42:43 -04:00
input
output
sql Establish conventions about global object names used in regression tests. 2016-07-17 18:42:43 -04:00
.gitignore
dblink--1.0--1.1.sql
dblink--1.1--1.2.sql Fix parallel-safety markings for contrib/dblink. 2016-06-17 23:08:21 -04:00
dblink--1.2.sql Fix parallel-safety markings for contrib/dblink. 2016-06-17 23:08:21 -04:00
dblink--unpackaged--1.0.sql
dblink.c Protect dblink from invalid options when using postgres_fdw server 2016-12-22 09:20:35 -08:00
dblink.control Update dblink extension for parallel query. 2016-06-17 15:18:44 -04:00
dblink.h Remove unnecessary prototypes 2016-09-30 14:04:16 -04:00
Makefile Update dblink extension for parallel query. 2016-06-17 15:18:44 -04:00
pg_service.conf