Andres Freund <and...@2ndquadrant.com> writes:
> On 2013-11-20 11:08:33 -0500, Tom Lane wrote:
>> Andres Freund <and...@2ndquadrant.com> writes:
>>> Something like PQstartSingleUser(dsn) returning a established connection
>>> seems better to me.

>> That just pushes the problem up a level --- how are you going to tell
>> psql, pg_dump, or other programs that they should do that?

> An explicit parameter. A program imo explicitly needs to be aware that a
> PQconnect() suddenly starts forking and such. What if it is using
> threads? What if it has it's own SIGCHLD handler for other business it's
> doing?

Hm.  That's a fair point.  I don't especially buy your other argument
about additional connections --- if the program tries such, they'll
just fail, which can hardly be said to be unexpected.  But it's reasonable
to worry that programs might need to be aware that they now have a child
process.  (It occurs to me that we'll need to provide a way to get the
PID of the child, too.)

                        regards, tom lane


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

Reply via email to