Releases: amphp/postgres
2.1.0
What's Changed
- Fixed type cast for
numeric
columns when using theext-pgsql
driver. The column value was being cast to a float, it is now cast to a string for parity with theext-pq
driver to retain value precision. (#66) - Added a parameter for the default transaction isolation to
PostgresConnectionPool
to set the default transaction level when constructing the pool.
Full Changelog: v2.0.0...v2.1.0
2.0.0
Stable release compatible with AMPHP v3 and fibers! 🎉
As with other libraries compatible with AMPHP v3, most cases of parameters or returns of Promise<ResolutionType>
have been replaced with ResolutionType
.
- Non-extension-specific classes and interfaces now are prefixed with
Postgres
to avoid collisions with similar names from other libraries. - Result sets now implement
Traversable
, allowing them to be used withforeach
to iterate over result rows. - Marked most classes as internal, leaving only interfaces and concrete implementations required to use the API or create a custom connector.
PostgresTransaction
now extendsPostgresLink
instead ofPostgresExecutor
to support nested transactions.- Removed
TimeoutConnector
in favor ofDefaultPostgresConnector
which has aCancellation
parameter onconnect()
which may be used with anAmp\TimeoutCancellation
. - Removed
PostgresConnector
since the interface was replaced by template types onSqlConnector
, i.e.SqlConnector<PostgresConfig, PostgresConnection>
- Added support for
BYTEA
fields. (#57) - Added the
PostgresConnection
interface extendingPostgresLink
. - Removed the
Receiver
interface. These methods are now a part ofPostgresConnection
. - Removed the
Quoter
Interface. These methods are now a part ofPostgresExecutor
.
2.0.0 Beta 6
What's Changed
- Compatibility with
amphp/sql-common@v2.0.0-beta.9
. - Forbid cloning and serialization of most class instances.
Full Changelog: v2.0.0-beta.5...v2.0.0-beta.6
2.0.0 Beta 5
What's Changed
Nested transactions have been refactored to be created simply with PostgresTransaction::beginTransaction()
instead of needing to wrap a PostgresTransaction
into a PostgresNestableTransaction
. If you did not use savepoints or nested transactions, you likely will be able to upgrade to this version without any code changes.
- Updated transactions for
amphp/sql@v2.0.0-beta.6
andamphp/sql-common@v2.0.0-beta.7
. RemovedPostgresNestableTransaction
. - Added
PostgresConnection
interface extending the base interfaceConnection
fromamphp/sql
. - Merged
PostgresQuoter
methods intoPostgresExecutor
and removedPostgresQuoter
. - Moved
PostgresReceiver
methods intoPostgresConnection
and removedPostgresReceiver
.
Full Changelog: v2.0.0-beta.4...v2.0.0-beta.5
2.0.0 Beta 4
- Fixed statements used in a nested transaction potentially deadlocking when using
ext-pgsql
.
2.0.0 Beta 3
- Added support for
BYTEA
fields. (#57) - Added
PostgresNestableTransaction
which may be optionally used to create aPostgresLink
from aPostgresTransaction
object. Nested transactions are implemented using savepoints. PostgresExecutor
now extendsPostgresQuoter
, moving the interface lower in the interface hierarchy.
1.4.5
2.0.0 Beta 2
- Compatibility with
Result::fetchRow()
added inamphp/sql@2.0.0-beta.3
- Added support for
BackedEnum
instances in statement parameters - Removed
PostgresConnector
since the interface was replaced by template types onSqlConnector
, i.e.SqlConnector<PostgresConfig, PostgresConnection>
- Fixed
MONEY
type columns from being cast to a float withext-pgsql
, which always resulted in a value of 0.MONEY
columns will now be returned as a string, matchingext-pq
- Requesting the next result set before consuming the entire current result set will now throw an
Error
1.4.4
2.0.0 Beta 1
Initial release compatible with AMPHP v3.
As with other libraries compatible with AMPHP v3, most cases of parameters or returns of Promise<ResolutionType>
have been replaced with ResolutionType
.
- Marked most classes as internal, leaving only interfaces and concrete implementations required to use the API or create a custom connector.
- Added
Postgres
as a prefix to interfaces and non-extension-specific classes. - Renamed
ConnectionConfig
toPostgresConfig
- Removed
TimeoutConnector
in favor ofDefaultPostgresConnector
, which has aCancellation
parameter onconnect()
(useAmp\TimeoutCancellation
with this parameter for similar behavior toTimeoutConnector
)