git.iko.soy/typeable/postgresql-simple
on master help sign in
Clarify loImport/transaction issue in docs

As it turns out, c_lo_creat, etc. are just wrappers around PQfn to the corresponsing server-side functions. Also, there is no non-blocking variant of PQfn in libpq, though a protocol-level client could certainly support fast-path calls with a non-blocking implementation. Thus as postgresql-simple moves to a non-blocking implementation underneath the library, it will make sense to eventually abandon the large object binding in postgresql-libpq in favor of non-blocking calls to execParams.

commit72a65f8d9d1ae215dae755ef00ce863e66498b6b authorLeon P Smith <leon@melding-monads.com> dateMon 5 Aug 2013, 10:38 (13 years ago) parent847f844
1 file changed+5−2
src/Database/PostgreSQL/Simple/LargeObjects.hs+5−2
src/Database/PostgreSQL/Simple/LargeObjects.hs+5−2
@@ -12,8 +12,11 @@
1212--
1313-- Note that Large Object File Descriptors are only valid within a single
1414-- database transaction, so if you are interested in using anything beyond
15−-- 'loCreat', 'loImport', 'loExport', and 'loUnlink', you will need to run
16−-- the entire sequence of functions in a transaction.
15+-- 'loCreat', 'loCreate', and 'loUnlink', you will need to run the entire
16+-- sequence of functions in a transaction. As 'loImport' and 'loExport'
17+-- are simply C functions that call 'loCreat', 'loOpen', 'loRead', and
18+-- 'loWrite', and do not perform any transaction handling themselves,
19+-- they also need to be wrapped in an explicit transaction.
1720--
1821-----------------------------------------------------------------------------
1922