[drupal-devel] [feature] Speed up Drupal and improve scalability:
On demand module loading
Jose A Reyero
drupal-devel at drupal.org
Sun Jul 31 15:43:16 UTC 2005
Issue status update for
http://drupal.org/node/27901
Post a follow up:
http://drupal.org/project/comments/add/27901
Project: Drupal
Version: cvs
Component: module system
Category: feature requests
Priority: normal
Assigned to: Anonymous
Reported by: Jose A Reyero
Updated by: Jose A Reyero
Status: patch (code needs review)
Attachment: http://drupal.org/files/issues/on_demand_module_loading.patch (7.8 KB)
As Drupal grows bigger, there is too much code not really needed parsed
for each request.
Also, installing more and more modules presents serious scalability
issues, as all the enabled modules are included always for each non
cached page.
This is a first attempt to keep track of *all* module hooks, and only
load modules when they're really needed. I guess it may need some
polishing but the idea is simple enough.
Currently, as the hook_menu is implemented by most of the modules, and
it is called most of the times, the potential performance improvement
introduced by this mechanism may be small.
But the thing is, once he have some system for on demand module
loading, hooks can be reworked in the future, to have some real
performance boost. I.e. hook_menu could be easily split in two
'hook_menu' and 'hook_menu_dynamic', thus really reducing acually
loaded modules.
As I said, this is a first step. If there's some interest in this kind
of features, I have some other things in the works aimed at performance
and scalability, like:
- (Simple) Rework of menu system to take real advantage of on demand
module loading
- Expand menu items to be able to include some file where the callback
is in
- Extend module loading for 'loading on path', and maybe 'loading split
modules'
- Some API loader, kind of api_invoke....
Jose A Reyero
More information about the drupal-devel
mailing list