[ZODB-Dev] ZEO client leaking memory?

Jeremy Hylton jeremy@zope.com
Fri, 12 Oct 2001 12:53:59 -0400 (EDT)


>>>>> "JH" == Jeremy Hylton <jeremy@zope.com> writes:

  >>> It's hard to tell if this is a problem with ZEO or not.  If the
  >>> client is leaking memory, the leak could be in any of several
  >>> places: in the ClientStorage, in any of the Zope code used by
  >>> the client, or in the applications themselves.

  CW> Yup... how do I go about measuring/narrowing it down?

  JH> We may be able to isolate ClientStorage vs. application by
  JH> performing a storage copy.  Take the FileStorage that contains
  JH> the unpacked transaction data generated by the leaky
  JH> application.  Use the iterator protocol to copy from the
  JH> FileStorage to a new storage using ZEO.  If we see a memory
  JH> leak, we can blame ZEO because the application isn't involved.
  JH> If we don't see a leak, it's more likely that the application is
  JH> leaking.

Jim offered a variant of my suggestion: If you run your job with
FileStorage instead of ZEO and still see a memory leak, then it's
unlikely the ZEO has a leak.

I did a simple test today: I ran speed.py (ZODB/tests/speed.py)
against ZODB for a million repititions.  The memory the client and
storage use appear to be constant.  So I'd guess that ZEO doesn't have
a leak.  It's possible to speed.py isn't hitting whatever part
of ZEO leaks, but I don't think it's likely.

Jeremy