- 浏览: 233845 次
- 性别:
- 来自: 深圳
文章分类
- 全部博客 (96)
- J2EE (11)
- Spring (11)
- Oracle (3)
- Struts2 (7)
- Hibernate (1)
- Struts1.x (0)
- 职场内外 (1)
- Java (31)
- JSP基础 (3)
- 英语点滴 (1)
- Linux (2)
- JavaScript (12)
- ANT (5)
- 计算机基础知识 (2)
- 开发工具 (4)
- Java网络编程 (3)
- Swing (2)
- JVM (3)
- 网络协议 (3)
- 算法与数据结构 (5)
- Ext JS (1)
- Spring JUnit (1)
- XML (1)
- 搜索引擎 (1)
- NoSQL (1)
- 搜索(引擎) Solr Lucene (2)
- UML (1)
- Design Pattern (1)
最新评论
-
chokee:
struts2如何获取页面参数 -
mengfei86:
顶顶!
jstat的使用方法 -- 分析JVM的使用情况 -
yifzeng:
感谢楼上两位!!!
Struts2 验证框架不起作用的几种可能[转] -
xianqi_h:
如果所要用的形容词是几个,而且是上述所列的归类之外的词,如: ...
英语形容词的排列顺序 -- 重点记忆 -
skzr.org:
fixbug——在IE7下面:IE无法打开站点XXXX,无法操 ...
struts2开发中ie无法打开XXX站点 已终止操作
Spring Transaction Architecture
Deployment options
As shown below, there are two fundamentally different ways of deploying an application that uses Spring transactions:
- Standalone Spring container
- J2EE container deployment
Standalone Spring container
In the standalone deployment model, the Spring container is provides access to persistent data sources and is responsible for managing the transactions associated with those data sources. A notable limitation of the standalone model is that the Spring container can support only local transaction managers, which means that only one data source (resource) at a time can participate in a transaction.
Data source
Spring supports a variety of different wrapper APIs for accessing persistent storage. For example, to access a database through JDBC, Spring provides the SimpleDriverDataSource class to represent the database instance and the JdbcTemplate class to provide access to the database using SQL. Wrappers are also provided for other kinds of persistent resource, such as JMS, Hibernate, and so on. The Spring data sources are designed to be compatible with the local transaction manager classes.
Local transaction manager
In Spring, a local transaction manager is a wrapper class that is responsible for managing the transactions of a single resource. The local transaction manager is responsible for starting, committing, and rolling back transactions. Typically, the way that you use a transaction manager in Apache Camel is that you pass the transaction manager reference to a transactional Apache Camel component bean.
Spring provides different types of local transaction manager for different types of data source. For example, Spring provides a DataSourceTransactionManager for JDBC, a JmsTransactionManager for JMS, a HibernateTransactionManager for Hibernate, and so on.
J2EE container deployment
In the J2EE deployment model, the Spring container is nested inside a J2EE application server. The advantage of this deployment model is that the Spring container can leverage the transaction management capabilities of the J2EE container. In particular, the Spring container can now access global transactions, which means that multiple resources can participate in a single transaction.
XA resources
In a J2EE deployment, the persistent resources should be integrated directly with J2EE. In other words, you do not use Spring data sources in this case. Moreover, in order to enable global transactions, you register each resource's XA interface with the JTA transaction manager in the J2EE environment.
JTA transaction manager
The Java Transaction API (JTA) and the Java Transaction Service define respectively the API and the implementation of a transaction manager for the J2EE platform. A full implementation of the JTA transaction manager can potentially provide enterprise-level transaction features, including support for global transactions, XA resources, and (in some cases) distributed transactions.
Global transaction manager
To access J2EE global transactions from within the Spring environment, the Spring container provides the JtaTransactionManager class, which is essentially just a thin wrapper around the JTA transaction manager. In fact, the JTA transaction manager is completely configured within the J2EE environment. If required, you can instantiate the Spring wrapper class, JtaTransactionManager, by obtaining a reference to the existing JTA transaction manager in J2EE, typically using a JNDI lookup.
For detail, open this url:
发表评论
-
运行mvn eclipse:eclipse 报插件不存在或者版本不对错误
2013-07-26 20:59 1220我的maven版本是2.2.1,当我使用mvn eclip ... -
eclipse 安装velocity插件
2013-07-14 21:09 948安装velocity的eclipse插件步骤: ... -
java日志,需要知道的几件事 -- 转
2013-03-07 14:16 943http://blog.csdn.net/su ... -
构建高可扩Web架构和分布式系统实战 -- 转
2013-01-24 11:34 1106http://www.csdn.net/articl ... -
Java中的ReentrantLock和synchronized两种锁定机制的对比 -- 转
2013-01-07 09:45 1245阅读本文,使我从对比的角度重新审视了两种锁的机制。 分享 ... -
ant jsch.jar -- 一个异常及解决方法
2012-12-11 14:49 3497运行build.xml出现异常: Cause: Cou ... -
struts2 拦截器 -- 转
2012-11-20 15:46 907深入认识struts2拦截器(甚至是struts2的ac ... -
web.xml文件中配置(servlet, spring, filter, listenr)的加载顺序 (转)
2012-11-20 14:44 887servlet: 项目的运 ... -
全局事务与本地事务的区别应用
2012-10-15 15:44 1338http://blog.csdn.net/sunitjy ... -
搜索服务器Solr部署使用
2012-09-21 10:56 1084本文肤浅探讨MySQL + Solr + Solr ... -
JAVA - DOM4J - XML 转化成String字串
2012-09-07 10:20 5491import org.dom4j.Document; imp ... -
JVM "Out of swap space"错误常见的原因
2012-08-01 15:31 1238Out of swap space error general ... -
struts2 converter 之类型转换器
2012-06-06 14:48 15571. 前面讲的自定义类型转换器是基于 OGNL 的 Defau ... -
Java中static、final用法小结
2012-05-18 14:02 1185一、final 1.final变量: 当 ... -
ConcurrentHashMap 详解
2012-05-15 15:03 0java.util.concurrent.Concurrent ... -
JAVA泛型简析
2012-05-11 15:13 1145泛型是JDK1.5支持的新功 ... -
Ant之build.xml详解
2012-05-08 14:55 1215Ant的概念 可能有些读 ... -
hashcode 与 equals 方法详解 --- 透彻,详尽
2012-01-15 20:41 0如果函数返回类型不同,子类的同名函数不能继承父类的同名函数 ... -
Java Hash算法大全
2012-01-15 20:35 1509/*** Hash算法大全<br>* 推荐使用FN ... -
java中equals和==的区别
2012-01-15 19:03 864<script type="text/ja ...
相关推荐
而Seata(前身是FATBOY和SEATA)是阿里巴巴开源的分布式事务解决方案,全称是Simple Extensible Autonomous Transaction Architecture,意为简单可扩展的自主事务架构。Seata支持AT(Automatic Transaction)、TCC...
3. **Seata**:全称 Simple Extensible Autonomous Transaction Architecture,是阿里巴巴开源的分布式事务解决方案,它支持全局事务的ACID特性,解决了微服务场景下分布式事务处理的难题。 4. **Sentinel**:这是...
4. **Seata**:Seata(Simple Extensible Autonomous Transaction Architecture)是阿里巴巴开源的分布式事务解决方案,致力于提供高性能和简单易用的分布式事务服务。在案例中,Seata可以帮助我们处理分布式环境下...
3. **Seata**:Seata(Simple Extensible Autonomous Transaction Architecture)是阿里开源的分布式事务解决方案,它支持AT、TCC、SAGA和XA等多种分布式事务模式,解决了在分布式环境下的事务一致性问题。...
Seata(Simple Extensible Autonomous Transaction Architecture)是由阿里开源的一款分布式事务解决方案,它集成了AT(二阶段提交)、TCC(尝试、确认、补偿)以及Saga(长事务)等多种事务模式,为开发者提供了...
而Seata(Simple Extensible Autonomous Transaction Architecture)则是一个高性能、轻量级的开源分布式事务解决方案,它旨在解决微服务环境下的分布式事务问题。本篇文章将详细探讨如何在Spring Cloud项目中整合...
Spring框架作为一个广泛使用的Java应用程序开发框架,提供了多种支持事务管理的解决方案,其中包括集成JOTM(Java Open Transaction Manager)来处理分布式事务。本文将深入探讨Spring与JOTM结合使用的知识点,帮助...
Seata(Simple Extensible Autonomous Transaction Architecture)是阿里巴巴开源的分布式事务解决方案,它实现了ACID(原子性、一致性、隔离性和持久性)特性,提供了AT(两阶段提交)、TCC(尝试、确认、补偿)...
Seata,全称Simple Extensible Autonomous Transaction Architecture,是一个开源的分布式事务解决方案,致力于提供高性能和简单易用的分布式事务服务。它旨在解决微服务架构下的分布式事务问题,支持AT(两阶段提交...
Seata是一款开源的分布式事务解决方案,它的全称是Simple Extensible Autonomous Transaction Architecture,即简单可扩展的自治事务架构。Seata包含了三个核心组件:TM(Transaction Manager)、RM(Resource ...
Seata(Simple Extensible Autonomous Transaction Architecture)是一款开源的分布式事务解决方案,主要致力于提供高性能和简单易用的分布式事务服务。Seata将ACID(原子性、一致性、隔离性、持久性)事务特性扩展...
5. **Manager, Architecture**:架构师需要设计事务管理的全局策略,比如是否使用全局事务(JTA)还是本地事务,以及如何在微服务架构中协调事务。 6. **IT Service Continuity Manager**:IT服务连续性经理关注...
3. **Seata**:全名为Simple Extensible Autonomous Transaction Architecture,是一个开源的分布式事务解决方案,致力于提供高性能和简单易用的分布式事务服务。Seata包含了AT、TCC、Saga和XA四种分布式事务模式。 ...
Seata(Simple Extensible Autonomous Transaction Architecture)是一款开源的分布式事务解决方案,主要致力于提供高性能和简单易用的分布式事务服务。2.0.0版本的发布标志着Seata在功能、性能和稳定性上有了显著的...
Explore Spring's comprehensive transaction support for declarative Transaction Management and its integration with Spring's data access abstractions Investigate Spring Data access mechanisms with ...
阿里开源的Seata(Simple Extensible Autonomous Transaction Architecture)是一个全球分布式事务解决方案,旨在提供高性能和简单易用的分布式事务服务。Seata-samples-master.zip是一个包含多种技术集成示例的...
It streamlines configuration, exception handling, and transaction management while providing a clean and modular architecture. By leveraging the power of both frameworks, developers can build robust,...
Seata 的全称是 Simple Extensible Autonomous Transaction Architecture,即简单可扩展的自主事务架构。在本项目中,我们将基于 Seata 1.7 版本,结合 Spring Cloud 和 Nacos 来搭建一个客户端,实现 AT 模式的...
在Spring中集成Atomikos,可以让应用程序具备处理XA(eXtended Architecture)事务的能力,即使在分布式环境中也能保证ACID(原子性、一致性、隔离性和持久性)特性。Atomikos通过实现JTA接口,使得Spring的`...