During a redeploy, all sessions are destroyed (and not serialized), unless you explicitly request that all active sessions be preserved during the redeploy, by specifying "keepSessions=true", as follows:
asadmin redeploy --properties keepSessions=true
in which case the sessions are serialized, and the serialized representations stored in memory for the duration of the redeploy.
Notice that the "keepSessions" redeploy property was added only recently, so I doubt you are using it.
Are you perhaps talking about a server restart?
In this case, all active sessions are serialized and written to file (even if the session persistence type is "memory"), and restored following the restart.
See
http://blogs.sun.com/jluehe/entry/how_to_disable_persisting_of
for how to disable this behaviour.
Thanks!
[Message sent by forum member 'jluehe' (jluehe)]
http://forums.java.net/jive/thread.jspa?messageID=302364