Hi, we have a development server and a production server. I'm currently developing a zclass-only product. To install it on the production server, I make a zexp off my dev-machine and import it on the prodcution server. This works _once_, because if I try to import a new version of the same product zexp, I naturally get an error, as the product is already installed. I can delete the old version and re-import the new version of course but with my zclasses being some kind of static superclasses of their instances, what happens to these? Answer: as long as the zope process is running between deleting the old version and importing the new one, everything's fine. But if zope dies for some reason, all my instances are gone !? So: how do YOU update zclass-based products between a development and a production server? Can it be that there's no intelligent mechanism for that? Am I just too stupid? Thanks, Heiko -- heiko.stoermer@innominate.de innominate AG networkingpeople fon: +49.30.308806-0 fax: -77 web: http://innominate.de
Heiko Stoermer wrote:
I can delete the old version and re-import the new version of course but with my zclasses being some kind of static superclasses of their instances, what happens to these?
They become instances of the new class next time they are reloaded into memory, I think. So some objects may not be updated until the object cache is flushed (or you restart Zope.)
Answer: as long as the zope process is running between deleting the old version and importing the new one, everything's fine. But if zope dies for some reason, all my instances are gone !?
No - they appear as 'broken instances' and will work, in theory, once you reimport the ZClass. Worse comes to worse you just Undo the deletion of the ZClass. We do this all the time - delete on-the-web Product containing ZClasses and reimport new version. It's worked fine until now (and I can't think of any other way of doing this, either.) -- Itamar S.T. itamars@ibm.net
participants (2)
-
Itamar Shtull-Trauring -
news-list.zope.dev@innominate.de