I really should read this stuff more careful :)
On 9/16/07, Igor Vaynberg <[EMAIL PROTECTED]> wrote: > the value is cached per request not per session > > also since the security policy is more global then the request it is harder > for it to cache on that level because it is a more granular level. Not necessarily you can just as easily have a permission for an entire page as for a single component. >you would > need something like a threadlocal with a map:component->boolean, and since > strategy is not aware of request lifecycle it would be hard for it to clean > the threadlocal. Maybe i'm focusing to much on wasp/swarm but i don't see why see why the security should be aware of the request lifecycle provided any and all changes to the permissions of a user go through the security layer, which i think is not a lot to ask for. This means the security layer can implements its caching in the session (i know the session is a threadlocal) or in a private store somewhere else it would not matter. Anyway to get back to what you first said. I agree that wicket caching the results from the security layer for the duration of the request should not be a problem but wonder if it is necessary. Maurice > > -igor > > > On 9/16/07, Maurice Marrink <[EMAIL PROTECTED]> wrote: > > > > Should it not be the responsibility of the security layer to cache > > that value if it is indeed such an expensive lookup? > > > > This same logic / problem would apply to all security inquiries wicket > > makes. > > > > Also it is not unthinkable that this value changes during a user > > session, just think of the su command in linux. wicket caching this > > value would complicate matters in those situations. the security layer > > oth will probably know / support this kind of changes to the > > authorization of a person and will be able to keep its internal > > bookkeeping / caching up to date. > > > > just my 2 cents. > > > > Maurice > > > > On 9/16/07, Igor Vaynberg <[EMAIL PROTECTED]> wrote: > > > wasnt the idea to do a pass one time and cache the value for the > > request? > > > because the lookup might be expensive. > > > > > > i wish we did that with isvisible, etc too :) > > > > > > -igor > > > > > > > > > On 9/16/07, Matej Knopp <[EMAIL PROTECTED]> wrote: > > > > > > > > Hi, > > > > > > > > is there a good reason why we traverse entire hierarchy and call > > > > setRenderAllowed on every component, when we could just change > > > > isRenderAllowed() to ask authorization strategy? > > > > > > > > -Matej > > > > > > > > > >
