Flowpack / media-ui

The development repository for the new Neos media management interface
GNU General Public License v3.0
20 stars 16 forks source link

BUGFIX: Don’t include asset variants in counts #225

Closed Sebobo closed 6 months ago

Sebobo commented 6 months ago

This problem appeared due to variants getting the same collection applied as their original asset in https://github.com/neos/neos-development-collection/pull/3562

Fixes: #224

Sebobo commented 6 months ago

To fix this I had to add a join to the count query to check the type of asset. I need to check whether this hurts performance in my larger projects and maybe adjust the query.

Sebobo commented 6 months ago

So this hurts performance with a large numbers of assets. I have to see whether I find a better solution.

Sebobo commented 6 months ago

So I updated the implementation with a sub select instead of a join. This still hurts performance, but it's about 3x faster than the JOIN on the asset table to check the dtype would have been.