[drupal-devel] menu system idea

Gerhard Killesreiter killesreiter at physik.uni-freiburg.de
Sun Jun 19 09:15:57 UTC 2005



On Sun, 19 Jun 2005, Dries Buytaert wrote:

>
> On 19 Jun 2005, at 10:26, Robert Douglass wrote:
> > The nested arrays don't bother me. How much work would one have to
> > do in this direction before we would be able to 1) measure
> > performance and 2) rule out any "gottchas" that would make it less
> > attractive than it initially seems?
>
> I agree.  We can't really tell it is an improvement until it has been
> tested.  I think it actually might fix a number of gottchas.
> Example: because modules get loaded in random order, a menu item's
> parent might only become available after the child has been loaded.
> Therefore, the current menu system first stores all menu items in a
> sequential array, and only builds the hierarchy of menu items after
> all modules have returned their menus.

I don't see how this could be improved using Adrian's arrays.

> The current menu system has two important drawbacks:
>    1. it is slow -- we had to add menu caching, but even with caching
> it is slow.

If Adrian's scheme can improve performance, I'd be all for it. I'd still
the code is ugly, but ...

>    2. it is complex -- it tends to be difficult to make simple changes.

One change I'd like to see is that permissions also apply to child menu
items. For example the user permission "access administration pages"
applies to the path "admin", but not to any of the child menu items.

Cheers,
	Gerhard




More information about the drupal-devel mailing list