Closed (fixed)
Project:
Book access
Version:
6.x-1.0-rc6
Component:
Code
Priority:
Normal
Category:
Task
Assigned:
Unassigned
Reporter:
Created:
23 Aug 2010 at 22:52 UTC
Updated:
7 Oct 2010 at 11:20 UTC
Jump to comment: Most recent
I am preparing to use the book_access module in a site with more than 70,000 nodes. Doing a full rebuild of the content access permissions doesn't take a few moments in this situation - it usually takes at least 30 minutes. There aren't too many nodes that are organized as books in our site (probably less than 250) and it would be nice to keep all the other nodes accessible when changing book permissions.
After changing permissions on a book, is there a way to rebuild the node access information only for nodes that are part of that book rather than every node in the site?
Comments
Comment #1
Anonymous (not verified) commentedLooking at the code of the function node_access_rebuild(), I think it is possible to rebuild the permissions only for the interested nodes.
This means to duplicate the code used by Drupal, but it is worth doing it for cases where the book pages are less than the total number of nodes present in a Drupal-powered site.
Comment #2
Anonymous (not verified) commentedThe code has been changed, and committed in the development snapshot. Thank you for your report.
The code still needs to be changed in branch 6.x-2.
Comment #3
Anonymous (not verified) commentedI committed the code also for the branch 6.x-2.