just thought this might be of notice for institutions who use managed ACLs (i.e. "Access policies" / Access Policy Templates).
We had 11k of them due to how the Stud.IP Opencast Plugin worked in the past.
AccessInformationUtil::matchAcls() required 6s to process (that's 6s per series and per event) which was certainly too slow for a sane /index/rebuild
Eventually, I dropped them from the database. Don't do that if you're not planning to reindex all your assets, though or if you are still relying on them.
DELETE FROM opencast.oc_acl_managed_acl
WHERE `name` LIKE 'course%'
OR `name` LIKE 'combined%';
Now, with only about 7 ACLs left, one series was indexed within under 50ms.