as long as you don't have a clustered environment or session persistence enabled in your servlet container, there shouldn't be much difference in adding an object to a session or request.
but it doesn't make sense to put it in session scope if you don't use it is session scope, but only in request scope. this could make your life harder than you want it to be (e.g. if you forget to delete such objects). this leads to one issue for session scope: if you store things in session, you HAVE TO REMOVE them as soon as you don't need them anymore, otherwise you can run out of memory because these objects won't be garbage collected. and usually it's very hard to make sure that your web app DEFINITELY reaches the point of deleting things from a session (think about a user just pressing back or going to a different page before hitting your "remove" page). of course, everything will be dumped when the session expires, but if you have a lot of users in your web app and they stay for a long time, the memory consuption can become significant if you have a lot of session objects. kr, guenther -----Original Message----- From: wo_shi_ni_ba_ba [mailto:[EMAIL PROTECTED] Sent: Thursday, March 10, 2005 10:52 PM To: user@struts.apache.org Subject: session and request scope In terms of performance, does storing an attribute into the session cost more than storing it into the request? how significant is the overhead? __________________________________ Do you Yahoo!? Yahoo! Small Business - Try our new resources site! http://smallbusiness.yahoo.com/resources/ --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]