libpq: Exact meaning of 'thread-safe'? - Mailing list pgsql-interfaces

From Florian Weimer
Subject libpq: Exact meaning of 'thread-safe'?
Date
Msg-id tgae8h546f.fsf@mercury.rus.uni-stuttgart.de
Whole thread Raw
List pgsql-interfaces
From the documentation:

| libpq is thread-safe as of Postgres 7.0, so long as no two threads
| attempt to manipulate the same PGconn object at the same time. In
| particular, you can't issue concurrent queries from different threads
| through the same connection object. (If you need to run concurrent
| queries, start up multiple connections.)

Is it safe to perform sequential queries from different threads to the
same object?  (On some systems, the process ID changes from thread to
thread, and this could have some side effects.)

Is it safe to assume that the accessor functions for connection
objects are task-safe and will remain it?

-- 
Florian Weimer                       Florian.Weimer@RUS.Uni-Stuttgart.DE
University of Stuttgart           http://cert.uni-stuttgart.de/
RUS-CERT                          +49-711-685-5973/fax +49-711-685-5898


pgsql-interfaces by date:

Previous
From: "Stathy Touloumis"
Date:
Subject: Perl DBD Driver
Next
From:
Date:
Subject: Re: Postgres ODBC