InfoQ

Minibook

Java Transaction Design Strategies

Posted by Mark Richards on May 14, 2006 11:03 PM

Community
Java
Topics
Transactions Processing
Tags
Spring,
EJB,
JDBC,
Design Patterns

Java Transactions Book Free Downloadable PDF

Understanding how transaction management works in Java and developing an effective transaction design strategy can help to avoid data integrity problems in your applications and databases and ease the pain of inevitable system failures.

This book is about how to design an effective transaction management strategy using the transaction models provided by Java-based frameworks such as EJB and Spring. Techniques, best practices, and pitfalls with each transaction model will be described. In addition, transaction design patterns will bring all these concepts and techniques together and describe how to use these models to effectively manage transactions within your EJB or Spring-based Java applications.  

Free download, buy the print version for $22.95

If you enjoyed reading the free downloadable version, please support the author as well as future InfoQ books by purchasing the print copy for only $22.95 or Login to download this book FREE (PDF)

Table of Contents

Introduction
  • Transaction Models
  • Where’s the ACID, Man?
  • JTA and JTS
  • UserTransaction Interface
  • TransactionManager Interface
  • EJBContext Interface
  • Status Interface
The Local Transaction Model
  • Auto Commit and Connection Management
  • Local Transaction Considerations and Limitations
The Programmatic TransactionModel
  • Obtaining a Reference to the
  • JTA UserTransaction
  • Programmatic Transaction Coding Traps
  • The Transaction Context Problem
  • Programmatic Transaction Scenarios
The Declarative Transaction Model
  • Transaction Attributes
  • Specifying Transaction Attributes
  • Exception Handling and thesetRollback() Method
  • EJB 3.0 Considerations
  • setRollbackOnly() Alternative
  • Using Required vs. Mandatory
  • Transaction Attributes
  • The Reality of Transaction Isolation Levels
XA Transaction Processing
  • The XA Interface Explained
  • When Should You Use XA?
  • Two-Phase Commit
  • Heuristic Exception Processing
  • Enabling Queues and Topics for XA
  • Enabling Databases for XA
Client Owner Transaction  Design Pattern
Domain Service Owner Transaction Design Pattern
Server Delegate Owner Transaction Design Pattern

About the author

Mark Richards is Certified Senior IT Architect at IBM, where he is involved in the architecture and design of large-scale Service Oriented Architectures in J2EE and other technologies, primarily in the financial services industry. He has been involved in the software industry as a developer, designer, and architect since 1984, speaks frequently at the No Fluff Just Stuff Symposiums and holds a Masters Degree in Computer Science from Boston University, and holds a number of Sun, IBM, and BEA Java and architect certifications.  Feel free to email Mark with any comments or questions about the book.

About the InfoQ Enterprise Software Development Series

Books on InfoQ are intentionally short and attempt to address important, timely issues in as concise a way as possible. The book's writing is intended for the Senior Architect/team lead audience.  Ever thought of writing a book? Our series is a great way to start. InfoQ offers abnormally high royalties and also contract writing opportunities. Email books AT c4media.com for opportunities.

Exclusive Content

Business Natural Languages Development in Ruby

Jay Fields presents his concept of Business Natural Languages - a type of Domain Specific Languages geared towards being readable by domain experts.

Distributed Version Control Systems: A Not-So-Quick Guide Through

Adoption and interest for Distributed Version Control Systems is constantly rising. We will introduce the concept of DVCS and have a look at 3 actors in the area: git, Mercurial and Bazaar.

Segundo Velasquez and Agile as Seen Through the Customer's Eyes

Deborah Hartmann interviewed Segundo Velasquez about his experience as customer with an Agile team during the initial phase of software design of a product.

Fine Grained Versioning with ClickOnce

David Cooksey shows how to fine grained versioning to a ClickOnce deployment using an HttpHandler written with ASP.NET, making partial rollouts to a test audience much easier.

Implementing Manual Activities in Windows Workflow

Windows workflow (WF) is an excellent framework for implementing business processes, but lacks support for human activities. This article describes a completely generic approach for changing this.

Markus Voelter about Software Architecture Documentation

In this interview taken during OOPSLA 2007, Markus Voelter talks about the importance of documenting the software architecture, and gives some good and also bad examples on how it could be done.

Voca, UK's largest payment processing engine running Spring

William Soo and Meeraj Kunnumpurath discuss the Voca transaction processing system, architectural challenges and requirements, Voca's Spring/J2EE architecture, and the future SEPA architecture.

Patterns for securing architectures

Security is about trade-offs. Only a few have the expertise to design good security. This talk focuses on Security Patterns, such as Role-based Access Control, Single Access Point, and Front Door.