psrebniak / guzzle-socket-handler
Unix socket handler for guzzle 6
Installs: 141
Dependents: 0
Suggesters: 0
Security: 0
Stars: 3
Watchers: 1
Forks: 1
Open Issues: 0
pkg:composer/psrebniak/guzzle-socket-handler
Requires
- guzzlehttp/guzzle: ~6.0
Requires (Dev)
- phpunit/phpunit: ^4.0
This package is not auto-updated.
Last update: 2025-11-09 07:21:13 UTC
README
Warning
This package is deprecated since cURL 7.40.0.
Use curl_setopt with CURLOPT_UNIX_SOCKET_PATH option instead of this package (available in cURL 7.40.0 (PHP 7.0.7))
Unix socket handler for guzzle 6.
Installation
composer require psrebniak/guzzle-socket-handler
Usage:
\GuzzleHttp\Client([
'handler' => new \psrebniak\GuzzleSocketHandler\SocketHandlerFactory(
$path
[, $domain = AF_UNIX
[, $type = SOCK_STREAM
[, $protocol = SOL_SOCKET
]]]
)
]);
Request options (from \psrebniak\GuzzleSocketHandler\SocketOptions)
SOCKET_TIMEOUT- alias ofRequestOptions::CONNECT_TIMEOUTSOCKET_DEBUG- alias ofRequestOptions::DEBUG
Done:
- sending JSON (
$options[RequestOptions::JSON]key) - sending form params (
$options[RequestOptions::FORM_PARAMS]key) - sending multipart (
$options[RequestOptions::multipart]key) - tracking redirects (
$options[RequestOptions::ALLOW_REDIRECTS]key) - timeout (
$options[RequestOptions::CONNECT_TIMEOUT]key) - Http Authentication (
$options[RequestOptions::AUTH]key)