-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 [EMAIL PROTECTED] escribió: > I am using Jetspeed 2.0 with wsrp4j consumer talking to a Tomcat instance > with the wsrp4j producer deployed. When I've logged into Jetspeed, it sends > the following fragment in the <getMarkup> message: > > <userContext> > <userContextKey>admin</userContextKey> > </userContext> > > where "admin" is the Jetspeed username. This is what I expect and I've tested > that Oracle Portal 10g does the same thing. > > The question is: how can I get access to the user from within my JSR-168 > portlet? > > Looking at the wsrp4j code, the UserContext is placed in a > DynamicInformationProviderImpl object and this is set as an attribute called > "org.apache.pluto.portalImpl.DynamicInformationProvider" on the request. > However, this class does not expose the UserContext. > > The Pluto RenderResponseImpl is extended by WSRPRenderResponseImpl but the > same isn't done for RenderRequestImpl so getRemoteUser() returns null. > > Am I missing something? > > Regards, > Terry
I'm not sure if producer exposes this functionality right now (but it should). Theoretically, you should be able to get the user information through the request.getAttribute(PortletRequest.USER_INFO) object, but as I say I don't know if producer maps this info right now. I'll try to take a look at the code this week, but I can't promise anything. Regards. Diego. -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.2.2 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iD8DBQFFdoLvgyzZYflJelERAugNAJ43Do55KwC1ztCTDn3mDbMmxlcUCACgnJTN h3FF5TVaGG8TvSvdsMuDV6M= =LbWR -----END PGP SIGNATURE-----
