NuoDB Atoms

{question}

How does NuoDB keep the data on the disk?

{question}

{answer}

Everything in NuoDB is made out of Atoms, both Data and Metadata are saved as a unit called Atom.

Any Atom can serialize itself, transmit its serialized contents to a new replica, send replication messages to replicas of itself. TEs operate on Atoms, listen for changes, and communicate changes with other TEs in the database.  The SM allows Atoms to serialize themselves to permanent storage.

Atoms are self-coordinating objects, each represent specific types of information such as:

  • Catalog Atom: Track local and remote atoms, create new atoms, request atom content from peers, manages effective protocol version number.
  • Master Catalog Atom: Catalog responsibilities plus node entry and exit from chorus, atom garbage collection.
  • Transaction Manager Atom: Changing and tracking transaction states.
  • Database Atom: Registry of Schema atoms.
  • Schema Atom: Registry of Table and Sequence atoms.
  • Sequence Atom: Management of SQL sequences.
  • Table Atom: Management of table metadata.
  • Record State Atom: Version and format control for a fixed range of record numbers.
  • Blob State Atom: Control for a fixed range of blob numbers.
  • Data Atom: User data, either row or blob.
  • Schema Atom: Registry of Table and Sequence atoms.
  • Index Atom: B-Tree of atoms each containing an internal B-Tree of key/record number.

Each Atom has a Chairman:
One of the TEs in the database is the Atom Chairman for every Atom, the Atom Chairman coordinates write access to the Atom and serializes write access to prevent data corruption. The first TE to read an Atom from disk is the Chairman. If an Atom Chairman TE fails or the Atom ages out from TE cache, another TE will take Chairmanship for the Atom automatically. Each time a TE in the NuoDB database needs to modify an Atom (such as when writing data), it will request permission from the Chairman.

{answer}

Have more questions? Submit a request

Comments