Archived - Java Transaction Management Part 1
Although Spring and EJB isolate us from most of the complexities involving transaction management, there are still a number of things we need to be aware of when dealing with transactions in Enterprise Java Applications. Too often transaction management is an afterthought in the design and development process, which leads to applications that have problems with data integrity, data consistency, and overall stability and reliability. In this session we will explore the three transaction models that both Spring and EJB support (Local, Programmatic, and Declarative), and discuss the advantages, disadvantages, and pitfalls within each of these models, when it makes sense to use each transaction model, and under what situations these models are appropriate and inappropriate. We will spend most of our time on the Declarative Transaction Model. Within this model we will explore some common pitfalls and look at the best practices within this model. Through coding examples in both EJB and Spring using real-world scenarios, you will learn how to properly handle exceptions, how to correctly use transaction attributes, and how the isolation level can affect transaction and application behavior. This session is the first part of a 3 hour transaction management session.
Agenda:
- Introduction
- Local Transaction Model
- Programmatic Transaction Model
- Declarative Transaction Model
- Best Practices and Pitfalls
About Mark Richards
Mark Richards is an experienced, hands-on software architect involved in the architecture, design, and implementation of microservices architectures, service-oriented architectures, and distributed systems. He has been in the software industry since 1983 and has significant experience and expertise in application, integration, and enterprise architecture. Mark is the founder of DeveloperToArchitect.com, a website devoted to helping developers in the journey to software architect. He is the author of numerous technical books and videos, including the recently published Fundamentals of Software Architecture, Microservices AntiPatterns and Pitfalls, Microservices vs. SOA, the Software Architecture Fundamentals video series, The Enterprise Messaging video series, Java Message Service, 2nd Edition, and contributing author to 97 Things Every Software Architect Should Know. Mark has a master’s degree in computer science and is a regular conference speaker at the No Fluff Just Stuff (NFJS) Symposium Series. He has spoken at hundreds of conferences and user groups around the world on a variety of enterprise-related technical topics.
More About Mark »