23 Commits

Author SHA1 Message Date
Mitar
a4ca0917da Support large large objects.
Fixes #1865.
2024-01-15 08:50:55 -06:00
Jack Christensen
05440f9d3f Drastically increase allowed test times for potato CI
The context timeouts for tests are designed to give a better error
message when something hangs rather than the test just timing out.
Unfortunately, the potato CI frequently has some test or another
randomly take a long time. While the increased times are somewhat less
than optimal on a real computer, hopefully this will solve the
flickering CI.
2023-07-11 21:16:08 -05:00
Jack Christensen
83e50f21e8 Extract SkipCockroachDB to pgxtest 2022-04-02 10:35:13 -05:00
Jack Christensen
aad3d65e16 Initial restructure of simple protocol to query exec mode 2022-03-05 10:27:15 -06:00
Jack Christensen
72cc95e4dd Bump module version to v5 2021-12-11 13:29:03 -06:00
Jack Christensen
0e293b966c Finish import of pgconn 2021-12-04 14:06:57 -06:00
Jack Christensen
1dc7133a63 Simplify CockroachDB detection 2021-02-27 10:40:06 -06:00
Jack Christensen
909398127d Skip large objects tests for CockroackDB 2021-02-27 09:52:51 -06:00
Jack Christensen
9cb58fc969 Fix large objects functionality when PreferSimpleProtocol = true
fixes #651
2019-12-27 11:17:12 -06:00
Jack Christensen
c3e41872a8 Resplit Begin and BeginEx
This is in preparation for a Begin / Tx interface that will similate
nested transactions with savepoints.

In addition, this passes the TxOptions struct by value and thereby
removes an allocation.
2019-08-17 15:53:55 -05:00
Jack Christensen
03abfc6452 Large objects use context 2019-05-11 11:49:59 -05:00
Jack Christensen
79f49ce300 Convert large objects to prepared statements
This allows removing semi-obsolete fastpath interface support. See
https://www.postgresql.org/docs/current/libpq-fastpath.html. This also
simplifies introducing context support.
2019-05-11 11:36:38 -05:00
Jack Christensen
2263521f70 Only have a single Begin transaction method 2019-04-24 13:35:27 -05:00
Jack Christensen
efb333df6b Fix go modules
Wow. This is fun. Sure is easy to get modules wrong when upgrading a v2+
project.
2019-04-20 17:41:08 -05:00
Jack Christensen
ae73ca2da1 Update to more effecient pgconn 2019-04-19 15:55:45 -05:00
Jack Christensen
54c6ddc2f0 Commit and Rollback take context
Remove Ex versions.
2019-04-10 12:22:12 -05:00
Jack Christensen
7718ee6207 Remove Ex versions of Query and QueryRow
Always require context and prepend options to arguments if necessary.
2019-04-10 12:12:22 -05:00
Jack Christensen
858d00788a Use extracted packages with Go modules 2019-04-05 10:59:47 -05:00
Jack Christensen
378ccb8945 PG error type is *pgconn.PgError 2018-12-31 17:46:56 -06:00
Jack Christensen
c672c0d595 Use environment variables for test configuration 2018-12-30 21:52:33 -06:00
Jack Christensen
b3c8a73dc7 Restructure connect process
- Moved lots of connection logic to pgconn from pgx
- Extracted pgpassfile package
2018-12-30 16:55:56 -06:00
Jack Christensen
b72ebe050f Fix fastpath / largeobjects query counting
fastpath.Call was not incrementing pendingReadyForQueryCount when it
sent a function call. But it was being decremented when the function
call was finished and the server sent the ready for query message. This
caused pendingReadyForQueryCount to go negative. This meant that any
subsequent activity that depended on ensureConnectionReadyForQuery would
not operate correctly because the connection would be considered ready
before it had read all previous data off the wire.

fixes #403
2018-03-31 11:11:48 -05:00
Jonathan Rudenberg
0176e3ccc0 Implement large object support
This patch implements large object support as described in
http://www.postgresql.org/docs/current/static/largeobjects.html
2015-01-01 22:01:01 -05:00