Skip to content

Commit 680cdb4

Browse files
committed
Merge pull request #18490 from izeye
* pr/18490: Polish Closes gh-18490
2 parents 4cfbe7f + 701bd0d commit 680cdb4

File tree

8 files changed

+18
-15
lines changed

8 files changed

+18
-15
lines changed

spring-boot-project/spring-boot-autoconfigure/src/main/java/org/springframework/boot/autoconfigure/amqp/RabbitAutoConfiguration.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@
4848
* <p>
4949
* This configuration class is active only when the RabbitMQ and Spring AMQP client
5050
* libraries are on the classpath.
51-
* <P>
51+
* <p>
5252
* Registers the following beans:
5353
* <ul>
5454
* <li>{@link org.springframework.amqp.rabbit.core.RabbitTemplate RabbitTemplate} if there

spring-boot-project/spring-boot-autoconfigure/src/main/java/org/springframework/boot/autoconfigure/batch/BatchDataSourceInitializer.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424
import org.springframework.util.Assert;
2525

2626
/**
27-
* Initialize the Spring Batch schema (ignoring errors, so should be idempotent).
27+
* Initialize the Spring Batch schema (ignoring errors, so it should be idempotent).
2828
*
2929
* @author Dave Syer
3030
* @author Vedran Pavic

spring-boot-project/spring-boot-autoconfigure/src/main/java/org/springframework/boot/autoconfigure/data/mongo/MongoDataAutoConfiguration.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@
3434
* <p>
3535
* Registers a {@link MongoTemplate} and {@link GridFsTemplate} beans if no other beans of
3636
* the same type are configured.
37-
* <P>
37+
* <p>
3838
* Honors the {@literal spring.data.mongodb.database} property if set, otherwise connects
3939
* to the {@literal test} database.
4040
*

spring-boot-project/spring-boot-autoconfigure/src/main/java/org/springframework/boot/autoconfigure/data/mongo/MongoReactiveDataAutoConfiguration.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@
4949
* <p>
5050
* Registers a {@link ReactiveMongoTemplate} bean if no other bean of the same type is
5151
* configured.
52-
* <P>
52+
* <p>
5353
* Honors the {@literal spring.data.mongodb.database} property if set, otherwise connects
5454
* to the {@literal test} database.
5555
*

spring-boot-project/spring-boot-docs/src/main/asciidoc/howto.adoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1301,7 +1301,7 @@ By default, Spring Boot picks up the native configuration from its default locat
13011301
=== Configure Logback for Logging
13021302
If you need to apply customizations to logback beyond those that can be achieved with `application.properties`, you'll need to add a standard logback configuration file.
13031303
You can add a `logback.xml` file to the root of your classpath for logback to find.
1304-
You can also use `logback-spring.xml` if you want to use the <<spring-boot-features.adoc#boot-features-logback-extensions,Spring Boot Logback extensions>>)
1304+
You can also use `logback-spring.xml` if you want to use the <<spring-boot-features.adoc#boot-features-logback-extensions,Spring Boot Logback extensions>>.
13051305

13061306
TIP: The Logback documentation has a https://logback.qos.ch/manual/configuration.html[dedicated section that covers configuration] in some detail.
13071307

spring-boot-project/spring-boot/src/main/java/org/springframework/boot/LazyInitializationBeanFactoryPostProcessor.java

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727
import org.springframework.core.Ordered;
2828

2929
/**
30-
* {@link BeanFactoryPostProcessor} to set lazy-init on bean definitions that not
30+
* {@link BeanFactoryPostProcessor} to set lazy-init on bean definitions that are not
3131
* {@link LazyInitializationExcludeFilter excluded} and have not already had a value
3232
* explicitly set.
3333
*
@@ -57,8 +57,11 @@ private void postProcess(ConfigurableListableBeanFactory beanFactory,
5757
Collection<LazyInitializationExcludeFilter> filters, String beanName,
5858
AbstractBeanDefinition beanDefinition) {
5959
Boolean lazyInit = beanDefinition.getLazyInit();
60+
if (lazyInit != null) {
61+
return;
62+
}
6063
Class<?> beanType = getBeanType(beanFactory, beanName);
61-
if (lazyInit == null && !isExcluded(filters, beanName, beanDefinition, beanType)) {
64+
if (!isExcluded(filters, beanName, beanDefinition, beanType)) {
6265
beanDefinition.setLazyInit(true);
6366
}
6467
}

spring-boot-project/spring-boot/src/main/java/org/springframework/boot/LazyInitializationExcludeFilter.java

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -21,24 +21,24 @@
2121

2222
/**
2323
* Filter that can be used to exclude beans definitions from having their
24-
* {@link AbstractBeanDefinition#setLazyInit(boolean) lazy-int} set by the
24+
* {@link AbstractBeanDefinition#setLazyInit(boolean) lazy-init} set by the
2525
* {@link LazyInitializationBeanFactoryPostProcessor}.
26-
* <P>
26+
* <p>
2727
* Primarily intended to allow downstream projects to deal with edge-cases in which it is
2828
* not easy to support lazy-loading (such as in DSLs that dynamically create additional
2929
* beans). Adding an instance of this filter to the application context can be used for
3030
* these edge cases.
31-
* <P>
31+
* <p>
3232
* A typical example would be something like this:
33-
* <P>
33+
* <p>
3434
* <pre><code>
3535
* &#64;Bean
3636
* public static LazyInitializationExcludeFilter integrationLazyInitializationExcludeFilter() {
3737
* return LazyInitializationExcludeFilter.forBeanTypes(IntegrationFlow.class);
3838
* }</code></pre>
3939
* <p>
4040
* NOTE: Beans of this type will be instantiated very early in the spring application
41-
* lifecycle so should generally be declared static and not have any dependencies.
41+
* lifecycle so they should generally be declared static and not have any dependencies.
4242
*
4343
* @author Tyler Van Gorder
4444
* @author Philip Webb
@@ -49,11 +49,11 @@ public interface LazyInitializationExcludeFilter {
4949

5050
/**
5151
* Returns {@code true} if the specified bean definition should be excluded from
52-
* having {@code lazy-int} automatically set.
52+
* having {@code lazy-init} automatically set.
5353
* @param beanName the bean name
5454
* @param beanDefinition the bean definition
5555
* @param beanType the bean type
56-
* @return {@code true} if {@code lazy-int} should not be automatically set
56+
* @return {@code true} if {@code lazy-init} should not be automatically set
5757
*/
5858
boolean isExcluded(String beanName, BeanDefinition beanDefinition, Class<?> beanType);
5959

spring-boot-project/spring-boot/src/main/java/org/springframework/boot/context/properties/source/PropertyMapper.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
/**
2323
* Strategy used to provide a mapping between a {@link PropertySource} and a
2424
* {@link ConfigurationPropertySource}.
25-
* <P>
25+
* <p>
2626
* Mappings should be provided for both {@link ConfigurationPropertyName
2727
* ConfigurationPropertyName} types and {@code String} based names. This allows the
2828
* {@link SpringConfigurationPropertySource} to first attempt any direct mappings (i.e.

0 commit comments

Comments
 (0)