Commit Graph

25373 Commits

Author SHA1 Message Date
Andy Wilkinson 1b48daf1d5 Do not ignore unknown fields when invalid fields are being ignored
Previously, ignoring invalid fields would cause the failure for an
unknown field to be ignored, irrespective of the ignoreUnknownFields
attribute on `@ConfigurationProperties`.

This commit updates the NoUnboundElementsBindHandler to ensure that
any UnboundConfigurationPropertiesException is thrown rather than
being ignored when the handler has been wrapped by an
IgnoreErrorsBindHandler.

Fixes gh-22308
2020-07-27 13:28:44 +01:00
Andy Wilkinson 41954533b2 Fix Mock|SpyBean context caching
The fix for gh-20916 updated DefinitionsParser so that the
ResolvableType for each MockBean or SpyBean field included the
implementation class from which the field was found. Where the field
was declared with a variable generic signature that was made constant
by its implementation class, this allowed the correct concrete type to
be determined. It also had the unintended side-effect of preventing two
test classes with identical `@MockBean` and `@SpyBean` configuration
from sharing a context as the resolvable types for their mock and spy
bean fields would now be different.

This commit updates DefinitionsParser to only include the
implementation class in the ResolvableType if the field's generic type
is variable. For cases where it is not variable, this restores the
behaviour prior to the fix for gh-20916.

Fixes gh-22566
2020-07-27 13:04:02 +01:00
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
2020-07-27 11:24:36 +01:00
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
2020-07-27 10:47:14 +01:00
Andy Wilkinson 1c3528f5a4 Include Jackson Modules in WebMvcTest and WebFluxTest
Fixes gh-22530
2020-07-27 10:11:29 +01:00
Andy Wilkinson 7b3c0a9e09 Advise against java.util.Optional configuration properties
Closes gh-21868
2020-07-27 09:58:24 +01:00
Andy Wilkinson 162253948a Merge branch '2.1.x' into 2.2.x 2020-07-26 10:08:22 +01:00
Andy Wilkinson 25866019c9 Polish pipeline env vars used by Gradle Enterprise 2020-07-26 10:05:26 +01:00
Andy Wilkinson 750777db24 Merge branch '2.1.x' into 2.2.x 2020-07-25 10:36:19 +01:00
Andy Wilkinson 5d776f2a8b Set user.name in CI builds so it's picked up by Gradle Enterprise 2020-07-25 10:33:39 +01:00
Andy Wilkinson 1dfa21c99f Merge branch '2.1.x' into 2.2.x 2020-07-25 10:28:35 +01:00
Andy Wilkinson 141c59e348 Set BRANCH env var so it's available to Gradle Enterprise 2020-07-25 10:26:53 +01:00
Andy Wilkinson 4a828c7db1 Merge branch '2.1.x' into 2.2.x 2020-07-25 09:10:50 +01:00
Andy Wilkinson 45d50e279e Disable build scans in custom layout sample's tests 2020-07-25 09:10:31 +01:00
Andy Wilkinson ce7210c4f0 Merge branch '2.1.x' into 2.2.x
Closes gh-22563
2020-07-25 09:06:11 +01:00
Andy Wilkinson ebfa26e3ac Merge pull request #22555 from runningcode
* gh-22555:
  Polish "Add generated-snippets as output to test goal"
  Add generated-snippets as output to test goal

Closes gh-22555
2020-07-25 09:05:05 +01:00
Andy Wilkinson d1ea5befea Polish "Add generated-snippets as output to test goal"
See gh-22555
2020-07-25 08:27:05 +01:00
Nelson Osacky 585aed8f8f Add generated-snippets as output to test goal
The generated snippets were not declared as an output to the
`spring-boot-actuator-autoconfigure` test goal so when the test was
pulled from the cache, it did not contain the `generated-snippets`
directory. This directory is required as an input to the Asciidoctor
plugin.

See gh-22555
2020-07-25 08:26:15 +01:00
Andy Wilkinson 1a43cd1c8e Merge branch '2.1.x' into 2.2.x
Closes gh-22551
2020-07-24 14:28:11 +01:00
Andy Wilkinson 843a618c83 Merge pull request #22550 from runningcode
* gh-22550:
  Disable extra scans for full profile.

Closes gh-22550
2020-07-24 14:28:06 +01:00
Nelson Osacky 0494007893 Disable extra scans for full profile.
The extra scans were not disabled for the full profile, only the
regular profile.

See gh-22550
2020-07-24 14:27:32 +01:00
Andy Wilkinson 051d3f2a2e Merge branch '2.1.x' into 2.2.x 2020-07-24 14:24:46 +01:00
Andy Wilkinson 6215052c5b Polish integration of Gradle Enterprise in CI builds 2020-07-24 14:22:25 +01:00
Andy Wilkinson 2f45bc085f Merge branch '2.1.x' into 2.2.x 2020-07-24 12:08:03 +01:00
Andy Wilkinson d435c19ab8 Align gradle-enterprise-maven-extension versions 2020-07-24 12:07:32 +01:00
Andy Wilkinson f4508b4059 Merge branch '2.1.x' into 2.2.x
Closes gh-22547
2020-07-24 11:54:12 +01:00
Andy Wilkinson 7d825cebbc Merge pull request #22089 from runningcode
* gh-22089:
  Polish "Add Gradle Enterprise Extension"
  Add Gradle Enterprise Extension

Closes gh-22089
2020-07-24 11:52:07 +01:00
Andy Wilkinson 60ff87155f Polish "Add Gradle Enterprise Extension"
See gh-22089
2020-07-24 11:51:52 +01:00
Nelson Osacky e41a53cf85 Add Gradle Enterprise Extension
This adds build caching and build scans.

The changes required disabling scans when using the maven invoker
plugin in order to not cause duplicate build scans when invoking other
maven builds. There is also an empty `.mvn` folder in the
spring-boot-starters project to prevent duplicate build scans as well
since there is no way to pass properties to the maven-javadoc-plugin.

The checkstyle plugin was causing a cache miss with the
`propertyExpansion` because it contains an absolute path. The absolute
path is now ignored and instead the files are added as inputs to the
checkstyle plugin. This only enables the local build cache. The remote
cache is not yet enabled.

On my local machine:

./mvnw clean install build times go from about 30 minutes to about 10 minutes.
./mvnw clean install -Pfull build times go from about 60 minutes to about 13 minutes.

See gh-22089
2020-07-24 11:47:24 +01:00
Spring Buildmaster 652712b5eb Next development version (v2.2.10.BUILD-SNAPSHOT) 2020-07-24 08:47:37 +00:00
Phillip Webb e137e3d130 Merge branch '2.1.x' into 2.2.x 2020-07-23 21:36:50 -07:00
Phillip Webb f68671e1bc Refine regex
See gh-22543
2020-07-23 21:23:42 -07:00
Phillip Webb 7ace6cd450 Move properties to correct file
See gh-22543
2020-07-23 21:09:15 -07:00
Phillip Webb b77dbcd06f Allow certain artifacts to be optionally deployed
Update `DistributeCommand` so that regex patterns can be used to mark
artifacts that are optional and need not fail the release.

Closes gh-22543
2020-07-23 20:45:25 -07:00
Phillip Webb d69c35a1db Deal with 404 response when checking for artifacts 2020-07-23 18:23:24 -07:00
Phillip Webb 53296cd161 Backport build script updates 2020-07-23 17:45:55 -07:00
Phillip Webb c043701dc0 Turn on debug logging 2020-07-23 17:45:49 -07:00
Spring Buildmaster 7ac5cc96c2 Next development version (v2.1.17.BUILD-SNAPSHOT) 2020-07-23 21:53:53 +00:00
Andy Wilkinson 9c5e59371f Upgrade to Jackson 2.10.5
Closes gh-22432
2020-07-23 21:12:08 +01:00
Andy Wilkinson 2118c73985 Merge branch '2.1.x' into 2.2.x 2020-07-23 21:03:57 +01:00
Andy Wilkinson f93bae4bd3 Upgrade to Aspectj 1.9.6
Closes gh-22539
2020-07-23 21:03:51 +01:00
Andy Wilkinson ce803cc678 Upgrade to Micrometer 1.3.11
Closes gh-22538
2020-07-23 21:03:49 +01:00
Andy Wilkinson 698db27a75 Upgrade to Aspectj 1.9.6
Closes gh-22537
2020-07-23 21:02:36 +01:00
Andy Wilkinson db242794ec Upgrade to Micrometer 1.1.16
Closes gh-22536
2020-07-23 21:02:34 +01:00
Stephane Nicoll 4f3b03afcf Merge branch '2.1.x' into 2.2.x
Closes gh-22525
2020-07-23 11:01:05 +02:00
Stephane Nicoll 0440a9a78c Upgrade to Groovy 2.5.13
Closes gh-22505
2020-07-23 10:55:47 +02:00
Stephane Nicoll 458b5690e1 Upgrade Java 14 version in CI image
Closes gh-22516
2020-07-23 09:33:30 +02:00
Stephane Nicoll a2b797f8b7 Upgrade Java 8 version in CI image
Closes gh-22518
2020-07-23 09:33:03 +02:00
Stephane Nicoll 3d1181ee96 Merge branch '2.1.x' into 2.2.x 2020-07-23 09:31:42 +02:00
Stephane Nicoll ee37ddd6c0 Upgrade Java 8 version in CI image
Closes gh-22512
2020-07-23 09:31:01 +02:00