We've been using Terracotta Sessions with Wicket successfully for some time
now with a fairly onerous side effect. The DiskPageStore temporary directory
grows steadily and never gets cleaned up, eventually leading to us having to
manually go and clean up the directory.

The issue appears to be that if a session fails over to the other node it
maintains the sessionid from the other server (as expected) however, because
we use sticky sessions via the jvmRoute in tomcat a session ID looks like
"2uWDurCx3V07Oe8LBn0V.node1" even if its currently on node2.

Therefore when the unbind/cleanup method of DiskPageStore/SessionEntry
attempts to clean it up it doesn't find anything and leaves the orphaned
session on the node where the session originated.

I was thinking that a easy fix for this would be to extend the DiskPageStore
and have it ignore the jvmRoute when serializing the session. Does this
sound like a good idea?

Thanks.

Jeremy



-- 
Jeremy Levy

Reply via email to