[Twisted-Python] Leaking memory with twisted-web

Christopher Armstrong radix at twistedmatrix.com
Wed Oct 8 05:59:03 EDT 2003


On Wed, Oct 08, 2003 at 05:27:34AM -0400, Alex Levy wrote:
> On Wed, 2003-10-08 at 04:38, Christopher Armstrong wrote:
> > I think I know what's happening. Do a "netstat |grep twistd-web-pb".
> 
> On Wed, 2003-10-08 at 05:11, Alex Levy wrote: 
> > This is indeed what's happening.
> 
> I spoke too soon. It looks like the bug you mentioned occurs in
> UserDirectory; I'm not using that. I'm simply using ResourceSubscription
> and ResourcePublisher. Should I _not_ be doing this? Or is there another
> solution to the problem?

Well... You might be using it in a bad way. Are you creating a new
ResourceSubscription for every request? If you are, you need to
persist them, probably by using 

  r.putChild('name', resourceSubscription) 

where `r' is already a persistent resource.


-- 
 Twisted | Christopher Armstrong: International Man of Twistery
  Radix  |          Release Manager,  Twisted Project
---------+            http://radix.twistedmatrix.com




More information about the Twisted-Python mailing list