Defines the access to underlying datastore. This datastore is Tamino by default.
An XConnection wraps a connection to Tamino. It is identified by Thread_id, database URI and user/password. An XConnection may be re-used, until it is commited and closed.
Holds several XConnections. Is responsible, that different XDbSessions may share the same XConnection, if they run in the same transaction and on the same database, for example if you move a resource from one store into another store pointing to the same Tamino with the same user. When a commit is done to an XConnection, it is removed from XConnectionPool.
An XDbSession is bound to one task of one store. It has a reference to an XConnection, which it may share with another XDbSession, if the other session runs in the same transaction. XDbSession handles the create, read, update and delete requests for content and metadata (descriptors). An XDbSession lives until a commit is done or if another session has closed this session's XConnection.
Each store has one XDbHandler. A handler has one XUtilDbSession for common tasks (check, if a schema is available for a specific doctype for example) and a list of XDbSessions for each thread.
There are some WebDAV commands, that have no transaction handling (GET, PROPFIND, HEAD). Commands with write access (PUT, PROPPATCH, ...) . One transaction runs always in one thread. When a store has to process for example a PUT, XDbHandler creates an XDbSession and stores it in a map with the thread-id as key. An XDbConnection is allocated and associated with the session. The first write command opens the transaction. A commit or rollback closes the transaction, cleans up XConnection and removes XDbSession.
If more than one store is involved in a transaction (MOVE from one store to anoteher, versionning stuff, ...), they run in the same thread. If both stores are configured to the same Tamino with the same user/pwd, they share one XConnection. So a two phase commit can be avoided.
This package and subpackages are the only packages, that deals with Tamino calls.