transaction services in component frameworks n.
Download
Skip this Video
Loading SlideShow in 5 Seconds..
Transaction Services in Component Frameworks PowerPoint Presentation
Download Presentation
Transaction Services in Component Frameworks

Loading in 2 Seconds...

play fullscreen
1 / 28

Transaction Services in Component Frameworks - PowerPoint PPT Presentation


  • 125 Views
  • Uploaded on

Transaction Services in Component Frameworks. Bruce Kessler Comp250CBS March 2, 2004. Overview. Transactions as Concept A Transaction Standard Transactions in CORBA Transactions in EJB Transactions in COM. Transactions as Concept. Definition

loader
I am the owner, or an agent authorized to act on behalf of the owner, of the copyrighted work described.
capcha
Download Presentation

PowerPoint Slideshow about 'Transaction Services in Component Frameworks' - bijan


An Image/Link below is provided (as is) to download presentation

Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author.While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server.


- - - - - - - - - - - - - - - - - - - - - - - - - - E N D - - - - - - - - - - - - - - - - - - - - - - - - - -
Presentation Transcript
transaction services in component frameworks

Transaction Services in Component Frameworks

Bruce Kessler

Comp250CBS

March 2, 2004

overview
Overview
  • Transactions as Concept
  • A Transaction Standard
  • Transactions in CORBA
  • Transactions in EJB
  • Transactions in COM
transactions as concept
Transactions as Concept
  • Definition
    • “An atomic unit of work. The work in a transaction must be completed as a whole; if any part of the transaction fails, the entire transaction fails.” - MSDN ODBC Glossary
  • The standard that applies to Transactions is the ACID definition.
transactions as concept1
Transactions as Concept
  • ACID is an acronym describing attributes of a transaction:
    • ATOMIC
    • CONSISTENT
    • ISOLATED
    • DURABLE
transactions as concept2
Transactions As Concept
  • The concept of transactions grew out of RDBMS systems. Given the encapsulation and use of databases the concept fits cleanly.
  • In component frameworks guaranteeing the same reliability across components for a distributed transaction is more difficult.
transactions as concept3
Transactions as Concept
  • For Example:
    • Three systems across a distributed network that need to work in unison and guarantee that they have all completed their work before anyone can commit. If the network goes down, the rollback procedure has to be defined by the framework.
transactions as concept4
Transactions as Concept
  • For Example:
    • In a bank transaction there is a component that updates customer accounts and then another component that formats and prints checks. The output of this component is a printed check. If a rollback is called for by the account component, the check has to be ‘rolled back’.
transaction as concept
Transaction as Concept
  • Given the diversity of the component environment, how do you handle transaction processing and guarantee the data?
transaction as concept1
Transaction as Concept
  • Given the diversity of the component environment, how do you handle transaction processing and guarantee the data?
  • Transaction Standards
a transaction standard
A Transaction Standard
  • A transaction standard shared by CORBA, EJB, and the COM framework is called XA.
  • XA is a Distributed Transaction Processing (DTP) protocol specified by the X/Open Organization.
  • The standard is now maintained by the Open Group.
a transaction standard1
A Transaction Standard
  • X/Open is known for being the standards body for the X Windowing System.
  • XA started as a system to allow for concurrency in operating systems. It was designed with an operating system component framework in mind.
a transaction standard2
A Transaction Standard
  • The parts of the XA standard are:
    • Application Program (AP)
    • Transaction Manager (TM)
    • Resource Manager (RM)
      • (eg RDBMS, File System)
  • The XA standard defines the interaction between the TM and the RM.
a transaction standard3
A Transaction Standard

From Distributed Transaction Processing : The XA Specification from the Open Group

a transaction standard4
A Transaction Standard
  • The fundamental process that underlies DTP is the two-phase commit.
    • Phase 1: Poll all resources to determine whether they are able to commit. If one is not able to commit, all resources rollback.
    • Phase 2: If all resources can commit, then send the commit signal to all resources. The resource then returns whether it committed successfully.
overview1
Overview
  • Transactions as Concept
  • A Transaction Standard
  • Transactions in CORBA
  • Transactions in EJB
  • Transactions in COM
transactions in corba
Transactions in CORBA
  • CORBA implements the XA DTP standard.
  • Objects in CORBA can opt out of providing support for transactions, even in the context of a transaction taking place in other objects in the same context.
  • The following diagram is from the OMG’s Transaction Service Specification v1.4 Sept. 2003
transactions in corba2
Transactions in CORBA
  • The Transaction Service in CORBA is required to support flat transactions, but there is a description of nested transactions in the specification.
  • Nested Transactions are transactions that have a hierarchical relationship with each other, that allow parts to rollback independently of other parts.
transactions in corba3
Transactions in CORBA
  • An example of a nested transaction would allow a ‘parent’ transaction that encapsulates a ‘child’ transaction to continue if part of the ‘child’ transaction fails.
  • Nested Transactions allow systems to carry out transactions that may have partially failed, but are still acceptable for a commit.
overview2
Overview
  • Transactions as Concept
  • A Transaction Standard
  • Transactions in CORBA
  • Transactions in EJB
  • Transactions in COM
transactions in ejb
Transactions in EJB
  • Enterprise Java Beans (EJB) use their containers to implement transactions but it is interoperable with the XA Standard.
  • EJB Containers allow transaction management to be done with the Java Transaction API (JTA) which is a XA compliant implementation or through the container itself.
transactions in ejb1
Transactions in EJB
  • Containers allow two types of transactions:
    • Container Managed Transactions – which is usually configured in the ejb-jar.xml file and leaves transactions to the Container. Options are:
      • NotSupported
      • Supports
      • Requires
      • RequiresNew
      • Mandatory
      • Never
transactions in ejb2
Transactions in EJB
  • Additionally, transactions can be managed by beans themselves using EJB methods that allow DTP within the application server.
overview3
Overview
  • Transactions as Concept
  • A Transaction Standard
  • Transactions in CORBA
  • Transactions in EJB
  • Transactions in COM
transactions in com
Transactions in COM
  • COM supports transactions through the Microsoft Transaction Server (MTS), which is also based on the XA standard.
  • MTS allows COM components to act as resources in the XA resource model, with itself as the transaction manager.
  • MTS is now incorporated into COM+.
transactions in com1
Transactions in COM
  • In terms of the XA framework, COM components are resources to be managed and the transaction manager is the Distributed Transaction Coordinator (DTC).
  • The DTC is responsible for handling distributed transactions and error recovery. Think of it as being like the container in EJB.
transactions in com2
Transactions in COM
  • In COM+ there is a concept of Bring Your Own Transaction.
  • This means that transaction contexts can be assigned to components dynamically and they can inherit them from other components.
  • For example, a transaction that is happening within a CORBA OTS, could be associated with a COM+ component and the framework could accept this as the transaction context.
references
References
  • Transaction Service Specification from OMG, v1.4 Sept 2003
  • Distributed Transaction Processing : The XA Specification from the Open Group
  • Java Transaction API Specification from Sun Microsystems
  • COM+ Documentation from MSDN (msdn.microsoft.com)