From 3d6476da4606e4b0864f059c7a97da431f0354ac Mon Sep 17 00:00:00 2001 From: Juergen Hoeller Date: Fri, 3 May 2019 17:29:22 +0200 Subject: [PATCH] Polishing --- .../interceptor/TransactionAspectSupport.java | 11 ++++++----- .../reactive/function/client/ExchangeStrategies.java | 2 +- 2 files changed, 7 insertions(+), 6 deletions(-) diff --git a/spring-tx/src/main/java/org/springframework/transaction/interceptor/TransactionAspectSupport.java b/spring-tx/src/main/java/org/springframework/transaction/interceptor/TransactionAspectSupport.java index ba21c66386..6e85e9a568 100644 --- a/spring-tx/src/main/java/org/springframework/transaction/interceptor/TransactionAspectSupport.java +++ b/spring-tx/src/main/java/org/springframework/transaction/interceptor/TransactionAspectSupport.java @@ -1,5 +1,5 @@ /* - * Copyright 2002-2018 the original author or authors. + * Copyright 2002-2019 the original author or authors. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -287,7 +287,8 @@ public abstract class TransactionAspectSupport implements BeanFactoryAware, Init if (txAttr == null || !(tm instanceof CallbackPreferringPlatformTransactionManager)) { // Standard transaction demarcation with getTransaction and commit/rollback calls. TransactionInfo txInfo = createTransactionIfNecessary(tm, txAttr, joinpointIdentification); - Object retVal = null; + + Object retVal; try { // This is an around advice: Invoke the next interceptor in the chain. // This will normally result in a target object being invoked. @@ -508,8 +509,8 @@ public abstract class TransactionAspectSupport implements BeanFactoryAware, Init // The TransactionInfo.hasTransaction() method will return false. We created it only // to preserve the integrity of the ThreadLocal stack maintained in this class. if (logger.isTraceEnabled()) { - logger.trace("Don't need to create transaction for [" + joinpointIdentification + - "]: This method isn't transactional."); + logger.trace("No need to create transaction for [" + joinpointIdentification + + "]: This method is not transactional."); } } @@ -592,7 +593,7 @@ public abstract class TransactionAspectSupport implements BeanFactoryAware, Init /** - * Opaque object used to hold Transaction information. Subclasses + * Opaque object used to hold transaction information. Subclasses * must pass it back to methods on this class, but not see its internals. */ protected final class TransactionInfo { diff --git a/spring-webflux/src/main/java/org/springframework/web/reactive/function/client/ExchangeStrategies.java b/spring-webflux/src/main/java/org/springframework/web/reactive/function/client/ExchangeStrategies.java index baefea67b5..804fbd9a42 100644 --- a/spring-webflux/src/main/java/org/springframework/web/reactive/function/client/ExchangeStrategies.java +++ b/spring-webflux/src/main/java/org/springframework/web/reactive/function/client/ExchangeStrategies.java @@ -51,7 +51,7 @@ public interface ExchangeStrategies { // Static builder methods /** - * Return a new {@code ExchangeStrategies} with default configuration + * Return an {@code ExchangeStrategies} instance with default configuration * provided by {@link ClientCodecConfigurer}. */ static ExchangeStrategies withDefaults() {