[Zope3-Users] zodb is growing every login/logout

Jens adner at fh-schmalkalden.de
Wed Apr 22 03:15:56 EDT 2009


@Paul: yes, ZODB just grow after login and logout.

@Nikolay: Yes, I'm using the default persistent zope3 session. This was
also my first idea, and I switched to a RAM Session, but it had no effects.

I tested the RAM Session by restart zope, and I where logged out after
restart (so I think the RAM session is working by losing the
login-data). But the ZODB was growing again.

Here is my code to switch the session and my session class:

-------------------------------------------------------------
#from zope.session.session import RAMSessionDataContainer
from zope.session.session import PersistentSessionDataContainer

class MySession(PersistentSessionDataContainer):
  timeout=5*60*6
  def __init__(self):
    super(MySession,self).__init__()
    # timeout session 5 minuten:
    self.timeout=MySession.timeout
    self.resolution=1*60
---------------------------------------------------

But i switched just in the app, maybe I have to change the global
session in zope?

Thanks for your help
Jens

Paul Winkler schrieb:
> On Tue, Apr 21, 2009 at 04:36:01PM +0200, Jens wrote:
>> Hello everybody,
>>
>> I'm building a small web app by using the great grok.zope.org.
>>
>> This is what I want to do:
>>
>> An ldap-user login, do something (change password etc) and logout. No
>> data will be stored in the zodb, all changes are made in ldap.
>>
>> So far so good, all works fine. I'm using ldappas and ldapadapter as an
>> PAU for zope3.
>>
>> Just a small problem, maybe someone can help me.
>>
>> Every login and logout, the ZODB grow about 300Byte. After some logins,
>> the ZODB is getting bigger and bigger, and I have to pack it manually.
> 
> Are you sure it's just logins?  I had a problem with Grok of ZODB
> bloat on every single request. Upgrading to zope.annotation>=3.4.1
> fixed it.
> 
> We weren't using LDAP though. Might be unrelated to your problem.
> 
> 


More information about the Zope3-users mailing list