Comments? Feedback?

This wiki does not yet support public comments (a limitation of Google Sites), so we encourage you to post your comments either:

On Twitter by responding to @orbeon.

On our community mailing list: subscribe sending an email to ops-users-subscribe@ow2.org (content of subject/body doesn't matter), you'll get a response with the email to use to send your message to the community mailing list.

Recent site activity

XForms Document Lifecycle

Concepts

  • a live XForms document is always associated with a session
  • the document may or may not be serialized in state store

Ajax requests and synchronization

2011-04-06
  • each document associates in the session
    • uuid
    • lock
  • each incoming Ajax request
    • obtains the lock
    • takes document from cache or store
      • if from cache, removed from cache (takeValid())
        • nobody can then remove us or evict us from cache
      • tricky: the lock is also used by the cache
        • philosophy: if we have the lock, we can't be evicted by another thread
        • we don't want to be evicted from cache between getting the lock and between taking from the cache, otherwise we won't find the document ever again
        • worst case scenario: cache may grow if nobody can be evicted, but that's ok, because soon after we take the document from the cache anyway
    • performs operations
    • if success, re-adds document to the cache
    • if failure, don't add document to the cache
    • releases lock

Fatal errors

Upon a fatal error during an Ajax request, the document is not put back into the cache.

Fatal errors should be few. As of 2011-04, there are probably too many such errors (like some XPath expressions evaluation issues). Possibly this should be relaxed a bit.