Review 11.5 Merged

78304[BUGFIX] Improve performance of TreeController

Andreas Kienast CR +2 V +2 Easy +23 −19 updated 04/11/23, 11:03

Commit message

The recursive function pagesToFlatArray make use of
the page tree repository on two places, which always
instantiates the same object. To improve the performance
this patch instantiates the page tree only once and stores
it in a protected property.

Moreover, it adds another protected property
editPageAndDefaultLanguageAccess, which holds the general
allowance of a backend user to modify pages and access to
the default language. This information is needed in the
pagesToFlatArray as well and was requested over and over
again.

Finally, the array_merge construction inside fetchDataAction
and filterDataAction was changed to a more performant solution,
by merging it after the loop.
Overall, this reduces the request time of a page tree ajax
call (data and filter) by around 10%.

Review

  • Code review CR +2

    Imported before Forger kept the single votes, the next import adds them.

  • Verified V +2

    Imported before Forger kept the single votes, the next import adds them.

Issues 1

Files 1