[wp-trac] [WordPress Trac] #55206: wp core api memory leaks
WordPress Trac
noreply at wordpress.org
Sun Feb 20 13:57:03 UTC 2022
#55206: wp core api memory leaks
--------------------------+------------------------------
Reporter: sllimrovert | Owner: (none)
Type: defect (bug) | Status: assigned
Priority: normal | Milestone: Awaiting Review
Component: Database | Version: trunk
Severity: normal | Resolution:
Keywords: 2nd-opinion | Focuses: performance
--------------------------+------------------------------
Changes (by SergeyBiryukov):
* keywords: => 2nd-opinion
* focuses: => performance
Comment:
Hi there, welcome back to WordPress Trac! Thanks for the ticket.
At a glance, the `SAVEQUERIES` constant works as intended here, it is only
meant for debugging and not meant to be enabled during large batch
processing jobs.
As for the object cache growing, you may get better results using the
`wp_suspend_cache_addition()` function introduced in [18681] / #5389
exactly for cases like this.
So I would say that both `$wpdb` and the object cache work as expected in
these circumstances. To impove perfomance of large batch processing jobs,
I would suggest looking into asynchronous solutions like
[https://github.com/deliciousbrains/wp-background-processing WP Background
Processing]. That said, I'm curious to know if you or anyone else have any
ideas on how WordPress core could be improved here.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/55206#comment:1>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list