while looking at optimising drupal post the registry, i noticed that menu_get_active_help
is a code hog. one of the things we want to get rid of now we have the registry is the module_load_all call during bootstrap. [In Drupal 8, this is in \Drupal\help\Plugin\Block\HelpBlock::getActiveHelp() ].
most modules implement hook_help, so menu_get_active_help
loads 'em.
thing is, most modules hook_help implementations don't care about most paths. also, for paths they care about, the output will rarely change.
creating this issue to look into this further, so we don't load every module that implements hook_help on every page request.
Comments
Comment #1
chx CreditAttribution: chx commentedhook_menu , keys help and help_callback instead of a hook_help and paths. I asked Gurpartap Singh, the SoC student who will do stuff with help subsystem to chime in.
Comment #2
Gábor Hojtsychx: Yay, this is a nice suggestion! Go, go! I also think tying the helps to pages by menu could be a way to go. It is also advisable to follow developments on the advanced help module with this issue. All-in-all it would be best to move out help text from module code altogether.
Comment #3
Anonymous (not verified) CreditAttribution: Anonymous commentedComment #4
Jody LynnI think this is still an issue.
I also don't like how the main help.module-related code is this menu_get_active_help that isn't in help.module.
Comment #5
dawehnerThis is all in
\Drupal\help\Plugin\Block\HelpBlock::getActiveHelp
nowComment #6
jhodgdonupdating title and summary
Comment #15
catchThe new help system will resolve this one, once #3031642: Deprecate hook_help() and combine with Topics is done. Marking duplicate.