2.0.0
This release provides compatibility with amphp/socket
v1.0. Most users of this library should be able to upgrade from 1.x to 2.0 with few to no changes. Please check the list of changes below for those that may affect your code.
- PHP 7.1+ now required.
- Duplicate parameter names in prepared statements now require only a single value in the parameter array passed to execute. e.g.:
SELECT * FROM test WHERE classId > :id AND nodeId < :id
will only require one value set forid
instead of an array of values:$statement->execute(['id' => 10])
. This behavior mirrorsamphp/postgres
and the PDO extension. (#90) ConnectionConfig
constructor now takes aConnectContext
as the second argument instead ofClientTlsContext
. TLS (and other connection) options can be specified using theConnectContext
object.ConnectionConfig::getTlsContext()
andConnectionConfig::withTlsContext()
have been replaced withConnectionConfig::getConnectContext()
andConnectionConfig::withConnectContext()
.- Added
CancellableConnector
that allows aCancellationToken
to be used to cancel the connection request. TimeoutConnector
removed. Specify a connection timeout usingConnectContext::withTimeout()
as part ofConnectionConfig
or with aTimeoutCancellationToken
withCancellableConnector
.Statement::bindParam()
now declaresvoid
as a return type.- Fixed result value when the column type is JSON and the data was inserted using a cast (#88).