Commit Graph

6482 Commits (00a3ad0fd1f750a1c97ea16a132246b2a6ff6053)

Author SHA1 Message Date
HaiTao Zhang 00a3ad0fd1 Added support for devtools YAML configuration
See gh-17915
5 years ago
Andy Wilkinson b43827d626 Configure ping (formerly application) health indicator by default
This commit renames ApplicationHealthIndicator to PingHealthIndicator
and changes the auto-configuration so that it is now always configured
by default.

Closes gh-17926
5 years ago
Andy Wilkinson 05e089601e Remove default favicon and support for serving from classpath root
Closes gh-17925
5 years ago
Phillip Webb e03f822c6d Add support for health indicator groups
Update the `HealthEndpoint` to support health groups. The
`HealthEndpointSettings` interface has been replaced with
`HealthEndpointGroups` which provides access to the primary group
as well as an optional set of additional groups.

Groups can be configured via properties and may have custom
`StatusAggregator` and `HttpCodeStatusMapper` settings.

Closes gh-14022

Co-authored-by: Stephane Nicoll <snicoll@pivotal.io>
5 years ago
Phillip Webb f09e0264d9 Migrate HealthIndicator auto-configurations
Migrate all `HealthIndicator` configuration to `HealthContributor`
configurations instead.

See gh-14022
5 years ago
Phillip Webb 3c535e0de3 Add HealthContributor and refactor HealthEndpoint
Overhaul `HealthEndpoint` support to make it easier to support health
groups. Prior to this commit the `HealthIndicator` interface was used
for both regular indicators and composite indicators. In addition the
`Health` result was used to both represent individual, system and
composite health. This design unfortunately means that all health
contributors need to be aware of the `HealthAggregator` and could not
easily support heath groups if per-group aggregation is required.

This commit reworks many aspects of the health support in order to
provide a cleaner separation between a `HealthIndicator`and a
composite. The following changes have been made:

- A `HealthContributor` interface has been introduced to represent
  the general concept of something that contributes health information.
  A contributor can either be a `HealthIndicator` or a
  `CompositeHealthContributor`.

- A `HealthComponent` class has been introduced to mirror the
  contributor arrangement. The component can be either
  `CompositeHealth` or `Health`.

- The `HealthAggregator` interface has been replaced with a more
  focused `StatusAggregator` interface which only deals with `Status`
  results.

- `CompositeHealthIndicator` has been replaced with
  `CompositeHealthContributor` which only provides access to other
  contributors. A composite can no longer directly return `Health`.

- `HealthIndicatorRegistry` has been replaced with
  `HealthContributorRegistry` and the default implementation now
  uses a copy-on-write strategy.

- `HealthEndpoint`, `HealthEndpointWebExtension` and
  `ReactiveHealthEndpointWebExtension` now extend a common
  `HealthEndpointSupport` class. They are now driven by a
  health contributor registry and `HealthEndpointSettings`.

- The `HealthStatusHttpMapper` class has been replaced by a
  `HttpCodeStatusMapper` interface.

- The `HealthWebEndpointResponseMapper` class has been replaced
  by a `HealthEndpointSettings` strategy. This allows us to move
  role related logic and `ShowDetails` to the auto-configure module.

- `SimpleHttpCodeStatusMapper` and `SimpleStatusAggregator`
  implementations have been added which are configured via constructor
  arguments rather than setters.

- Endpoint auto-configuration has been reworked and the
  `CompositeHealthIndicatorConfiguration` class has been replaced
  by `CompositeHealthContributorConfiguration`.

- The endpoint JSON has been changed make `details` distinct from
  `components`.

See gh-17926
5 years ago
Andy Wilkinson 24b5b0d93e Polish 5 years ago
Andy Wilkinson 87339405f3 Merge branch '2.1.x'
Closes gh-17928
5 years ago
Andy Wilkinson abe3d38527 Fix OoM error when starting Tomcat with max int load on startup
Fixes gh-17927
5 years ago
dreis2211 6ef6875a60 Correct WebFlux response body method
See gh-17919
5 years ago
Andy Wilkinson 9ac6485768 Prioritise static resource locations over classpath for favicon.ico
Closes gh-17922
5 years ago
Madhura Bhave 55c6ee71c1 Include logger group with configuredLevel in docs
Closes gh-17772
5 years ago
Phillip Webb 5f88c592b3 Polish 5 years ago
Brian Clozel e7c3ab3e27 Rename WebFlux response body methods
This commit adapts to recent changes in Spring Framework.
See spring-projects/spring-framework#23212
5 years ago
Stephane Nicoll 752bb0f5ab Start building against Spring Kafka 2.3.0 snapshots
See gh-17902
5 years ago
Stephane Nicoll 9dd6edbe56 Start building against Spring Integration 5.2.0 snapshots
See gh-17901
5 years ago
Stephane Nicoll b2e024f22e Start building against Spring HATEOAS 1.0.0 snapshots
See gh-17904
5 years ago
Stephane Nicoll e984874e96 Start building against Spring Data Moore snapshots
See gh-17900
5 years ago
Stephane Nicoll 3c0a41646b Start building against Spring Batch 4.2.0 snapshots
See gh-17899
5 years ago
Stephane Nicoll 4b6e3b2a59 Start building against Reactor Dysprosium snapshots
See gh-17895
5 years ago
Andy Wilkinson e805b6ea6e Upgrade to Mockito 3.0.0
Closes gh-17803
5 years ago
Andy Wilkinson 7f8944d00f Polish 5 years ago
Andy Wilkinson cc3df98135 Merge branch '2.1.x' 5 years ago
Andy Wilkinson ab87b2a39b Polish 5 years ago
Andy Wilkinson f916e1a1ce Document response structure for retrieving a logger group
Closes gh-17909
5 years ago
Stephane Nicoll 3bc65f4fec Upgrade to Kotlin coroutines 1.3.0-RC2
See gh-17907
5 years ago
Stephane Nicoll a43e4c7a21 Start building against Spring Framework 5.2.0 snapshots
See gh-17896
5 years ago
Stephane Nicoll 7f06504006 Detect ConfigurationProperties using autowiring constructor
This commit improves InvalidConfigurationPropertiesException failure
analysis by adding a dedicated description when a single autowiring
constructor is found. When @Component is removed, such constructor is
used for properties binding and will not apply the same semantics as
before.

Closes gh-17750
5 years ago
LiangYong a5746d0a03 Simplify some code
See gh-17893
5 years ago
thelproad 9c1f503e46 Simplify if statements
See gh-17884
5 years ago
Stephane Nicoll fc0cee5ea7 Merge branch '2.1.x' 5 years ago
lijuny d33ed84f1f Remove redundant code
See gh-17875
5 years ago
dreis2211 d4affd7f85 Use hasSize() assertion in favor of length checks
See gh-17874
5 years ago
Stephane Nicoll 04b63cda8f Merge branch '2.1.x'
Closes gh-17889
5 years ago
Filip Hrisafov 1ebbe9fc55 Map non-null LDAP properties
The userDn and password in LdapContextSource are not nullable. The
default values for userDn and password in LdapProperties are null. When
the values are set to null there will eventually be a
NullPointerException during
AbstractContextSource#setupAuthenticatedEnvironment since HashTable
doesn't allow null for values.

See gh-17861
5 years ago
Madhura Bhave 76dfe1aae4 Merge branch '2.1.x'
Closes gh-17887
5 years ago
Madhura Bhave 0187e5106d Polish "Set up SpringLiquibase beans' dependencies by type rather than name"
See gh-17805
5 years ago
Andrii Hrytsiuk b69f9e9fdf Add missing javadoc
See gh-17805
5 years ago
Andrii Hrytsiuk eaad22dd89 Set up SpringLiquibase beans' dependencies by type rather than name
See gh-17805
5 years ago
Madhura Bhave dab815af40 Simplify mockmvc security in tests following upstream changes
SecurityMockMvcConfigurer now honors filter order so we can use that instead
of manually adding the filter.
5 years ago
Andy Wilkinson a785a5b58a Test the Gradle Plugin against Gradle 5.6
Closes gh-17883
5 years ago
dreis2211 56940fca97 Test the Gradle Plugin against Gradle 5.6
See gh-17876
5 years ago
Madhura Bhave 64e8b1d47c Polish "Add properties for Jetty threadpool"
See gh-17871
5 years ago
HaiTao Zhang 1024d74742 Add properties for Jetty threadpool
See gh-17871
5 years ago
Madhura Bhave 09b690b3c9 Fix tests 5 years ago
Madhura Bhave 7494a2baad Merge branch '2.1.x'
Closes gh-17880
5 years ago
Madhura Bhave 8d7deb7b67 Polish "Expand documentation on remote devtools"
See gh-17780
5 years ago
Sergei Petunin ab33bc7deb Expand documentation on remote devtools
See gh-17780
5 years ago
Madhura Bhave eea83e935e Resolve httpstatus error series using raw int code
See gh-16691
5 years ago
Madhura Bhave 186530478c Bypass Spring security authentication for remote devtools endpoint
Closes gh-17878
5 years ago