You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am running into an issue when trying to send a message body with more than 65,535 characters.
When running the below send.php, listener.php responds with "length: 0". If you change $content to be 65535 characters, then it responds correctly with "length: 65535".
send.php:
<?php
require('vendor/autoload.php');
use hollodotme\FastCGI\Client;
use hollodotme\FastCGI\Requests\PostRequest;
use hollodotme\FastCGI\SocketConnections\NetworkSocket;
$client = new Client(new NetworkSocket('127.0.0.1', 9000));
$content = str_repeat('a', 65536);
$request = new PostRequest(__DIR__.'/listener.php', $content);
$response = $client->sendRequest($request);
echo $response->getBody();
exit;
contentData: Between 0 and 65535 bytes of data, interpreted according to the record type.
Until now, only one content packet is sent to php-fpm for a request, that's why it is limited to 65535 characters/bytes. This issue seems to be in the client implementation from the beginning (in the original one and mine - for about 7 years).
I already have tested a working solution by sending chunks of content packets. Let me finalize it and bump a new bugfix release.
Thanks for this, you're obviously the first hitting this "edge case".
I am running into an issue when trying to send a message body with more than 65,535 characters.
When running the below send.php, listener.php responds with "length: 0". If you change $content to be 65535 characters, then it responds correctly with "length: 65535".
send.php:
listener.php:
The text was updated successfully, but these errors were encountered: