Transaction Manager

Why Trust Techopedia

What Does Transaction Manager Mean?

A transaction manager is a part of an application that controls the coordination of transactions over one or more resources. The transaction manager is responsible for creating transaction objects and managing their durability and atomicity. Transaction managers keep track of all the resource managers that are enlisted in a transaction.

Advertisements

Techopedia Explains Transaction Manager

When instructed to commit a transaction, transaction managers kick off the two-phase commit protocol. In the first phase, they ask all enlisted resource managers to prepare. In the second phase, the transaction managers notify the resource managers if the transaction is aborted or committed.

A transaction manager maintains a log in storage. This log is usually a sequential file, which is used to record the transaction events. Transaction managers use this log for recording transaction starts, commit decisions, enlistments, etc. At the time of normal processing, transaction managers simply write to the log, but if they fail, they read the log as soon as it restarts to restore the latest state.

Transaction managers often have the following responsibilities:

  • Demarcation: Starting and finishing transactions by means of begin, commit and rollback methods.
  • Controlling the Transaction Context: Transaction contexts contain all the information that helps a transaction manager to monitor a transaction. Transaction managers are in charge of building transaction contexts and connecting them to the existing thread.
  • Coordinating the Transaction: Transaction managers generally have the ability to harmonize a transaction over various resources. This feature demands the two-phase commit protocol. XA protocol is also used to register and manage the resources.
  • Recovery From Failure: Transaction managers are accountable to guarantee that the resources are not kept in an inconsistent state in case of a system or application failure.
Advertisements

Related Terms

Margaret Rouse
Technology Specialist
Margaret Rouse
Technology Specialist

Margaret is an award-winning writer and educator known for her ability to explain complex technical topics to a non-technical business audience. Over the past twenty years, her IT definitions have been published by Que in an encyclopedia of technology terms and cited in articles in the New York Times, Time Magazine, USA Today, ZDNet, PC Magazine, and Discovery Magazine. She joined Techopedia in 2011. Margaret’s idea of ​​a fun day is to help IT and business professionals to learn to speak each other’s highly specialized languages.