[wp-trac] [WordPress Trac] #29957: Hardcoded value of $chunk_size variable in class-IXR.php in wp-includes
WordPress Trac
noreply at wordpress.org
Wed Oct 29 18:29:24 UTC 2014
#29957: Hardcoded value of $chunk_size variable in class-IXR.php in wp-includes
-----------------------------------------+------------------------------
Reporter: ankit.gade@… | Owner:
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: XML-RPC | Version: 3.4
Severity: normal | Resolution:
Keywords: has-patch reporter-feedback | Focuses: performance
-----------------------------------------+------------------------------
Changes (by westi):
* keywords: has-patch => has-patch reporter-feedback
Comment:
Replying to [ticket:29957 ankit.gade@…]:
> Variable $chunk_size is used to restrict RAM usage to parse xml-rpc
response message if the message is very large.
> This variable value has been hard coded to 262144 (256 Kb). A filter
should be provided for setting value of this variable.
>
> It has following advantages.
>
> 1. If message is large around 4-5 Mb, then getResponse() method of
IXR_Client returns null, we can avoid this situation by setting
$chunk_size to higher value.
>
> 2. If server configuration is well versed, for example: If we have 32 GB
RAM on server then allotting 5-8 Mb to $chunk_size should not be an issue
and for the same filter can be used.
Hey, Ankit Gade can you explain these bugs in more detail with some
examples.
I'm not sure how change the chunk_size should affect the maximum response
size that can be parsed.
It would be good to have some test date / a unit test which shows how this
bug can be reproduced.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/29957#comment:6>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list