[wp-trac] [WordPress Trac] #31071: media / post_mime_type related queries are very slow on larger sites

WordPress Trac noreply at wordpress.org
Tue Apr 19 05:31:51 UTC 2016


#31071: media / post_mime_type related queries are very slow on larger sites
-------------------------------------------------+-------------------------
 Reporter:  archon810                            |       Owner:  pento
     Type:  defect (bug)                         |      Status:  assigned
 Priority:  normal                               |   Milestone:  Future
Component:  Media                                |  Release
 Severity:  normal                               |     Version:  4.1
 Keywords:  dev-feedback reporter-feedback 2nd-  |  Resolution:
  opinion has-patch                              |     Focuses:
                                                 |  performance
-------------------------------------------------+-------------------------

Comment (by mintindeed):

 I think the index is a more sound strategy. Logically I don't know why
 this index would cause more problems than any other index. There's also
 the idea that people are no more worse off with the index, and many will
 be better off, and those who are having problems with the index can help
 gather more data about why it doesn't work for some people.

 If that's not enough, then I'd suggest instead of using a transient, set a
 flag. You'll know when an audio or video file gets uploaded, so you can
 unset the flag then. When deleting an audio or video file, you can then
 check to see if it's the only one left in the media library and re-set the
 flag at that time. Upgrades can check the media library during the
 database upgrade operation and set the initial flag accordingly.

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


More information about the wp-trac mailing list