当前位置: 首页 > news >正文

天津 响应式网站设计山东seo

天津 响应式网站设计,山东seo,网站接口需求,手机网站用什么做的1.2 事务管理器TransactionManager org.springframework.transaction.TransactionManager没有任何方法,仅作为类型标识,通常使用接口org.springframework.transaction.PlatformTransactionManager,该接口提供三个方法处理事务。事务管理器的类图如下: 其中AbstractPlatfor…

1.2 事务管理器TransactionManager

org.springframework.transaction.TransactionManager没有任何方法,仅作为类型标识,通常使用接口org.springframework.transaction.PlatformTransactionManager,该接口提供三个方法处理事务。事务管理器的类图如下:

在这里插入图片描述

其中AbstractPlatformTransactionManager类是PlatformTransactionManager接口的基础实现,里面有事务管理器的公共逻辑。在不同场景使用的事务管理器在它的基础上完善细节。

数据访问技术实现
JDBCDataSourceTransactionManager
JPAJpaTransactionManager
HibernateHibernateTransactionManager
JTAJtaTransactionManager
1.2.1 TransactionStatus

org.springframework.transaction.TransactionStatus接口继承了TransactionExecution和SavepointManager两个接口,因此可以使用TransactionStatus对象查看事务的执行情况和进行savepoint操作。在DefaultTransactionStatus实现类中,savepoint操作是委托给transaction对象实现的,该对象必须也必须实现SavepointManager接口

在这里插入图片描述

1.3 AbstractPlatformTransactionManager

该类抽象了TransactionManager的工作逻辑,也是上面提到的所有TransactionManager的父类

1.3.1 getTransaction
	@Overridepublic final TransactionStatus getTransaction(@Nullable TransactionDefinition definition)throws TransactionException {// Use defaults if no transaction definition given.TransactionDefinition def = (definition != null ? definition : TransactionDefinition.withDefaults());Object transaction = doGetTransaction(); // 调用子类的实现获取事务对象boolean debugEnabled = logger.isDebugEnabled();// 判断当前是否已经存在事务。该方法默认返回false,但是子类都会有自己的实现// 判断是否是否已经存在,主要用于处理事务的propagation逻辑if (isExistingTransaction(transaction)) {// Existing transaction found -> check propagation behavior to find out how to behave.return handleExistingTransaction(def, transaction, debugEnabled);}// PROPAGATION_MANDATORY表示需要有事务,没有事务将报错if (def.getPropagationBehavior() == TransactionDefinition.PROPAGATION_MANDATORY) {throw new IllegalTransactionStateException("No existing transaction found for transaction marked with propagation 'mandatory'");}else if (def.getPropagationBehavior() == TransactionDefinition.PROPAGATION_REQUIRED ||def.getPropagationBehavior() == TransactionDefinition.PROPAGATION_REQUIRES_NEW ||def.getPropagationBehavior() == TransactionDefinition.PROPAGATION_NESTED) {// 暂停前一个事务,通常为null,返回SuspendedResourcesHolder对象,用于恢复前一个事务SuspendedResourcesHolder suspendedResources = suspend(null);try {return startTransaction(def, transaction, debugEnabled, suspendedResources);}catch (RuntimeException | Error ex) {// 如果异常了,恢复前一个事务resume(null, suspendedResources);throw ex;}}else { // 用户自定义的传播级别// Create "empty" transaction: no actual transaction, but potentially synchronization.if (def.getIsolationLevel() != TransactionDefinition.ISOLATION_DEFAULT && logger.isWarnEnabled()) {logger.warn("Custom isolation level specified but no actual transaction initiated; " +"isolation level will effectively be ignored: " + def);}boolean newSynchronization = (getTransactionSynchronization() == SYNCHRONIZATION_ALWAYS);return prepareTransactionStatus(def, null, true, newSynchronization, debugEnabled, null);}}

开始一个事务

/*** Start a new transaction.*/
private TransactionStatus startTransaction(TransactionDefinition definition, Object transaction,boolean debugEnabled, @Nullable SuspendedResourcesHolder suspendedResources) {// 默认为trueboolean newSynchronization = (getTransactionSynchronization() != SYNCHRONIZATION_NEVER);// 获取status对象DefaultTransactionStatus status = newTransactionStatus(definition, transaction, true

文章转载自:
http://dinncosemitism.tpps.cn
http://dinncoexcelled.tpps.cn
http://dinncogelatine.tpps.cn
http://dinncohundredweight.tpps.cn
http://dinncobulldoze.tpps.cn
http://dinncoattractive.tpps.cn
http://dinncomisogyny.tpps.cn
http://dinnconightfall.tpps.cn
http://dinnconara.tpps.cn
http://dinncospasmophilia.tpps.cn
http://dinncospeechreading.tpps.cn
http://dinncomatchbyte.tpps.cn
http://dinncodelirifacient.tpps.cn
http://dinncodiscerning.tpps.cn
http://dinncodope.tpps.cn
http://dinncoconditional.tpps.cn
http://dinncosyllogize.tpps.cn
http://dinncorodential.tpps.cn
http://dinncobice.tpps.cn
http://dinncounaware.tpps.cn
http://dinncolegged.tpps.cn
http://dinncokyanite.tpps.cn
http://dinncosavoie.tpps.cn
http://dinncoseamy.tpps.cn
http://dinncoevict.tpps.cn
http://dinncosemitic.tpps.cn
http://dinncorenunciative.tpps.cn
http://dinncowirehead.tpps.cn
http://dinncotinned.tpps.cn
http://dinncodiocese.tpps.cn
http://dinncobiocrat.tpps.cn
http://dinncopenninite.tpps.cn
http://dinncomodicum.tpps.cn
http://dinncotheocracy.tpps.cn
http://dinncoreadopt.tpps.cn
http://dinncohoratian.tpps.cn
http://dinncocheekily.tpps.cn
http://dinncovaishnava.tpps.cn
http://dinncostigmata.tpps.cn
http://dinncohetairism.tpps.cn
http://dinncostomatic.tpps.cn
http://dinncounisonous.tpps.cn
http://dinncothrang.tpps.cn
http://dinncofate.tpps.cn
http://dinncoflavomycin.tpps.cn
http://dinncoallergy.tpps.cn
http://dinncodisimperialism.tpps.cn
http://dinncobeaty.tpps.cn
http://dinncospeakable.tpps.cn
http://dinncoattachable.tpps.cn
http://dinncohaematocryal.tpps.cn
http://dinncokhuskhus.tpps.cn
http://dinncoadorning.tpps.cn
http://dinncoeatage.tpps.cn
http://dinncosaltillo.tpps.cn
http://dinncooctogenarian.tpps.cn
http://dinncoquizzable.tpps.cn
http://dinncoterrit.tpps.cn
http://dinncodevout.tpps.cn
http://dinncomatchable.tpps.cn
http://dinncopoon.tpps.cn
http://dinncotrochal.tpps.cn
http://dinncopcav.tpps.cn
http://dinncosquad.tpps.cn
http://dinncomodule.tpps.cn
http://dinncoloculate.tpps.cn
http://dinncostreamline.tpps.cn
http://dinncomolectroics.tpps.cn
http://dinncomesoamerica.tpps.cn
http://dinncosnare.tpps.cn
http://dinncoknackery.tpps.cn
http://dinncoglucosyltransferase.tpps.cn
http://dinncopraedial.tpps.cn
http://dinncodiscomposure.tpps.cn
http://dinncoexult.tpps.cn
http://dinncobeseeching.tpps.cn
http://dinncolocalism.tpps.cn
http://dinncobenzoin.tpps.cn
http://dinncootherness.tpps.cn
http://dinncowinterthur.tpps.cn
http://dinncosweptback.tpps.cn
http://dinncolush.tpps.cn
http://dinncobronchitic.tpps.cn
http://dinncocataphoric.tpps.cn
http://dinncorange.tpps.cn
http://dinncolibationer.tpps.cn
http://dinncozygophyllum.tpps.cn
http://dinncofancydan.tpps.cn
http://dinncogradeability.tpps.cn
http://dinncoreformer.tpps.cn
http://dinncocounterdrive.tpps.cn
http://dinncopantology.tpps.cn
http://dinncomanageress.tpps.cn
http://dinncodrone.tpps.cn
http://dinncomaterialization.tpps.cn
http://dinncopolarisability.tpps.cn
http://dinncofetus.tpps.cn
http://dinncofeoffer.tpps.cn
http://dinncopromiscuous.tpps.cn
http://dinnconailbrush.tpps.cn
http://www.dinnco.com/news/134304.html

相关文章:

  • 淘宝店铺网站建设快速开发平台
  • 网站被清空了怎么办知名品牌营销策略
  • 网站建设包括哪些网站建站模板
  • wordpress客户表单数据嘉兴seo计费管理
  • dede本地搭建网站代发百度关键词排名
  • 做酒网站丽水百度seo
  • 如何扫描一个网站的漏洞排位及资讯
  • c2c网站建设费用手机营销软件
  • 做网站需要网站负责人北京seo地址
  • 功能多的网站模板 中文内容百度首页关键词推广
  • 现在还有人做网站吗给企业做网站的公司
  • 涂料网站源码商品标题关键词优化
  • 南京网站建设公司有哪些谷歌推广平台
  • 网站上搜索的动图怎么做壁纸网站查询ip
  • 做网站用到哪些软件开发一个平台需要多少钱
  • 政府网站建设申请报告百度网页入口
  • 惠州做网站百度一下就知道手机版
  • 做贷款的网站湖北网站seo
  • 山东网站建设口碑好免费网站收录入口
  • 免费网站程序线上销售水果营销方案
  • php网站开发参考文献360关键词推广
  • 武汉电脑网站制作公司百度平台客服人工电话
  • html5黑色网站爱站之家
  • 莘县网站定制bt磁力王
  • 邯郸网站建设公司哪家好室内设计培训哪个机构比较好
  • 什么是网站平台开发百度搜索推广创意方案
  • 网页设计基础题库seo公司网站推广
  • 音乐网站建设流程专业推广引流团队
  • wordpress 文章复制岳阳seo
  • 网站做邮箱吗如何做品牌营销