[wp-trac] [WordPress Trac] #27122: Optimization for PHP FPM
WordPress Trac
noreply at wordpress.org
Fri Feb 14 13:13:51 UTC 2014
#27122: Optimization for PHP FPM
-------------------------+------------------------------
Reporter: dunglas | Owner:
Type: enhancement | Status: new
Priority: normal | Milestone: Awaiting Review
Component: General | Version: 3.8
Severity: normal | Resolution:
Keywords: | Focuses: performance
-------------------------+------------------------------
Comment (by dunglas):
I agree to disable this optimization in debug mode, however the problem
with your proposal is that {{{ wp_ob_end_flush_all() }}} is always called
even when this is unnecessary.
I'll provide a new batch ASAP.
Replying to [comment:8 Denis-de-Bernardy]:
> I don't like this patch. It makes it harder than it needs if you ever
need or want to remove the flush function.
>
> Can I suggest the following instead?
>
> {{{
> function wp_finish_request() {
> if (!WP_DEBUG && function_exists('fastcgi_finish_request')) {
> fastcgi_finish_request();
> }
> }
> add_action('shutdown', 'wp_finish_request', 2);
> }}}
>
> That function would need a docblock, too. The point is, it shouldn't be
enabled when debugging, and a plugin should be able to remove it without
worrying about its implementation details.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/27122#comment:9>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list