Bienvenido! - Willkommen! - Welcome!

Bitácora Técnica de Tux&Cía., Santa Cruz de la Sierra, BO
Bitácora Central: Tux&Cía.
Bitácora de Información Avanzada: Tux&Cía.-Información
May the source be with you!

Saturday, July 24, 2010

ACID properties

The term ``transaction'' has a specific technical meaning in computer science. It's extremely important that the contents of a database don't get corrupted by software or hardware crashes, and most database software offers protection against such corruption by supporting four useful properties, Atomicity, Consistency, Isolation, and Durability. 
In computer science jargon these four terms are collectively dubbed the ACID properties, forming an acronym from their names.
Definitions of the ACID properties are:
Atomicity
means that any changes to data made during a transaction are all-or-nothing. Either all the changes are applied, or none of them are. If a program makes a bunch of modifications and then crashes, the database won't be partially modified, potentially leaving the data in an inconsistent state; instead all the changes will be forgotten. That's bad, but it's better than having a partially-applied modification put the database into an inconsistent state.
Consistency
means that each transaction executes a valid transformation of the database state. Some databases provide a variety of consistency checks in the database or language; for example, a relational database constraint columns to be of particular types and can enforce relations across tables. Viewed more generally, atomicity and isolation make it possible for applications to provide consistency.
Isolation
means that two programs or threads running in two different transactions cannot see each other's changes until they commit their transactions.
Durability
means that once a transaction has been committed, a subsequent crash will not cause any data to be lost or corrupted.

No comments: