[wp-trac] [WordPress Trac] #37997: Increase in function calls to get_locale() because of _load_textdomain_just_in_time()

WordPress Trac noreply at wordpress.org
Sat Nov 12 00:21:28 UTC 2016


#37997: Increase in function calls to get_locale() because of
_load_textdomain_just_in_time()
-------------------------------------------------+-------------------------
 Reporter:  sharkomatic                          |       Owner:  ocean90
     Type:  defect (bug)                         |      Status:  reviewing
 Priority:  normal                               |   Milestone:  4.7
Component:  I18N                                 |     Version:  4.6
 Severity:  normal                               |  Resolution:
 Keywords:  needs-testing has-patch has-unit-    |     Focuses:
  tests                                          |  performance
-------------------------------------------------+-------------------------

Comment (by jrf):

 Just out of curiosity and as it hasn't been asked before.

 As the chart explicitly states the issue is with the `locale`
 '''''hook''''':
 @sharkomatic Could you check which functions are hooked into the `locale`
 hook on your install ?

 You can check it using the [https://wordpress.org/plugins/debug-bar/ Debug
 Bar] plugin combined with the [https://wordpress.org/plugins/debug-bar-
 actions-and-filters-addon/ Debug Bar Actions and Filters Addon].

 It be great to see the list of hooked in functions for both front-end as
 well as back-end to verify.

 On a default install, AFAICS, nothing is hooked in, so the hook itself
 should not cause such a performance hit.

 I'm just wondering if we're not trying to solve an issue caused by a
 plugin instead of by WP core here....

--
Ticket URL: <https://core.trac.wordpress.org/ticket/37997#comment:24>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list