On Monday 26 December 2005 01:57 pm, Bèr Kessels wrote:
So, I get from this, that we will have to live with the inconsistency. And I will probably (?) not be able to write a tag - tid mapping module that rewrites the urls. Because honestly, a module cannot have that function. It /will/ break! It would mean that my module exludes any module that wants to do something (remotely) similar.
An I think it is indeed not i18n specific as my use case very well points out. Another use case would be to map /user/CHX to user/12345. Again. This is not possible atm. (though this could possibly be stored in the database, IMO its a silly and odd overkil)
I agree completely, Ber. This topic came up on the dev list a few weeks ago as well when discussing the limitations of path and pathauto. The basic problem is that they don't scale well, particularly for dynamic content. Making /user/myname/* work for all /user/ functions, just in core, using url_alias, would require at minimum 4 records per user. (view, edit, track, contact, plus some number of profile pages.) Putting that in url_alias is simply not going to scale past a few hundred users. Try it on drupal.org (45000 users and counting), and it dies horribly. I did spend some time trying to implement it manually for the user module, actually (usernames are unique, so they can be used in place of uids in URLs without increasing the number of db hits), but ended up creating all sorts of strange and mysterious errors I couldn't identify so I eventually abandoned it. (It also had to be all-or-nothing, or other user-extending modules wouldn't work either.) The performance concern is real, though, given the number of links a typical page has. Some fast, well-cached module-based rewrite mechanism is needed, I agree. Perhaps just prefix-based? I've been trying to avoid proposing anything at this point, though, as any changes now would just slow down the release of 4.7. :-) -- Larry Garfield AIM: LOLG42 larry@garfieldtech.com ICQ: 6817012 "If nature has made any one thing less susceptible than all others of exclusive property, it is the action of the thinking power called an idea, which an individual may exclusively possess as long as he keeps it to himself; but the moment it is divulged, it forces itself into the possession of every one, and the receiver cannot dispossess himself of it." -- Thomas Jefferson