Skip to main content

Plone 4, ZEO and tempstorage

This is reminder for myself and hopefully for other people too so that they don't have to waste several hours of valuable time looking for this simple piece of information.

If you have experience setting up Plone 3 with ZEO and tempstorage (so that your sessions won't disappear in the middle of hardcore content managing) you might have trouble setting up same kind of setup while using Plone 4.

Thanks to David Glick who enlightened  me that plone.recipe.zeoserver doesn't include whole Zope 2 in it's Python environment anymore. In this specific scenario this means that even though you have tempstorage in your eggs folder it isn't included in pythonpath when zeoserver part is being processed and this leads to below error message:

Error: could not load package tempstorage: No module named tempstorage
Package name: 'tempstorage'
File name: 'component.xml'
Package path: None
For help, use bin/zeo-server -h


Solution to this is to add this simple oneliner to your buildout.cfg zeoserver part:


[zeoserver]
...
eggs = tempstorage
...

Comments

  1. I thought this kind of trick was needed for Plone2.5 and earlier versions, but not for Plone3.

    Plone3 with plone.session doesn't use the Zope2-session-machinery and tempstorage? (except when your own code uses it explicitly)

    ReplyDelete
  2. Almost no code in Plone 3 uses REQUEST.SESSION, and really no code in Plone 4 does.

    So you only need tempstorage if any custom code makes use of this.

    ReplyDelete
  3. Hmm.. maybe my information about this specific topic is out of date (I wouldn't be surprised).

    I've thought that when you're using zeo with loadbalancing you'll need some way to keep logged in users session available regardless of which backend user ends up. I guess I'll try to dig some more information about this.

    ReplyDelete
  4. Thank you for this post! Saved me those 4 hours :)

    ReplyDelete

Post a Comment

Popular posts from this blog

Speed comparsions between Plone and Wordpress

Jon Stahl wrote recently a blogpost about Plone being three times faster than Dropal, Joomla and Wordpress . We had a small discussion about this in my workplace and as my colleague pointed out this wasn't a really that comprehensive test that you could state Plone being 3 times faster than it's competitors. This seemed a bit unfair test considering how fast this has been spread in tweet/blogosphere, so I decided to repeat the test with a bit more critical viewpoint. What's wrong in the original test? No one would consider opinion poll with 10 answers nowhere near trustworthy - it's all the same with requests. I didn't want to put up all the cms so I just set up second best (Wordpress 2.9.1) and compared that to my Plone development site (4.0a3). As a comparsion I did the first test with same ab command Jon used and my iMac gave following results: Wordpress: 7.13 requests / second Plone: 17.10 requests / second So far we have clear winner and Jons data hol

Usability and Plone

I've seen in here and there someone mentioning that usability of Plone is very good. Lot's of people - me included - like the fact that in Plone you don't have separate content management interface compared to some of Plones rivals. That counts for something when we're talking about good usability. Still that is only one quite small part of the whole picture. So what else is there? What do people like in Plone and where are the rough edges for end users? If general consensus is that Plone does have good usability, where is the actual proof of that? On plone.org I found one page in developer documentation mentioning following:  "Plone differentiates itself on usability. The intuitiveness of the user interface is what attracts people to Plone the most." I interpret this sentence meaning about the "one view for all" approach. What bugs me in this is that this whole sentence about good usability is about how the UI works compared to Plones competi

Problems with Plone version pinning

Since we splitted our one huge Plone site to several smaller ones we've been looking for the correct procedure to keep things running smoothly and to make updates as painless as possible. So far we haven't found the right way and every update has had some problems. Some of the problems are related to the fact that we have about 24 sites to maintain and adding a new content type to all of them means lots of work. Below are all the steps needed for update (and solutions we've founded so far). 1. Add your new product to buildout.cfg eggs and zcml list. Do this 24 times and you'll find yourself thinking there has to be better way. Luckily there is; you can extend your buildout.cfg with some general config file (eg. deployement.cfg). Most tutorials describe a way where you have those two files living side by side in filesystem and you run buildout with -c deployement.cfg option, but this doesn't remove the actual problem. We have our deployement.cfg living in diffe