Seems like an odd request. Assuming you are storing the ASO in the session (the only option with the default implementatons), then you (or the servlet API) must already know the session id (i.e., from the request object, from cookie in the request). So storing it in the ASO isn't useful.
You could just have a String field in your ASO and when you first create your ASO, get the session id from the HttpServletRequest and store it into the ASO. On Mon, May 5, 2008 at 1:24 PM, Shing Hing Man <[EMAIL PROTECTED]> wrote: > I need to retrieve the http session id. One way to get > session id is to inject > RequestGlobals into my page and then get the > HttpRequest from RequestGlobals. > > For simplicity sake, I try to inject the httpRquest > into an exisitng (session) ASO X > (which is already injected to my page) and > retrieve the session id from X. > With the above approach, I found that the ASO X for > different users always return identical > session id (the id of the first session created.) > Is there a way to store HttpRequest (or session id), > in ASO X, so that the > HtppRequest (or session id) is 'in sync' with the > session. > > > In AppModule : > public void contributeApplicationStateManager( > MappedConfiguration<Class, > ApplicationStateContribution> configuration, > final @Inject @Value("${tempDir}") String > tempDir, > final @Inject RequestGlobals requestGlobals) > { > > HttpServletRequest request = > requestGlobals.getHTTPServletRequest(); > > ApplicationStateCreator<IUserDirManager> creator > = > new UserDirManagerCreator(request, tempDir); > > > configuration.add(IUserDirManager.class, new > ApplicationStateContribution("session", creator)); > } > > > Thanks in advance for any assistance ! > > Shing > > Home page : http://www.lombok.demon.co.uk/ > > > > > __________________________________________________________ > Sent from Yahoo! Mail. > A Smarter Email http://uk.docs.yahoo.com/nowyoucan.html > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > -- Howard M. Lewis Ship Creator Apache Tapestry and Apache HiveMind --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]