jerrySheen wrote: > Hi, > I have been successful in saving the sessions to my mysql db, using the > given code in my server configuration file. > > <Store className="org.apache.catalina.session.JDBCStore" > > connectionURL="jdbc:mysql://XXXXXXXXX/xxxxxx?user=zzzzz&password=zzzzzz" > driverName="com.mysql.jdbc.Driver" > sessionIdCol="id" > sessionValidCol="valid" > sessionMaxInactiveCol="maxinactive" > sessionLastAccessedCol="lastaccess" > sessionTable = "app_sessions" > sessionAppCol = "context" > sessionDataCol = "data" > /> > this stores the session data as a blob in the db. So my questions are, > > Can we assign the blob data directly to a new session, so that this new > session assumes the state of the session in the db?
Why? The session manager should be doing this for you. > Can we retrieve and edit information from the blob? Why? The risk is that you will introduce inconsistencies into live sessions. Surely modifying the session using the API provided by the Servlet spec is a) safer and b) easier. > if YES, please furnish some sample code or at least direct me towards the > solutions. > if NO, what other ways can we go about, to achieve session persistence(not > just validation as in cookies but a complete session state snapshot). Isn't that happening now? p p.s. tomcat version, jvm version, os version? --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org