diff --git a/CHANGELOG.md b/CHANGELOG.md index 44a5cf75..03039ea8 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -15,8 +15,10 @@ Inspired from [Keep a Changelog](https://keepachangelog.com/en/1.0.0/) - Changed fluent setters to return static ### Deprecated - Passing a callable to \OpenSearch\ClientBuilder::setEndpoint() is deprecated and replaced with passing an EndpointFactory to \OpenSearch\ClientBuilder::setEndpointFactory() ([#237](https://github.com/opensearch-project/opensearch-php/pull/237)) +- Connections, Connection pools and Selectors are deprecated. Use a PSR HTTP Client that supports retries instead. ### Removed -- Removed support for PHP 7.3 and 7.4 +- Removed support for PHP 7.3, 7.4 and 8.0. +- Removed support for async requests which were never actually working. ### Fixed - Fixed PHP 8.4 deprecations ### Updated APIs diff --git a/src/OpenSearch/ClientBuilder.php b/src/OpenSearch/ClientBuilder.php index 1349e2c4..da41753b 100644 --- a/src/OpenSearch/ClientBuilder.php +++ b/src/OpenSearch/ClientBuilder.php @@ -45,7 +45,7 @@ use Psr\Log\NullLogger; use ReflectionClass; -@trigger_error(__CLASS__ . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); +@trigger_error(ClientBuilder::class . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); /** * @deprecated in 2.3.2 and will be removed in 3.0.0. diff --git a/src/OpenSearch/Common/EmptyLogger.php b/src/OpenSearch/Common/EmptyLogger.php index c3a44c18..d44f8166 100644 --- a/src/OpenSearch/Common/EmptyLogger.php +++ b/src/OpenSearch/Common/EmptyLogger.php @@ -24,7 +24,7 @@ use Psr\Log\AbstractLogger; use Psr\Log\LoggerInterface; -@trigger_error(__CLASS__ . ' is deprecated in 2.3.2 and will be removed in 3.0.0. Use Psr\Log\NullLogger instead', E_USER_DEPRECATED); +@trigger_error(EmptyLogger::class . ' is deprecated in 2.3.2 and will be removed in 3.0.0. Use Psr\Log\NullLogger instead', E_USER_DEPRECATED); /** * Class EmptyLogger diff --git a/src/OpenSearch/Common/Exceptions/AuthenticationConfigException.php b/src/OpenSearch/Common/Exceptions/AuthenticationConfigException.php index a75cecc0..28afa295 100644 --- a/src/OpenSearch/Common/Exceptions/AuthenticationConfigException.php +++ b/src/OpenSearch/Common/Exceptions/AuthenticationConfigException.php @@ -22,7 +22,7 @@ namespace OpenSearch\Common\Exceptions; -@trigger_error(__CLASS__ . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); +@trigger_error(AuthenticationConfigException::class . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); /** * @deprecated in 2.3.2 and will be removed in 3.0.0. diff --git a/src/OpenSearch/Common/Exceptions/BadRequest400Exception.php b/src/OpenSearch/Common/Exceptions/BadRequest400Exception.php index 4ea5798d..ac232f01 100644 --- a/src/OpenSearch/Common/Exceptions/BadRequest400Exception.php +++ b/src/OpenSearch/Common/Exceptions/BadRequest400Exception.php @@ -21,7 +21,7 @@ namespace OpenSearch\Common\Exceptions; -@trigger_error(__CLASS__ . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); +@trigger_error(BadRequest400Exception::class . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); /** * @deprecated in 2.3.2 and will be removed in 3.0.0. diff --git a/src/OpenSearch/Common/Exceptions/ClientErrorResponseException.php b/src/OpenSearch/Common/Exceptions/ClientErrorResponseException.php index a2a56caa..884e00f2 100644 --- a/src/OpenSearch/Common/Exceptions/ClientErrorResponseException.php +++ b/src/OpenSearch/Common/Exceptions/ClientErrorResponseException.php @@ -21,7 +21,7 @@ namespace OpenSearch\Common\Exceptions; -@trigger_error(__CLASS__ . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); +@trigger_error(ClientErrorResponseException::class . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); /** * @deprecated in 2.3.2 and will be removed in 3.0.0. diff --git a/src/OpenSearch/Common/Exceptions/Conflict409Exception.php b/src/OpenSearch/Common/Exceptions/Conflict409Exception.php index fe7e6a6d..36e6ed34 100644 --- a/src/OpenSearch/Common/Exceptions/Conflict409Exception.php +++ b/src/OpenSearch/Common/Exceptions/Conflict409Exception.php @@ -21,7 +21,7 @@ namespace OpenSearch\Common\Exceptions; -@trigger_error(__CLASS__ . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); +@trigger_error(Conflict409Exception::class . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); /** * @deprecated in 2.3.2 and will be removed in 3.0.0. diff --git a/src/OpenSearch/Common/Exceptions/Curl/CouldNotConnectToHost.php b/src/OpenSearch/Common/Exceptions/Curl/CouldNotConnectToHost.php index cd7ad8b4..7f95c944 100644 --- a/src/OpenSearch/Common/Exceptions/Curl/CouldNotConnectToHost.php +++ b/src/OpenSearch/Common/Exceptions/Curl/CouldNotConnectToHost.php @@ -25,7 +25,7 @@ use OpenSearch\Common\Exceptions\OpenSearchException; use OpenSearch\Common\Exceptions\TransportException; -@trigger_error(__CLASS__ . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); +@trigger_error(CouldNotConnectToHost::class . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); /** * @deprecated in 2.3.2 and will be removed in 3.0.0. diff --git a/src/OpenSearch/Common/Exceptions/Curl/CouldNotResolveHostException.php b/src/OpenSearch/Common/Exceptions/Curl/CouldNotResolveHostException.php index 6e6c91d5..3b6a5417 100644 --- a/src/OpenSearch/Common/Exceptions/Curl/CouldNotResolveHostException.php +++ b/src/OpenSearch/Common/Exceptions/Curl/CouldNotResolveHostException.php @@ -24,7 +24,7 @@ use OpenSearch\Common\Exceptions\OpenSearchException; use OpenSearch\Common\Exceptions\TransportException; -@trigger_error(__CLASS__ . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); +@trigger_error(CouldNotResolveHostException::class . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); /** * @deprecated in 2.3.2 and will be removed in 3.0.0. diff --git a/src/OpenSearch/Common/Exceptions/Curl/OperationTimeoutException.php b/src/OpenSearch/Common/Exceptions/Curl/OperationTimeoutException.php index 137a4ba9..19bf5fc5 100644 --- a/src/OpenSearch/Common/Exceptions/Curl/OperationTimeoutException.php +++ b/src/OpenSearch/Common/Exceptions/Curl/OperationTimeoutException.php @@ -24,7 +24,7 @@ use OpenSearch\Common\Exceptions\OpenSearchException; use OpenSearch\Common\Exceptions\TransportException; -@trigger_error(__CLASS__ . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); +@trigger_error(OperationTimeoutException::class . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); /** * @deprecated in 2.3.2 and will be removed in 3.0.0. diff --git a/src/OpenSearch/Common/Exceptions/Forbidden403Exception.php b/src/OpenSearch/Common/Exceptions/Forbidden403Exception.php index d7572e22..8a307cd0 100644 --- a/src/OpenSearch/Common/Exceptions/Forbidden403Exception.php +++ b/src/OpenSearch/Common/Exceptions/Forbidden403Exception.php @@ -21,7 +21,7 @@ namespace OpenSearch\Common\Exceptions; -@trigger_error(__CLASS__ . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); +@trigger_error(Forbidden403Exception::class . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); /** * @deprecated in 2.3.2 and will be removed in 3.0.0. diff --git a/src/OpenSearch/Common/Exceptions/InvalidArgumentException.php b/src/OpenSearch/Common/Exceptions/InvalidArgumentException.php index f9ffb68b..0ff06b20 100644 --- a/src/OpenSearch/Common/Exceptions/InvalidArgumentException.php +++ b/src/OpenSearch/Common/Exceptions/InvalidArgumentException.php @@ -21,7 +21,7 @@ namespace OpenSearch\Common\Exceptions; -@trigger_error(__CLASS__ . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); +@trigger_error(InvalidArgumentException::class . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); /** * @deprecated in 2.3.2 and will be removed in 3.0.0. diff --git a/src/OpenSearch/Common/Exceptions/MaxRetriesException.php b/src/OpenSearch/Common/Exceptions/MaxRetriesException.php index 296dc69b..9d4be5fa 100644 --- a/src/OpenSearch/Common/Exceptions/MaxRetriesException.php +++ b/src/OpenSearch/Common/Exceptions/MaxRetriesException.php @@ -21,7 +21,7 @@ namespace OpenSearch\Common\Exceptions; -@trigger_error(__CLASS__ . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); +@trigger_error(MaxRetriesException::class . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); /** * @deprecated in 2.3.2 and will be removed in 3.0.0. diff --git a/src/OpenSearch/Common/Exceptions/Missing404Exception.php b/src/OpenSearch/Common/Exceptions/Missing404Exception.php index 35d16e35..c9b69be7 100644 --- a/src/OpenSearch/Common/Exceptions/Missing404Exception.php +++ b/src/OpenSearch/Common/Exceptions/Missing404Exception.php @@ -21,7 +21,7 @@ namespace OpenSearch\Common\Exceptions; -@trigger_error(__CLASS__ . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); +@trigger_error(Missing404Exception::class . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); /** * @deprecated in 2.3.2 and will be removed in 3.0.0. diff --git a/src/OpenSearch/Common/Exceptions/NoDocumentsToGetException.php b/src/OpenSearch/Common/Exceptions/NoDocumentsToGetException.php index 7d43c652..82fdd9fa 100644 --- a/src/OpenSearch/Common/Exceptions/NoDocumentsToGetException.php +++ b/src/OpenSearch/Common/Exceptions/NoDocumentsToGetException.php @@ -21,7 +21,7 @@ namespace OpenSearch\Common\Exceptions; -@trigger_error(__CLASS__ . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); +@trigger_error(NoDocumentsToGetException::class . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); /** * @deprecated in 2.3.2 and will be removed in 3.0.0. diff --git a/src/OpenSearch/Common/Exceptions/RequestTimeout408Exception.php b/src/OpenSearch/Common/Exceptions/RequestTimeout408Exception.php index 31025246..0892ea13 100644 --- a/src/OpenSearch/Common/Exceptions/RequestTimeout408Exception.php +++ b/src/OpenSearch/Common/Exceptions/RequestTimeout408Exception.php @@ -21,7 +21,7 @@ namespace OpenSearch\Common\Exceptions; -@trigger_error(__CLASS__ . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); +@trigger_error(RequestTimeout408Exception::class . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); /** * @deprecated in 2.3.2 and will be removed in 3.0.0. diff --git a/src/OpenSearch/ConnectionPool/AbstractConnectionPool.php b/src/OpenSearch/ConnectionPool/AbstractConnectionPool.php index 71614ed8..ecb0f0b6 100644 --- a/src/OpenSearch/ConnectionPool/AbstractConnectionPool.php +++ b/src/OpenSearch/ConnectionPool/AbstractConnectionPool.php @@ -26,7 +26,7 @@ use OpenSearch\Connections\ConnectionFactoryInterface; use OpenSearch\Connections\ConnectionInterface; -@trigger_error(__CLASS__ . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); +@trigger_error(AbstractConnectionPool::class . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); /** * @deprecated in 2.3.2 and will be removed in 3.0.0. diff --git a/src/OpenSearch/ConnectionPool/ConnectionPoolInterface.php b/src/OpenSearch/ConnectionPool/ConnectionPoolInterface.php index a229a2d8..0c5da67d 100644 --- a/src/OpenSearch/ConnectionPool/ConnectionPoolInterface.php +++ b/src/OpenSearch/ConnectionPool/ConnectionPoolInterface.php @@ -23,7 +23,7 @@ use OpenSearch\Connections\ConnectionInterface; -@trigger_error(__CLASS__ . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); +@trigger_error(ConnectionPoolInterface::class . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); /** * @deprecated in 2.3.2 and will be removed in 3.0.0. diff --git a/src/OpenSearch/ConnectionPool/Selectors/RandomSelector.php b/src/OpenSearch/ConnectionPool/Selectors/RandomSelector.php index 819adf70..557a9063 100644 --- a/src/OpenSearch/ConnectionPool/Selectors/RandomSelector.php +++ b/src/OpenSearch/ConnectionPool/Selectors/RandomSelector.php @@ -23,7 +23,7 @@ use OpenSearch\Connections\ConnectionInterface; -@trigger_error(__CLASS__ . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); +@trigger_error(RandomSelector::class . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); /** * @deprecated in 2.3.2 and will be removed in 3.0.0. diff --git a/src/OpenSearch/ConnectionPool/Selectors/RoundRobinSelector.php b/src/OpenSearch/ConnectionPool/Selectors/RoundRobinSelector.php index 412fb196..1c0204bc 100644 --- a/src/OpenSearch/ConnectionPool/Selectors/RoundRobinSelector.php +++ b/src/OpenSearch/ConnectionPool/Selectors/RoundRobinSelector.php @@ -23,7 +23,7 @@ use OpenSearch\Connections\ConnectionInterface; -@trigger_error(__CLASS__ . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); +@trigger_error(RoundRobinSelector::class . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); /** * @deprecated in 2.3.2 and will be removed in 3.0.0. diff --git a/src/OpenSearch/ConnectionPool/Selectors/SelectorInterface.php b/src/OpenSearch/ConnectionPool/Selectors/SelectorInterface.php index 1eff5268..2d7ba1f2 100644 --- a/src/OpenSearch/ConnectionPool/Selectors/SelectorInterface.php +++ b/src/OpenSearch/ConnectionPool/Selectors/SelectorInterface.php @@ -23,7 +23,7 @@ use OpenSearch\Connections\ConnectionInterface; -@trigger_error(__CLASS__ . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); +@trigger_error(SelectorInterface::class . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); /** * @deprecated in 2.3.2 and will be removed in 3.0.0. diff --git a/src/OpenSearch/ConnectionPool/Selectors/StickyRoundRobinSelector.php b/src/OpenSearch/ConnectionPool/Selectors/StickyRoundRobinSelector.php index aef1588f..5091ac40 100644 --- a/src/OpenSearch/ConnectionPool/Selectors/StickyRoundRobinSelector.php +++ b/src/OpenSearch/ConnectionPool/Selectors/StickyRoundRobinSelector.php @@ -23,7 +23,7 @@ use OpenSearch\Connections\ConnectionInterface; -@trigger_error(__CLASS__ . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); +@trigger_error(StickyRoundRobinSelector::class . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); /** * @deprecated in 2.3.2 and will be removed in 3.0.0. diff --git a/src/OpenSearch/ConnectionPool/SimpleConnectionPool.php b/src/OpenSearch/ConnectionPool/SimpleConnectionPool.php index 26592d28..0108a3e6 100644 --- a/src/OpenSearch/ConnectionPool/SimpleConnectionPool.php +++ b/src/OpenSearch/ConnectionPool/SimpleConnectionPool.php @@ -25,7 +25,7 @@ use OpenSearch\Connections\ConnectionFactoryInterface; use OpenSearch\Connections\ConnectionInterface; -@trigger_error(__CLASS__ . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); +@trigger_error(SimpleConnectionPool::class . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); /** * @deprecated in 2.3.2 and will be removed in 3.0.0. diff --git a/src/OpenSearch/ConnectionPool/SniffingConnectionPool.php b/src/OpenSearch/ConnectionPool/SniffingConnectionPool.php index 64bd7d85..d27d1228 100644 --- a/src/OpenSearch/ConnectionPool/SniffingConnectionPool.php +++ b/src/OpenSearch/ConnectionPool/SniffingConnectionPool.php @@ -28,7 +28,7 @@ use OpenSearch\Connections\ConnectionFactoryInterface; use OpenSearch\Connections\ConnectionInterface; -@trigger_error(__CLASS__ . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); +@trigger_error(SniffingConnectionPool::class . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); /** * @deprecated in 2.3.2 and will be removed in 3.0.0. diff --git a/src/OpenSearch/ConnectionPool/StaticConnectionPool.php b/src/OpenSearch/ConnectionPool/StaticConnectionPool.php index 8d62c62b..0f16fbe6 100644 --- a/src/OpenSearch/ConnectionPool/StaticConnectionPool.php +++ b/src/OpenSearch/ConnectionPool/StaticConnectionPool.php @@ -27,7 +27,7 @@ use OpenSearch\Connections\ConnectionFactoryInterface; use OpenSearch\Connections\ConnectionInterface; -@trigger_error(__CLASS__ . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); +@trigger_error(StaticConnectionPool::class . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); /** * @deprecated in 2.3.2 and will be removed in 3.0.0. diff --git a/src/OpenSearch/ConnectionPool/StaticNoPingConnectionPool.php b/src/OpenSearch/ConnectionPool/StaticNoPingConnectionPool.php index 643aeb35..9b3b6001 100644 --- a/src/OpenSearch/ConnectionPool/StaticNoPingConnectionPool.php +++ b/src/OpenSearch/ConnectionPool/StaticNoPingConnectionPool.php @@ -27,7 +27,7 @@ use OpenSearch\Connections\ConnectionFactoryInterface; use OpenSearch\Connections\ConnectionInterface; -@trigger_error(__CLASS__ . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); +@trigger_error(StaticNoPingConnectionPool::class . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); /** * @deprecated in 2.3.2 and will be removed in 3.0.0. diff --git a/src/OpenSearch/Connections/Connection.php b/src/OpenSearch/Connections/Connection.php index 4ff592ed..653a1bcb 100644 --- a/src/OpenSearch/Connections/Connection.php +++ b/src/OpenSearch/Connections/Connection.php @@ -47,7 +47,7 @@ use OpenSearch\Transport; use Psr\Log\LoggerInterface; -@trigger_error(__CLASS__ . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); +@trigger_error(Connection::class . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); /** * @deprecated in 2.3.2 and will be removed in 3.0.0. diff --git a/src/OpenSearch/Connections/ConnectionFactory.php b/src/OpenSearch/Connections/ConnectionFactory.php index 5a02c441..f19d78b4 100644 --- a/src/OpenSearch/Connections/ConnectionFactory.php +++ b/src/OpenSearch/Connections/ConnectionFactory.php @@ -24,7 +24,7 @@ use OpenSearch\Serializers\SerializerInterface; use Psr\Log\LoggerInterface; -@trigger_error(__CLASS__ . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); +@trigger_error(ConnectionFactory::class . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); /** * @deprecated in 2.3.2 and will be removed in 3.0.0. diff --git a/src/OpenSearch/Connections/ConnectionFactoryInterface.php b/src/OpenSearch/Connections/ConnectionFactoryInterface.php index 8929c9ea..ddb240cd 100644 --- a/src/OpenSearch/Connections/ConnectionFactoryInterface.php +++ b/src/OpenSearch/Connections/ConnectionFactoryInterface.php @@ -21,7 +21,7 @@ namespace OpenSearch\Connections; -@trigger_error(__CLASS__ . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); +@trigger_error(ConnectionFactoryInterface::class . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); /** * @deprecated in 2.3.2 and will be removed in 3.0.0. diff --git a/src/OpenSearch/Connections/ConnectionInterface.php b/src/OpenSearch/Connections/ConnectionInterface.php index 1d9d5a9b..791c5a79 100644 --- a/src/OpenSearch/Connections/ConnectionInterface.php +++ b/src/OpenSearch/Connections/ConnectionInterface.php @@ -23,7 +23,7 @@ use OpenSearch\Transport; -@trigger_error(__CLASS__ . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); +@trigger_error(ConnectionInterface::class . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); /** * @deprecated in 2.3.2 and will be removed in 3.0.0. diff --git a/src/OpenSearch/Handlers/SigV4Handler.php b/src/OpenSearch/Handlers/SigV4Handler.php index 3b88f6aa..fa1edad1 100644 --- a/src/OpenSearch/Handlers/SigV4Handler.php +++ b/src/OpenSearch/Handlers/SigV4Handler.php @@ -13,7 +13,7 @@ use Psr\Http\Message\RequestInterface; use RuntimeException; -@trigger_error(__CLASS__ . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); +@trigger_error(SigV4Handler::class . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); /** * @phpstan-type RingPhpRequest array{http_method: string, scheme: string, uri: string, query_string?: string, version?: string, headers: array>, body: string|resource|null, client?: array} diff --git a/src/OpenSearch/Transport.php b/src/OpenSearch/Transport.php index d3dbcd40..cd4ecf07 100644 --- a/src/OpenSearch/Transport.php +++ b/src/OpenSearch/Transport.php @@ -27,7 +27,7 @@ use OpenSearch\Connections\ConnectionInterface; use Psr\Log\LoggerInterface; -@trigger_error(__CLASS__ . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); +@trigger_error(Transport::class . ' is deprecated in 2.3.2 and will be removed in 3.0.0.', E_USER_DEPRECATED); /** * @deprecated in 2.3.2 and will be removed in 3.0.0.