RE: [PEAR-DEV] liveUser (was: Re: permissions managment)
| From: | Lukas Smith | Date: | Tue, 13 Aug 2002 10:15:50 +0000 |
| Subject: | RE: [PEAR-DEV] liveUser (was: Re: permissions managment) | ||
| References: | 1 | Groups: | php.pear.dev |
| Request: | Send a blank email to pear-dev+get-8353@lists.php.net to get a copy of this message | ||
If I understand the class correctly it first gets all user rights and
then flattens everything. This is quite nice because it simplifies
things, since then it is much easier to handle user and group rights.
There is just one problem with this:
It creates a lot of work to do this even though most of the time only
1-2 rights will be requested per page load.
Would an on demand system not be better?
This would mean it would always check the backend if the user has the
necessary rights if needed.
Obviously this would be faster if only one check was made. It might even
be faster if 2 or even 3 rights where to be requested. At some point
obviously getting everything in bulk would be faster.
Dunno if its feasible to provide both approaches. It would probably
require modularizing things here and there.
Anyways I would definitely write the class so that it would first hit
the backend when the first real check is done. From looking at the
source this does not seem to be the case ATM, but the usage example
seems to never do readRights()?
I have actually just written a concept for something similar for my
company (in german). I am now considering refocusing my work towards
this system (gotta get that competitive advantage somewhere else then
:-) )
Regards,
Lukas