Hi, Justin Edelson wrote > Carsten- > I've only had a few hours to use the new implementation, so I may have more > comments, but my initial comments are: > > * It should be noted somewhere that the default workspace is always used for > authentication. Yepp.
> > * We no longer have an *obvious* place to set the workspace for a request. > When workspace selection was integrated with auth, it was clear (I thought) > that you needed an AuthenticationHandler or an > AuthenticationInfoPostProcessor. But now, workspace selection is detached > from auth, yet auth is the only place within Sling you can effectively do > workspace selection. I had originally thought you could use a Filter, but > Sling Filter processing occurs after resource resolution, so you either have > to use a Filter external to Sling or use the auth extension points > anyway. I would really like my "Selected workspace X because of Y" to be > loggable in RequestProgressTracker, but this won't work if I use a "regular" > Filter. Perhaps we need a new type of Filter that would get invoked before > resource resolution. Ok, I see your point, maybe adding a new type of filters is really a good thing. > > * At first glance, it appears to me that you've removed the "fallback to the > default workspace" logic we had in the script resolver. But I don't actually > use that (and I don't think we have integration tests for it), so I'm not > sure. Removing this fallback is OK with me (Bertrand may feel differently), > but it should be noted in SLING-1446. I think I left it in, at least I wanted to :) > Finally, in terms of returning the real resource resolver, this is OK with > me, but should be done soon. Yes, I first wanted to get some feedback before doing so, but I'll do this rsn. > As I mentioned before, one of my needs is to > get access to a session in the request-specific workspace. First I did: > session = request.getResourceResolver().adaptTo(Session.class) > > then I switched to: > session = request.getResource().getResourceResolver().adaptTo(Session.class) > > now I will need to: > session = request.getResource().adaptTo(Node.class).getSession() > Yes, that's true - but in the end I think this is the better way, even if this requires more method calls :) Regards Carsten -- Carsten Ziegeler [email protected]
