[wp-trac] [WordPress Trac] #57901: Improvement the performance of lazy loading meta api

WordPress Trac noreply at wordpress.org
Fri Mar 10 12:11:25 UTC 2023


#57901: Improvement the performance of lazy loading meta api
--------------------------------+-----------------------------
 Reporter:  spacedmonkey        |      Owner:  (none)
     Type:  enhancement         |     Status:  new
 Priority:  normal              |  Milestone:  Awaiting Review
Component:  Options, Meta APIs  |    Version:  4.5
 Severity:  normal              |   Keywords:
  Focuses:  performance         |
--------------------------------+-----------------------------
 The existing lazy loading meta api, creates a queue of ids, to be primed,
 if the get_comment_meta or get_term_meta functions are called. Once they
 it is called for the first time, then queue is primed in cache and the
 queue is clear. However, this does not check to see the request piece of
 meta, was already in the queue. Take this scenario for example.

 1. Add 3 ids to the lazy load queue, 123, 456, 789.
 2. Call get_term_meta, with id 444.
 3. This will prime all term meta in lazy load queue and not prime 444.

 There should be a simple check in check processing the queue, to see in
 requested id is in the queue.

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/57901>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list