[development] Conditionally include include files

Dries Buytaert dries.buytaert at gmail.com
Tue May 22 06:01:58 UTC 2007

Hello world,

I just committed patch http://drupal.org/node/140218, which enables  
us to split module files into multiple (include) files.  With this  
patch, it is the router's (menu system) responsibility to load the  
correct include file -- i.e. the include file that has the active  
callback's code.  In other words, depending on the active callback,  
Drupal can conditionally load include files rather than having to  
load the entire world.

This is an important patch as it enables us to load less code --  
hence, it can offer an important performance boost.  Kudos to all the  
people who helped make this possible.  :-)

The patch that has been committed implements the system to accomplish  
that, but doesn't actually split modules.  There is only one new .inc  
file that has been committed with this patch that acts as an example.

Now this patch landed, the natural next step would be to fire up your  
profilers, and to split a couple more big modules in Drupal core --  
and to report back the performance improvements that you observe with  

Dries Buytaert  ::  http://www.buytaert.net/

More information about the development mailing list