Pending

User tests: Successful: Unsuccessful:

avatar Fedik
Fedik
15 Sep 2024

Pull Request for Issue # .

Summary of Changes

It is not actually a fix, but rather demo and try to find out why List query is slow for site with large amount of articles.

After some debugging I found that MySQL is ignoring a few indexes while runing query from getListQuery(), but only for large amount of Articles. And for the Testing sample data these indexes working very well.

The ignored indexes:

  • #__languages : idx_langcode
  • #__users: PRIMARY
  • #__workflow_associations: PRIMARY
  • #__workflow_stages: PRIMARY
  • #__workflows: PRIMARY

If someone have an idea how to make it work without FORCE INDEX that would be nice.
There probably also other reasons, that I did not found.

Note: The code in PR will not work with PostgreSQL.

Testing Instructions

Create a site with 20k articles (more is better). Can use following plugin to generate random content https://github.com/Fedik/plg_sampledata_bigdata

Enable debug.
Open list of articles in administrator.
Look for time in the debug bar.

Also can enable "Query profiling" and "Query explain" in debug plugin, and check them for the list query in the debug bar before and after PR.

Actual result BEFORE applying this Pull Request

Around ~2s

Expected result AFTER applying this Pull Request

Around ~500ms

Link to documentations

Please select:

  • Documentation link for docs.joomla.org:
  • No documentation changes for docs.joomla.org needed
  • Pull Request link for manual.joomla.org:
  • No documentation changes for manual.joomla.org needed

Related issue:

avatar Fedik Fedik - open - 15 Sep 2024
avatar Fedik Fedik - change - 15 Sep 2024
Status New Pending
avatar joomla-cms-bot joomla-cms-bot - change - 15 Sep 2024
Category Administration com_content Front End
avatar Fedik Fedik - change - 15 Sep 2024
The description was changed
avatar Fedik Fedik - edited - 15 Sep 2024
avatar Fedik Fedik - change - 15 Sep 2024
The description was changed
avatar Fedik Fedik - edited - 15 Sep 2024
avatar Fedik Fedik - change - 1 Oct 2024
The description was changed
avatar Fedik Fedik - edited - 1 Oct 2024
avatar Fedik Fedik - change - 5 Oct 2024
Title
[5.2][Performance] Optimising of the ArticlesModel::getListQuery() for large sites
[5.3][Performance] Optimising of the ArticlesModel::getListQuery() for large sites
avatar Fedik Fedik - edited - 5 Oct 2024

Add a Comment

Login with GitHub to post a comment