Commit Graph

1663 Commits

Author SHA1 Message Date
Stephane Nicoll 85a3fcfb5e Merge branch '2.2.x'
Closes gh-21119
2020-04-25 09:32:24 +02:00
Stephane Nicoll 80410997ec Polish "Enhance Database initialization how to guide"
See gh-21077
2020-04-25 09:30:58 +02:00
nikmanzotti f2b10be01e Enhance Database initialization how to guide
See gh-21077
2020-04-25 09:30:43 +02:00
Johnny Lim ef567388c1 Polish
See gh-21110
2020-04-25 09:04:10 +02:00
dreis2211 c2fb95151b Fix link to R2DBC Query in docs
See gh-21079
2020-04-25 09:00:58 +02:00
dreis2211 5eb5bf0a2d Polish
See gh-21009
2020-04-25 08:54:47 +02:00
Andy Wilkinson d53be18582 Deprecate support for Bitronix
Closes gh-20823
2020-04-24 11:37:44 +01:00
Phillip Webb 6ccba24494 Merge branch '2.2.x'
Close gh-20507 in 2.3.0.RC1
2020-04-23 16:40:49 -07:00
Phillip Webb 581ce09f88 Merge branch '2.1.x' into 2.2.x
Closes gh-21106
2020-04-23 16:39:38 -07:00
Phillip Webb 416cfc2c86 Improve @Value documentation
Improve "@ConfigurationProperties vs. @Value" documentation with the
recommendation that kebab-case is used with the `@Value` annotation.

Closes gh-20507
2020-04-23 16:39:22 -07:00
Andy Wilkinson d05c973e71 Polish 2020-04-23 11:49:07 +01:00
Stephane Nicoll fe90b2a251 Rename Service Level Agreement to Service Level Objective
This commit harmonizes our integration of Micrometer's Service Level
objectives.

Closes gh-21076
2020-04-23 10:13:17 +02:00
Phillip Webb 48821bccb7 Merge branch '2.2.x'
Closes gh-21092
2020-04-22 16:50:41 -07:00
Phillip Webb d1649fbb9a Merge branch '2.1.x' into 2.2.x
Closes gh-21091
2020-04-22 16:49:33 -07:00
Phillip Webb e0f94f54ac Add "Health as Gauge" how-to documentation
Add how-to documentation describing how health information can be
exported to a Micrometer Gauge.

Closes gh-18329
2020-04-22 16:45:46 -07:00
Phillip Webb 3e3587e0fb Polish 2020-04-22 12:57:08 -07:00
Madhura Bhave 0699116e95 Merge branch '2.2.x'
Closes gh-21075
2020-04-21 17:11:05 -07:00
Madhura Bhave 16ac968f69 Relocate section on configuring DevTools' file system watcher
Closes gh-20895
2020-04-21 17:09:40 -07:00
Madhura Bhave 7755e0c3e2 Fix Dockerfile example in docs
Fixes gh-21020
2020-04-20 16:02:35 -07:00
Madhura Bhave 2cac264624 Merge branch '2.2.x'
Closes gh-21049
2020-04-20 15:58:45 -07:00
Madhura Bhave af6d538781 Add support for initializing nested object when nothing bound
When using constructor binding, if no properties are bound to
a nested property, the top-level instance will be created with a
null value for the nested property.
This commit introduces support for an empty `@DefaultValue` which
indicates that an instance of the nested property must be created
even if nothing is bound to it. It honors any `@DefaultValue`
annotations that the nested property might have in its constructor.

Closes gh-18917
2020-04-20 15:39:55 -07:00
dreis2211 320b328610 Fix anchors in links to Maven and Gradle plugin docs
See gh-21033
2020-04-20 13:39:38 +01:00
Phillip Webb e533ce3826 Merge branch '2.2.x'
Closes gh-21028
2020-04-19 18:56:02 -07:00
Phillip Webb d27e437ddc Merge branch '2.1.x' into 2.2.x
Closes gh-21027
2020-04-19 18:55:15 -07:00
Phillip Webb f0ec571b2e Document relaxed binding from the environment
Update the reference documentation with more details about how relaxed
binding works against environment variables.

Closes gh-18215
2020-04-19 18:51:07 -07:00
Phillip Webb 636a47641a Merge branch '2.2.x'
Closes gh-21026
2020-04-19 17:49:13 -07:00
Phillip Webb 55f0af7f0f Merge branch '2.1.x' into 2.2.x
Closes gh-21025
2020-04-19 17:48:32 -07:00
Phillip Webb 359b508077 Document devtool property file profile restrictions
Closes gh-19972
2020-04-19 17:46:24 -07:00
Phillip Webb 3c388cf48e Fix typo 2020-04-16 13:20:47 -07:00
Johnny Lim 5fad43ec40 Polish
See gh-20973
2020-04-16 13:46:53 +02:00
Madhura Bhave d648b98991 Merge branch '2.2.x'
Closes gh-20964
2020-04-14 16:55:40 -07:00
Madhura Bhave 947594addd Merge branch '2.1.x' into 2.2.x
Closes gh-20963
2020-04-14 16:54:54 -07:00
Madhura Bhave c98fe51914 Make it more obvious that Jolokia does not work with a WebFlux app
Closes gh-20623
2020-04-14 16:45:31 -07:00
Phillip Webb 28da1da241 Update availability/probe documentation
Update the application availability and probes documentation following
the recent set of updates.

See gh-20962
2020-04-14 16:40:36 -07:00
Johnny Lim cb320288a4 Polish
See gh-20931
2020-04-13 14:35:21 +02:00
Stephane Nicoll 9752cd4b8c Merge branch '2.2.x'
Closes gh-20909
2020-04-10 11:37:32 +02:00
A Vaz 267f6481f8 Fix typo
See gh-20907
2020-04-10 11:36:46 +02:00
Stephane Nicoll d571fb311f Add support for NewRelicClientProvider
Closes gh-20908
2020-04-10 11:34:19 +02:00
Madhura Bhave 1342e4970a Provide a condition for detecting war deployments
Closes gh-19421
2020-04-09 18:52:06 -07:00
Andy Wilkinson 2d360ef155 Merge branch '2.2.x'
Closes gh-20897
2020-04-09 12:41:48 +01:00
Andy Wilkinson 7e1807c01b Polish "Update endpoint enablement description to describe availability"
See gh-20799
2020-04-09 12:41:16 +01:00
Eric Opoku 399c85a5ef Update endpoint enablement description to describe availability
See gh-20799
2020-04-09 12:41:05 +01:00
Phillip Webb d9fb4dd477 Don't use monospacing in documentation headings
Closes gh-20875
2020-04-07 11:08:57 -07:00
Phillip Webb 5e028599f0 Change PDF rename logic
Rework the rename logic used to include the reference PDF to try
and workaround the following local build error:

	Encountered duplicate path "reference/pdf/spring-boot-reference.pdf"
	during copy operation configured with DuplicatesStrategy.FAIL

See gh-20829
2020-04-06 19:18:22 -07:00
Phillip Webb ef9611e30e Document executable-jar index files
Update the executable jar appendix to include details of the index
files.

Closes gh-20859
2020-04-06 19:18:22 -07:00
Scott Frederick c05d7f844d Remove duplication in documentation index files
This commit combines index adoc files for single-page HTML and PDF
into one file to remove duplication. It also renames index files to
reflect the separation between source format and generated output
format.

Finishes gh-20829
2020-04-06 16:49:29 -05:00
Stephane Nicoll 888a81beba Migrate Kafka metrics to KafkaClientMetrics
Closes gh-20838
2020-04-06 16:45:56 +02:00
Scott Frederick bb568c5bff Consolidate Maven plugin documentation in plugin reference
This commit moves Maven plugin content from several sections in the
main Spring Boot reference documentation to the plugin-specific
documentation.

Fixes gh-19165
2020-04-03 16:41:12 -05:00
Stephane Nicoll b7ac83a830 Fix typo 2020-04-03 17:03:57 +02:00
Stephane Nicoll 1df8b5886c Add reference to r2dbc database initialization section
Closes gh-20524
2020-04-03 16:51:10 +02:00
Stephane Nicoll f4e6d7c1cf Fix links to Maven Plugin's documentation in reference guide
Closes gh-20818
2020-04-03 14:34:16 +02:00
Phillip Webb 12bc890e75 Update Maven and Gradle layer customization docs
Update the Maven and Gradle documentation following the refined
layer customization changes.

See gh-20526
2020-04-03 00:34:27 -07:00
Madhura Bhave 0e1394ef30 Update reference documentation for layer changes
Update the reference documentation following the jar format changes.

See gh-20813
2020-04-03 00:34:27 -07:00
Andy Wilkinson 84e16d55ea Raise the minimum supported version of Gradle 6 to 6.3
Closes gh-20532
2020-03-31 19:48:17 +01:00
Andy Wilkinson 6d7c3da1cf Polish "Make it clear to which type the DataSource properties are bound"
See gh-20727
2020-03-31 12:56:34 +01:00
Param 004ea51b05 Make it clear to which type the DataSource properties are bound
See gh-20727
2020-03-31 12:56:13 +01:00
Stephane Nicoll 960ab159e4 Document how to initialize a database with R2DBC
This commit adds a section to the reference guide on how to initialize
a database using R2DBC. 2 smoke tests are also added to validate this
behaviour with Flyway and Liquibase.

Closes gh-20742
2020-03-31 13:15:06 +02:00
Stephane Nicoll 722d37468b Rationalize RabbitProperties
Closes gh-18830
2020-03-30 15:04:52 +02:00
Stephane Nicoll 49ab5de91c Polish
See gh-20704
2020-03-28 10:37:16 +01:00
Stephane Nicoll 8154e672dd Polish
See gh-20704
2020-03-28 08:45:57 +01:00
dreis2211 674f1e77b5 Fix typos
See gh-20704
2020-03-28 08:42:59 +01:00
Stephane Nicoll 7a64b3f761 Restore Cassandra port option
This commit restores the port option that was removed in an earlier
milestone. Contact points that do not define a port already are
automatically transformed to include the one configured, with a default
matching Cassandra's default port.

This makes upgrades easier in the case a cluster uses consistent ports
everywhere.

Closes gh-19672
2020-03-27 12:20:40 +01:00
Stephane Nicoll 443abd414b Merge branch '2.2.x'
Closes gh-20699
2020-03-27 11:01:00 +01:00
Stephane Nicoll 5d56e24da2 Document that Java 14 is a supported version
Closes gh-20689
2020-03-27 11:00:42 +01:00
Stephane Nicoll dfa3939f56 Merge branch '2.2.x' 2020-03-26 11:09:15 +01:00
Stephane Nicoll a234dff573 Remove check for deprecated configuration properties
See gh-20528
2020-03-26 11:06:47 +01:00
Stephane Nicoll ff15d136db Merge branch '2.2.x'
Closes gh-20687
2020-03-26 10:42:31 +01:00
Stephane Nicoll ab01c55d8e Deprecate use of path extensions for request mapping and content negotiation
Closes gh-20528
2020-03-26 10:41:08 +01:00
Dave Syer 5022ec500a Extra detail for Kubernetes probes
Provides a few more concrete details about how probes and Kubernetes
behave, so users can make more informed decisions.

See gh-19593
Closes gh-20660
2020-03-24 13:02:54 +01:00
dreis2211 f95e9543dc Fix typos in packaging docs
See gh-20630
2020-03-24 07:44:26 +01:00
Phillip Webb 0717de723f Polish 2020-03-23 20:03:44 -07:00
Brian Clozel 4be64e8f9c Add "management.health.probes.enabled" config property
Prior to this commit, we were relying on the
`"spring.main.cloud-platform"` property for overriding cloud platform
detection and enabling liveness and readiness probes. Changes made in
gh-20553 have now been reverted.

This commit adds the `"management.health.probes.enabled"` configuration
property. The auto-configuration now enables the HTTP Probes and
`HealthIndicator` if this property is enabled, or if the Kubernetes
cloud platform is detected.

This property is `false` by default for now, since enabling this for all
Spring Boot applications would be a breaking change. In this case, the
global `"/actuator/health"` endpoint could report `OUT_OF_SERVICE`
during startup time because the application now reports the readiness as
well.

See gh-19593
2020-03-23 22:04:30 +01:00
Brian Clozel 3cc0ab1583 Polish reference docs on Kubernetes Probes
See gh-19593
2020-03-23 21:23:51 +01:00
Stephane Nicoll 8c9711ab9a Merge branch '2.2.x'
Closes gh-20622
2020-03-23 15:28:41 +01:00
Stephane Nicoll bf15276af1 Fix import in constructor binding example
Closes gh-20378
2020-03-23 15:27:08 +01:00
Stephane Nicoll 34b71561d3 Merge branch '2.2.x'
Closes gh-20619
2020-03-23 14:22:56 +01:00
Stephane Nicoll 7be3db2d4d Merge branch '2.1.x' into 2.2.x
Closes gh-20618
2020-03-23 14:22:30 +01:00
Stephane Nicoll bcce6f9f07 Document that Jackson is a required dependency of the Actuator
Closes gh-19564
2020-03-23 14:16:55 +01:00
Johnny Lim cc18b91723 Fix "Building Docker Images" section level
See gh-20608
2020-03-23 08:19:49 +00:00
Brian Clozel 6b9f2cac17 Fix section title levels in reference docs 2020-03-21 11:33:42 +01:00
Brian Clozel ffdf9a422f Polish Liveness and Readiness support
This commit moves the core Liveness and Readiness support to its own
`availability` package. We've made this a core concept independent of
Kubernetes.

Spring Boot now produces `LivenessStateChanged` and
`ReadinessStateChanged` events as part of the typical application
lifecycle.

Liveness and Readiness Probes (`HealthIndicator` components and health
groups) are still configured only when deployed on Kubernetes.

This commit also improves the documentation around Probes best practices
and container lifecycle considerations.

See gh-19593
2020-03-20 23:54:00 +01:00
Brian Clozel b30e5a60c5 Polish
See gh-19593
2020-03-19 20:07:35 +01:00
Brian Clozel fd0b2f6695 Add Kubernetes Liveness and Readiness Probes support
Prior to this commit and as of Spring Boot 2.2.0, we would advise
developers to use the Actuator health groups to define custom "liveness"
and "readiness" groups and configure them with subsets of existing
health indicators.

This commit addresses several limitations with that approach.

First, `LivenessState` and `ReadinessState` are promoted to first class
concepts in Spring Boot applications. These states should not only based
on periodic health checks. Applications should be able to track changes
(and adapt their behavior) or update states (when an error happens).

The `ApplicationStateProvider` can be injected and used by applications
components to get the current application state. Components can also
track specific `ApplicationEvent` to be notified of changes, like
`ReadinessStateChangedEvent` and `LivenessStateChangedEvent`.
Components can also publish such events with an
`ApplicationEventPublisher`. Spring Boot will track startup event and
application context state to update the liveness and readiness state of
the application. This infrastructure is available in the
main spring-boot module.

If Spring Boot Actuator is on the classpath, additional
`HealthIndicator` will be contributed to the application:
`"LivenessProveHealthIndicator"` and `"ReadinessProbeHealthIndicator"`.
Also, "liveness" and "readiness" Health groups will be defined if
they're not configured already.

Closes gh-19593
2020-03-19 14:11:00 +01:00
Andy Wilkinson 0a17e2daf3 Merge branch '2.2.x'
Closes gh-20556
2020-03-18 10:57:40 +00:00
Lars Grefer c748f36856 Fix recommended task dependency configuration
`compileJava.dependsOn(processResources)` is not enough to ensure the
correct behavior. Using `dependsOn` only affects the execution order
(`processResources` before `compileJava`) but not the up-to-date check
of `compileJava`. After modifying
`META-INF/additional-spring-configuration-metadata.json`, the
`processResouces` task will considered out-of-date and will be
re-executed, but after that `compileJava` will still be considered
up-to-date which causes the changes not to be merged into
`META-INF/spring-configuration-metadata.json`

With this change the up-do-date check of `compileJava` is affected,
too. Therefore, it will correctly re-execute the
configuration-processor when
`META-INF/additional-spring-configuration-metadata.json` was changed.

See gh-20323
2020-03-18 10:55:32 +00:00
Stephane Nicoll abe43b2e83 Upgrade to Couchbase SDK v3
This commit upgrades to the Couchbase SDK v3 which brings the following
breaking changes:

* Bootstrap hosts have been replaced by a connection string and the
authentication is now mandatory.
* A `Bucket` is no longer auto-configured. The
`spring.couchbase.bucket.*` properties have been removed
* `ClusterInfo` no longer exists and has been replaced by a dedicated
API on `Cluster`.
* `CouchbaseEnvironment` no longer exist in favour of
`ClusterEnvironment`, the customizer has been renamed accordingly.
* The bootstrap-related properties have been removed. Users requiring
custom ports should supply the seed nodes and initialize a Cluster
themselves.
* The endpoints-related configuration has been consolidated in a
single IO configuration.

The Spring Data Couchbase provides an integration with the new SDK. This
leads to the following changes:

* A convenient `CouchbaseClientFactory` is auto-configured.
* Repositories are configured against a bucket and a scope. Those can
be set via configuration in `spring.data.couchbase.*`.
* The default consistency property has been removed in favour of a more
flexible annotation on the repository query methods instead. You can now
specify different query consistency on a per method basis.
* The `CacheManager` implementation is provided, as do other stores for
consistency so a dependency on `couchbase-spring-cache` is no longer
required.

See gh-19893

Co-authored-by: Michael Nitschinger <michael@nitschinger.at>
2020-03-17 17:00:09 +01:00
Stephane Nicoll e3899df22c Configure Spring Data Couchbase explicitly
This commit configures Spring Data Couchbase explicitly rather than
relying on the abstract configuration class. This has the advantage of
simplifying the auto-configuration and let it us proxy-free
configuration classes.

Spring Boot no longer uses or interacts with CouchbaseConfigurer. Users
relying on that to teach Spring Boot which components to use should
rely on `@Primary` flag instead in case of multiple beans of the same
type.

`CouchbaseConfiguration` is no longer public as extending from it is
no longer necessary. If the `CouchbaseEnvironment` has to be
customized, a `CouchbaseEnvironmentBuilderCustomizer` bean can be
registered to tune the auto-configured environment.

Closes gh-20533
2020-03-17 16:20:21 +01:00
Andy Wilkinson 0315724126 Cache endpoint responses on a per-principal basis
Previously, any HTTP request to an endpoint that included a principal
would bypass the cache. This prevented authenticated requests from
making use of the cache and its configurable time-to-live.

This commit updates the caching operation invoker to include the
principal, if any, in its cache key. As a result, requests that
include a principal will make use of the cache, potentially returning
the result of a previous invocation of the same endpoint by the same
principal.

Closes gh-19538
2020-03-13 15:31:41 +00:00
Andy Wilkinson ef9960c69f Allow additional tags to be contributed to WebMvc and WebFlux defaults
Closes gh-20175
2020-03-13 09:38:29 +00:00
Johnny Lim 8526e66939 Polish
See gh-20498
2020-03-11 12:17:58 +01:00
Andy Wilkinson 4d371f0d88 Merge branch '2.2.x'
Closes gh-20491
2020-03-10 21:27:41 +00:00
Florian Dreier 76451d47b7 Update versiion of git-properties plugin shown in the docs
See gh-20436
2020-03-10 21:26:48 +00:00
Andy Wilkinson 308e1d3675 Add support for gracefully shutting down the web server
This commit adds support for gracefully shutting down the embedded
web server. When a grace period is configured
(server.shutdown.grace-period), upon shutdown, the web server will no
longer permit new requests and will wait for up to the grace period
for active requests to complete.

Closes gh-4657
2020-03-09 18:12:20 +00:00
Artem Bilan 3967e76b9b Auto-Configure RSocket support for Spring Integration
This commit adds a new auto-configuration for RSocket support in Spring
Integration.

Given an application with `spring-messaging`, `spring-integration-rsocket`
and RSocket dependencies, developers are now able to leverage Spring
Integration features with RSocket.

It is now possible to configure an RSocket server with
`"spring.rsocket.server.*"` properties and let it use
`IntegrationRSocketEndpoint` or `RSocketOutboundGateway` components to
handle incoming RSocket messages. This infrastructure can handle Spring
Integration RSocket channel adapters and `@MessageMapping` handlers
(given `"spring.integration.rsocket.server.message-mapping-enabled"`is
configured.

If the `"spring.integration.rsocket.client.host"` and
`"spring.integration.rsocket.client.port"` (for TCP protocol), or
`"spring.integration.rsocket.client.uri"`  (for WebSocket) is configured
then a `ClientRSocketConnector` will be configured accordingly.

Closes gh-18834

Co-authored-by: Brian Clozel <bclozel@pivotal.io>
2020-03-03 15:15:24 +01:00
Stephane Nicoll ea66940be1 Document R2DBC support
Closes gh-19988

Co-authored-by: Mark Paluch <mpaluch@pivotal.io>
2020-02-25 09:29:36 -05:00
Stephane Nicoll 4c2ff9c314 Merge branch '2.2.x'
Closes gh-20315
2020-02-25 09:00:30 -05:00
Yoo In Keun ec20246415 Fix typos in documentation
See gh-20313
2020-02-25 08:59:12 -05:00
Madhura Bhave 15cd590f7f Allow users to opt out of including the layer tools in a layered jar
For Maven, the layer configuration is now an additional configuration
option instead of a layout type.

Closes gh-19866
2020-02-19 17:28:27 -08:00
Scott Frederick 6017c1ccac Update MongoDB auto-configuration documentation. 2020-02-19 12:39:57 -06:00
Stephane Nicoll 363edfa00c Merge branch '2.2.x'
Closes gh-20221
2020-02-18 17:38:39 +01:00