RLock leakage with CP 3.0

1 view
Skip to first unread message

Bill Gribble

unread,
Jul 8, 2008, 2:50:01 PM7/8/08
to cherryp...@googlegroups.com
Hi, I'm using RamSessions with my CherryPy app and the most excellent
Dowser has revealed to me that I am leaking RLocks. I followed through
to the Trace page and it looks like the locks in question are ones
stored in the RamSession.locks dict.

The way I read the RamSession.clean_up code, the lock will never be
unreferenced from this dict unless I have first called save() at least
once on the session (to put a key in the RamSession.cache dict). Since
I never call save() on my sessions (what's the point, with a
RamSession?), the locks persist forever.

I can change my code to call save(), which is probably nice in case I
ever switch to a persistent session storage, but I thought I would point
this behavior out since it could be considered to be a bug.

Thanks,
Bill Gribble

Robert Brewer

unread,
Jul 8, 2008, 3:20:40 PM7/8/08
to cherryp...@googlegroups.com

Good analysis. Would you please make a ticket?


Robert Brewer
fuma...@aminus.org

Reply all
Reply to author
Forward
0 new messages