8192 Commits

Author SHA1 Message Date
Stephane Nicoll
4e554b8c2b Start building against Spring Data Moore-SR9 snapshots
See gh-22384
2020-07-17 13:42:38 +02:00
Stephane Nicoll
0e4b6d3203 Start building against Spring AMQP 2.2.9 snapshots
See gh-22383
2020-07-17 13:42:11 +02:00
Stephane Nicoll
819ff56e94 Start building against Reactor Dysprosium-SR10 snapshots
See gh-22374
2020-07-17 10:29:49 +02:00
Stephane Nicoll
84303e682c Start building against Spring Framework 5.2.8 snapshots
See gh-22372
2020-07-17 10:29:17 +02:00
Andy Wilkinson
d9882f2c88 Clarify the effects of ordering auto-configuration classes
Closes gh-22337
2020-07-15 10:48:01 +01:00
Andy Wilkinson
9558779dd4 Replace ConfigurationPropertiesBeanDefinitionValidator with a FailureAnalyzer
Previously, regular bean definitions for configuration properties classes
that attempt to use constructor binding were detected in a bean factory
post-processor, ConfigurationPropertiesBeanDefinitionValidator. This
validation examined every standard bean definition and failed if it
encountered one for a class that should have used constructor binding.
There were two downsides to this approach:

1. Reflection used to identify if the bean should be using constructor
   binding triggered class loading that could prevent subsequent
   instrumentation by a load-time weaver.
2. The cost of the validation was incurred when there was no
   misconfiguration to report.

This commit replaces ConfigurationPropertiesBeanDefinitionValidator
with a failure analyzer. This failure analyzer only runs once a failure
has occurred and the application context is not going to complete
refresh. This avoids causing problems with subsequent instrumentation
and also avoids the cost of validation and error reporting unless there
is an error.

Fixes gh-20798
2020-07-14 11:37:54 +01:00
Andy Wilkinson
afa5b12bdb Make reactive Jetty auto-config back off without jetty-servlet
Fixes gh-22275
2020-07-09 10:36:32 +01:00
Andy Wilkinson
66987533d1 Link to application properties section from externalized config list
Closes gh-22262
2020-07-08 17:58:35 +01:00
Andy Wilkinson
4e79bb1cff Disable bean method proxying in SpringBootJdbcConfiguration
Closes gh-22231
2020-07-07 11:51:07 +01:00
Andy Wilkinson
14f24dbecc Merge branch '2.1.x' into 2.2.x
Closes gh-22248
2020-07-07 11:42:43 +01:00
Andy Wilkinson
26f591264c Fix handling of NestedServletException with no root cause
Fixes gh-22169
2020-07-07 11:34:25 +01:00
Andy Wilkinson
a8d3f9af31 Polish "Rename NoneOfNestedConditions to NoneNestedConditions in example docs"
See gh-22207
2020-07-07 10:46:32 +01:00
Clayton Walker
7fee70a625 Rename NoneOfNestedConditions to NoneNestedConditions in example docs
See gh-22207
2020-07-07 10:46:20 +01:00
Andy Wilkinson
a0f1424393 Polish "Fix unwrapping of captured PrintStream in test support's OutputCapture"
See gh-22214
2020-07-07 09:54:52 +01:00
XenoAmess
75a64bd901 Fix unwrapping of captured PrintStream in test support's OutputCapture
See gh-22214
2020-07-07 09:53:34 +01:00
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
2020-07-06 14:24:36 +01:00
Andy Wilkinson
21453b5016 Ignore scoped targets when finding matching beans
Fixes gh-22038
2020-07-02 10:39:56 +01:00
Andy Wilkinson
81d6751ba7 Use ApplicationContextRunner in ConditionalOnSingleCandidateTests 2020-07-02 10:10:28 +01:00
Andy Wilkinson
a13acf9f2b Upgrade to Reactor Dysprosium-SR9
Closes gh-21937
2020-07-01 11:49:39 +01:00
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
2020-06-30 17:39:21 +01:00
Andy Wilkinson
3922fb7164 Polish "Avoid NPE when binder is closed before started event"
See gh-22141
2020-06-30 13:26:30 +01:00
im47cn
b34c268547 Avoid NPE when binder is closed before started event
Previously, if TomcatMetricsBinder destroy() was called before it had
received an ApplicationStartedEvent an NPE would be thrown due to
TomcatMetrics being null. This NPE was then caught and logged at
warning level by the disposable bean adapter.

This prevents the NPE by checking that the TomcatMetrics instance is
null before calling close() on it.

See gh-22141
2020-06-30 13:23:58 +01:00
May
c1b9d3c226 Simplify logic in ErrorPage's equals method
See gh-22082
2020-06-29 17:06:49 -07:00
Andy Wilkinson
5475f10657 Remove WebClient's in-memory buffer size limit for endpoint tests
Previously, the thread dump endpoint's response could exceed
WebClient's in-memory buffer limt when there were a large number of
threads or the threads had large stacks.

This commit disables WebClient's in-memory buffer size limit so that
the test passing is not dependent on the number of active threads and
their stack sizes.

Closes gh-22101
2020-06-25 10:21:43 +01:00
Scott Frederick
b27303704f Fix RedisReactiveHealthIndicator in clustered configuration
Prior to Spring Data Redis version 2.2.8, the contents of the
Properties object returned from the
ReactiveRedisConnection.ServerCommands.info API were the same
for clustered and non-clustered Redis configurations, containing a set
of key/value pairs. This allowed ReactiveRedisHealthIndicator to get
a version property using a well-known key. Starting with Spring Data
Redis 2.2.8, the info property keys contain a host:port prefix in a
clustered Redis configuration. This prevented
ReactiveRedisHealthIndicator from getting the version property as
before and resulted in the health always being reported as DOWN.

This commit adjusts ReactiveRedisHealthIndicator to detect the
clustered configuration from Spring Data Redis and find the version
property for one of the reported cluster nodes.

Fixes gh-22061
2020-06-24 13:34:22 -05:00
Andy Wilkinson
3fed27fd90 Merge branch '2.1.x' into 2.2.x
Closes gh-22085
2020-06-24 10:17:57 +01:00
Andy Wilkinson
0b4533659f Use Groovy's bom in spring-boot-dependencies
Closes gh-22084
2020-06-24 10:17:06 +01:00
Phillip Webb
e6eb02603c Polish 'Inherit show-details property in health groups'
Rework the inheritance so that the property metadata JSON more
accurately reflects the default value.

See gh-22022
2020-06-22 23:01:37 -07:00
Leo Li
10de88884f Inherit show-details property in health groups
Update `Group` properties so that the `showDetails` value does not
inherit `Show.NEVER`. Prior to this commit, the `Group` properties
would not correctly inherit a `showDetails` value from the main
`management.endpoint.health.show-details` property.

See gh-22022
2020-06-22 22:54:34 -07:00
Phillip Webb
3b3a49db1f Polish 'Fix infinite loop in FieldValues'
See gh-22040
2020-06-22 12:01:04 -07:00
Konrado85
39a853c57b Fix infinite loop in FieldValues
Update `FieldValues` test object so that it doesn't cause an infinite
loop if it is actually created.

See gh-22040
2020-06-22 11:58:22 -07:00
Stephane Nicoll
9b803af3c3 Polish "Document how to exclude an annotation processor with Maven"
See gh-22000
2020-06-19 11:36:25 +02:00
Marco Pens
627c0b1031 Document how to exclude an annotation processor with Maven
See gh-22000
2020-06-19 11:35:48 +02:00
Andy Wilkinson
41173f7c40 Polish "Use Awaitility instead of Thread.sleep"
See gh-21988
2020-06-19 08:18:01 +01:00
Tomek Szmytka
c13385ea74 Use Awaitility instead of Thread.sleep
See gh-21988
2020-06-19 08:17:53 +01:00
Andy Wilkinson
67604a5416 Only process main metadata as it already includes additional metadata
Previously, the configuration property table generation was reading
both the main metadata and the additional metadata from each project.
This was unnecessary as the annotation processor will have already
merged the additional metadata into the main metadata before writing
it to disk. Processing both the main and additional metadata led to
a clash as the metadata overlapped. When the entry in the additional
metadata won the clash, the resulting entry in the configuration
property table would lose any details that aren't contained in the
additional metadata.

This commit updates the property table generation code to only use
the main metadata files.

Fixes gh-21131
2020-06-18 15:49:34 +01:00
Andy Wilkinson
1b62abab9a Configure context on SizeAndTimeBasedRollingPolicy
Previously, when file-based logging was enabled, Logback would output
the following during logging system initialization:

LOGBACK: No context given for c.q.l.core.rolling.SizeAndTimeBasedRollingPolicy

This commit updates the default logback configuration to set the
context on the SizeAndTimeBasedRollingPolicy that it creates.

Fixes gh-21056
2020-06-18 11:01:26 +01:00
Andy Wilkinson
907b64a5eb Remove redundant stop() calls from LiveReloadServerTests 2020-06-18 09:23:02 +01:00
Madhura Bhave
615cf63a82 Make MockBean resolve right type for abstract test class
Fixes gh-20916
2020-06-17 17:25:03 -07:00
Stephane Nicoll
58974ab9cf Start building against Reactor Dysprosium-SR9 snapshots
See gh-21937
2020-06-16 07:57:31 +02:00
Stephane Nicoll
ec8c1e3860 Update copyright year of changed files
See gh-21906
2020-06-15 08:39:51 +02:00
lltx
de897b9b72 Fix wrong property reference to keys-to-sanitize in Javadoc
See gh-21906
2020-06-15 08:39:51 +02:00
Stephane Nicoll
f8a0ca0d80 Upgrade to Netty Tcnative 2.0.31.Final
Closes gh-21889
2020-06-11 13:23:35 +02:00
Stephane Nicoll
9af5f70b75 Upgrade to Spring Batch 4.2.4
Closes gh-21783
2020-06-11 10:34:50 +02:00
Stephane Nicoll
e64bfb80e4 Upgrade to Postgresql 42.2.14
Closes gh-21888
2020-06-11 08:55:47 +02:00
Stephane Nicoll
664436a3d6 Upgrade to Spring Kafka 2.3.9
Closes gh-21781
2020-06-11 08:54:52 +02:00
Stephane Nicoll
49ba5dc6bc Upgrade to Postgresql 42.2.14
Closes gh-21887
2020-06-11 08:44:30 +02:00
Stephane Nicoll
c496f2401f Upgrade to Netty Tcnative 2.0.31.Final
Closes gh-21886
2020-06-11 08:44:29 +02:00
Stephane Nicoll
7dee9e34b5 Upgrade to Spring Kafka 2.2.14
Closes gh-21780
2020-06-11 08:43:39 +02:00
Phillip Webb
ac197be815 Fix checkstyle issue 2020-06-10 22:14:09 -07:00