Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
On every entity check, "checkTree" is getting the schema menu tree. This is causing a huge overhead (and timeouts) if there are several menus with thousands of nodes on each one (my situation: 4 menus with +1000 nodes).
IMHO, the menu tree must be cached in some way.
Comment | File | Size | Author |
---|---|---|---|
#9 | 2965924-workbench_access-static-cache-9.patch | 1.71 KB | agentrickard |
#8 | 2965924-workbench_access-static-cache-8.patch | 1.5 KB | agentrickard |
#2 | cache_scheme_menu_tree-2965924-1.patch | 1.1 KB | rutiolma |
Comments
Comment #2
rutiolmaSomething like this will work
Comment #3
rutiolmaComment #4
agentrickardNot a bug.
Comment #5
agentrickardBTW: I've always assumed that tree caching happens at the core level, and I've never liked using Menu for access control because of this very overhead.
Comment #6
agentrickardYou cannot put menu-specific handling code in the WorkbenchAccessManager. That is a base class that handles plugin implementations.
I agree with the need for caching, but this needs to be abstracted for use with all Plugin types.
Comment #7
agentrickardThis also needs means and tests for cache invalidation.
Comment #8
agentrickardNew patch. Running tests now.
Comment #9
agentrickardNew patch.
Comment #11
agentrickardCommitted.