Object lifecyclesΒΆ

Plone has different lifecycles for different objects

  • Persistent objects: These objects are transparently persistent. They look like normal Python objects, but they are serialized to the disk if the transaction completes successfully. Persistent object inherit from Zope's various persistent classes: persistent.Persistent, PersistentDict, PersistentList and they have special attributes like _p_mtime when the object was last written to disk. To make object persistent, it must be refered from Zope's App traversing graph. Examples: content objects, user account objects.
  • Request attached objects and thread-local objects: Each HTTP request is processed by its own Python thread. These objects disappear when the request has been procesed. Examples: request object itself, getSite() thread-local way to access the site object, request specific permission caches.
  • In-process objects, or "static" objects are created when the server application is launched and they are gone when the application quits. Usually these objects are set-up during Plone initialization and they are read-only for served HTTP requests. Examples: content type vocabulary lists.

About Plone

This is documentation for Plone®. Plone is a popular, open source, content management system written in Python programming language.




Edit this document

The source code of this file is hosted on GitHub. Everyone can update and fix errors in this document with few clicks - no downloads needed.

  1. Go to Object lifecycles on GitHub.
  2. Press Fork and edit this file button.
  3. Edit file contents using GitHub's text editor in your web browserm
  4. Fill in the Commit message text box at the end of the page telling why you did the changes. Press Propose file change button next to it when done.
  5. On Send a pull request page you don't need to fill in text anymore. Just press Send pull request button.
  6. Your changes are now queued for review under project's Pull requests tab on Github.

For basic information about updating this manual and Sphinx format please see Writing and updating the manual guide.