Problem/Motivation

It's been pointed out that permissions_by_entity needs a pretty big overhaul so thought I'd open a ticket to track this

Proposed resolution

For consideration.
There's this module https://www.drupal.org/project/taxonomy_entity_index that tracks taxonomy indexes across different entities. Could this module be leveraged to use that?

Currently only using taxonomy_index is tracking published nodes only.

Comments

smustgrave created an issue. See original summary.

mrweiner’s picture

I'm no longer working on the project where I was using PbT/PbE, but at the time I discovered a lot of uncached, raw database queries, e.g. in AccessCheck, AccessStorage, NodeAccess, and TermHandler. This was problematic for us due to the sheer number of fields/taxonomies/entities the site had and led to performance issues. This module was a frequent offender in NewRelic as having some of the slowest/longest method/function calls in the application.

Shameless plug for https://www.drupal.org/project/cache_register, which I created to simplify inline caching. I was inspired to create it specifically because of PbT/PbE after creating #3126542: Improve Performance.

I think the aforementioned classes/queries could benefit from it, and potentially also from the addition of a/multiple custom cache bin(s) to help persist query cachability and increase the amount of data that can be cached. Cache tables are limited to 5000 rows by default, but this can be increased if needed: https://git.drupalcode.org/project/tome/-/commit/bcccb3c5d306e4b2608ea73...

mrweiner’s picture

jepster_’s picture

I have currently no project which would provide me the time to work on this module and make such big improvements like refactoring. If anybody would like to work on refactorings: please let me know.