Jump to content

Manual:IDBAccessObject.php

From mediawiki.org

Interface for database access objects.

Classes using this support a set of constants in a bitfield argument to their data loading functions. In general, objects should assume READ_NORMAL if no flags are explicitly given, though certain objects may assume READ_LATEST for common use case or legacy reasons.

There are four types of reads:

  • READ_NORMAL  : Potentially cached read of data (e.g. from a replica DB or stale replica)
  • READ_LATEST  : Up-to-date read as of transaction start (e.g. from primary or a quorum read)
  • READ_LOCKING  : Up-to-date read as of now, that locks (shared) the records
  • READ_EXCLUSIVE : Up-to-date read as of now, that locks (exclusive) the records

All record locks persist for the duration of the transaction.

Extended by

[edit]

Implemented by

[edit]

Public methods

[edit]

None.