Hi,

I prepared a patch to replace sapi_globals' request_info post_data and
raw_post_data with a temp stream and remove support for
HTTP_RAW_POST_DATA. [1]

PROS:
* save up to 300% on post_data_len memory (on non-form POSTs)
* a local siege (c=512/512, 2.4k form/2.2k json) showed no (negative)
performance impact; see attached logs
* reusable php://input stream
* ...

CONS:
* no more $HTTP_RAW_POST_DATA, where BC could easily provided with a one-liner:
$GLOBALS["HTTP_RAW_POST_DATA"]=file_get_contents("php://input");
* memory is cheap
* ???


[1] https://github.com/m6w6/php-src/compare/slim-postdata-merge

-- 
Regards,
Mike

Attachment: logs.json
Description: application/json

-- 
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to