Commit Graph

2199 Commits (5dd7780a381f0e9553b6599cb6a0b0e0fd5a8c37)

Author SHA1 Message Date
Andy Wilkinson d0c75aef19 Merge branch '2.2.x' into 2.3.x
Closes gh-22580
4 years ago
Andy Wilkinson 16eaae0b2f Defer background pre-init till the environment is prepared
Previously, background pre-init was started in response to the
application starting event. This meant that it would be running while
the logging turbo filter was in place and was rejecting all logging.
As a result, any logging performed during pre-init would be lost.

This commit changes background pre-init so that it is now started
in response to the application environment prepared event. By this
point, the logging turbo filter has been removed as the logging levels
have been configured from the environment.

Closes gh-21897
4 years ago
Andy Wilkinson f0d90020e5 Merge branch '2.2.x' into 2.3.x
Closes gh-22578
4 years ago
Andy Wilkinson b98c3dccfd Fix property-based configuration of Undertow socket options
Previously, only UndertowOptions was used as the source of options for
both server and socket options, but it only contains server options.
As a result, attempting to configure any socket options defined by
XNIO's Options class would fail.

This commit updates the property-based configuration of options to use
UndertowOptions as the source for server options and XNIO's Options as
the source for socket options.

Fixes gh-22502
4 years ago
Stephane Nicoll 6b32e62142 Fix CacheAutoConfiguration relative order for Couchbase
This commit fixes the auto-configuration of the Couchbase caching
support by configuring the cache once Spring Data Couchbase has gotten
a chance to be processed.

Closes gh-22542
4 years ago
Andy Wilkinson c605a6e34b Override other variant of registerBeanDefintions
Fixes gh-22480
4 years ago
Phillip Webb 187d3af7fc Update copyright year of changed files 4 years ago
Phillip Webb 217b2eff89 Merge branch '2.2.x' into 2.3.x 4 years ago
Phillip Webb b5e70157dc Update copyright year of changed files 4 years ago
Andy Wilkinson f88038f00d Upgrade to Couchbase Client 3.0.6
Closes gh-22456
4 years ago
dreis2211 267283e3cd Handle null items as advertized in the Javadoc
See gh-22344
4 years ago
Andy Wilkinson 259ea65388 Merge branch '2.2.x' into 2.3.x
Closes gh-22339
4 years ago
Andy Wilkinson d9882f2c88 Clarify the effects of ordering auto-configuration classes
Closes gh-22337
4 years ago
dreis2211 de30e5c6ac Avoid unnecessary allocations in ConditionMessage for NORMAL style
See gh-22330
4 years ago
Stephane Nicoll 603e65a629 Polish 4 years ago
dreis2211 60e7146326 Reduce started threads in OnClassCondition
Prior to this commit, OnClassCondition started a thread even if the number of
passed autoconfiguration class candidates never exceeded 1. This commit only
starts a thread if there is actually work to split in half.

See gh-22294
4 years ago
Andy Wilkinson c765df6e5d Merge branch '2.2.x' into 2.3.x
Closes gh-22282
4 years ago
Andy Wilkinson afa5b12bdb Make reactive Jetty auto-config back off without jetty-servlet
Fixes gh-22275
4 years ago
Scott Frederick 1e2176b6c9 Improve Redis URL validation
This commit improves the validation of URLs provided in the property
'spring.redis.url' used to auto-configure a Spring Data Redis
connection. In particular, only the URL schemes 'redis://' and
'rediss://' are allowed, and any other scheme will result in a
configuration error. A failure analyzer is also provided to improve
diagnostics for common mis-configurations detected by this validation.

Fixes gh-21999
4 years ago
Andy Wilkinson 502ccb6586 Honor spring.autoconfigure.exclude in test slices
Previously, the import selector for `@ImportAutoConfiguration` did not
consider the spring.autoconfigure.exclude property when determining
which auto-configurations to exclude. This meant that tests using a
slice that included a particular auto-configuration would include it
even if the application's configuration excluded it via
spring.autoconfigure.exclude. Confusingly, this could result in a
sliced test using an auto-configuration that would be excluded in a
broader `@SpringBootTest`.

This commit updates the ImportAutoConfigurationImportSelector to
consider the spring.autoconfigure.exclude property so that sliced tests
will use a subset of the auto-configurations that a `@SpringBootTest`
would use.

Fixes gh-21736
4 years ago
Andy Wilkinson 1b85ce0769 Streamline OAuth2 resource server auto-config class conditions
Fixes gh-22233
4 years ago
Andy Wilkinson b8bc219b25 Merge branch '2.2.x' into 2.3.x
Closes gh-22251
4 years ago
Andy Wilkinson 4e79bb1cff Disable bean method proxying in SpringBootJdbcConfiguration
Closes gh-22231
4 years ago
Andy Wilkinson 24e1a1dddf Merge branch '2.2.x' into 2.3.x
Closes gh-22246
4 years ago
Andy Wilkinson a8d3f9af31 Polish "Rename NoneOfNestedConditions to NoneNestedConditions in example docs"
See gh-22207
4 years ago
Clayton Walker 7fee70a625 Rename NoneOfNestedConditions to NoneNestedConditions in example docs
See gh-22207
4 years ago
Andy Wilkinson 2007490ce7 Merge branch '2.2.x' into 2.3.x
Closes gh-22234
4 years ago
Andy Wilkinson 4301580095 Improve testing of PropertyPlaceholderAutoConfiguration
Since Spring Framework 4.3.0.RC2, a default embedded value resolver
has been registered with the bean factory when one is not otherwise
configured. This meant that placeholders in `@Value` would be resolved
with or without PropertyPlaceholderAutoConfiguration defining a
PropertySourcesPlaceholderConfigurer bean. However, placeholders in
bean definitions would only be resolved if a
PropertySourcesPlaceholderConfigurer was defined.

This commit updates PropertyPlaceholderAutoConfigurationTests to align
with this change in Framework. We now test that placeholders are
resolved in `@Value` annotations with or without the auto-configuration
and that placeholders in bean definitions are only resolved with the
auto-configured.

Closes gh-22230
4 years ago
Andy Wilkinson f6b3666b16 Merge branch '2.2.x' into 2.3.x
Closes gh-22197
4 years ago
Andy Wilkinson 21453b5016 Ignore scoped targets when finding matching beans
Fixes gh-22038
4 years ago
Andy Wilkinson 81d6751ba7 Use ApplicationContextRunner in ConditionalOnSingleCandidateTests 4 years ago
Eddú Meléndez 54e0a61b42 Reinstate metrics for Kafka Streams
See gh-21921
4 years ago
Andy Wilkinson 0e1ded6893 Merge branch '2.2.x' into 2.3.x
Closes gh-22175
4 years ago
dreis2211 8c0e302f2e Accept empty filter dispatcher types in auto-configurations
Prior to this commit, the usage of EnumSet.copyOf resulted in exceptions when
the underlying collection was empty.

See gh-22138
4 years ago
Andy Wilkinson 4566ac5c25 Add package info to o.s.b.autoconfigure.elasticsearch.rest
Closes gh-22147
4 years ago
Andy Wilkinson f86831da9c Use TCCL at time of access for resource loading
Fixes gh-22119
4 years ago
Andy Wilkinson 1e97ff834e Only consider current context when finding lifecycle processor
Previously, LifecycleAutoConfiguration would check the current context
and all of its ancestors for a lifecycle processor bean, only
configuring a custom processor if one was not found. Every context
has a lifecycle processor so this check meant that lifecycle processing
timeout could not be customized in any context with a parent.

This commit updates the auto-configuration to only check the current
context.

Closes gh-22014
4 years ago
Andy Wilkinson 0de466e06e Require dependency on s-b-dependencies to use its constraints
Previously, Spring Boot's modules published Gradle Module Metadata
(GMM) the declared a platform dependency on spring-boot-dependencies.
This provided versions for each module's own dependencies but also had
they unwanted side-effect of pulling in spring-boot-dependencies
constraints which would influence the version of other dependencies
declared in the same configuration. This was undesirable as users
should be able to opt in to this level of dependency management, either
by using the dependency management plugin or by using Gradle's built-in
support via a platform dependency on spring-boot-dependencies.

This commit reworks how Spring Boot's build uses
spring-boot-dependencies and spring-boot-parent to provide its own
dependency management. Configurations that aren't seen by consumers are
configured to extend a dependencyManagement configuration that has an
enforced platform dependency on spring-boot-parent. This enforces
spring-boot-parent's version constraints on Spring Boot's build without
making them visible to consumers. To ensure that the versions that
Spring Boot has been built against are visible to consumers, the
Maven publication that produces pom files and GMM for the published
modules is configured to use the resolved versions from the module's
runtime classpath.

Fixes gh-21911
4 years ago
Brian Clozel a480f6e2ee Polish 4 years ago
Brian Clozel af2666df79 Fix welcome page support in WebFlux
Prior to this commit, the welcome page support implemented in gh-9785
would override existing index views in both annotation and functional
variants.

This comes from the fact that the feature was implemented as a
`RouterFunction` configured in the main `RouterFunctionMapping` bean.
Due to ordering issues between mappings, this would override existing
application mappings in some cases.

This commit ensures that the welcome page `RouterFunction` is
contributed to the context in its own handler mapping, ordered after the
application ones.

Fixes gh-21909
4 years ago
Stephane Nicoll ca5afb6e90 Fix flaky integration test
Closes gh-21487
5 years ago
Andy Wilkinson 90bd433083 Allow child contexts to configure server properties
Previously, HttpMessageConvertersAutoConfiguration registered
ServerProperties. When this happened in a parent context, any child
contexts would skip registering ServerProperties due to its presence
in the parent context. This prevents the child contexts from
configuring their own server properties.

This commit updates HttpMessageConvertersAutoConfiguration to
bind server.servlet.encoding directly instead of enabling
ServerProperties. With ServerProperties no longer enabled in a parent
context, child contexts are now able to configure their own server
properties.

Fixes gh-21789
5 years ago
Tomek Szmytka 8890660a71 Back-off if a custom ReactiveSessionFactory is defined
This commit makes sure that CassandraReactiveDataAutoConfiguration does
not create a reactiveCassandraSessionFactory bean if the user has
provided their own.

See gh-21769
5 years ago
Andy Wilkinson 3e5fcee187 Upgrade to Spring Security 5.3.3.RELEASE
Closes gh-21863
5 years ago
Stephane Nicoll 6534a9abaf Configure password-based authentication with Cassandra
This commit updates the Cassandra auto-configuration to configure
password-based authentication on the CqlSession directly.

Closes gh-21487
5 years ago
Stephane Nicoll 7fe85750fb Merge branch '2.2.x' into 2.3.x 5 years ago
Stephane Nicoll cc3575b3f4 Merge branch '2.1.x' into 2.2.x 5 years ago
Stephane Nicoll 9a457527fd Polish test 5 years ago
Andy Wilkinson 8155cc5f23 Merge branch '2.2.x' into 2.3.x
Closes gh-21786
5 years ago
Andy Wilkinson a0f29edd4d Always initialize stompWebSocketHandlerMapping eagerly
Previously, when lazy initialization was enabled, STOMP-based WebSocket
messaging would not work as the stompWebSocketHandlerMapping bean was
not initialized and CONNECT requests would go unanswered.

This commit adds a LazyInitializationExcludeFilter that causes the
stompWebSocketHandlerMapping bean to always be initialized eagerly.
This triggers initialization of the WebSocket transport allowing
requests to be received and processed.

Fixes gh-19611
5 years ago