Prior to this commit, the `ApplicationContext` couldn't start with a
JDK-proxied `HikariDataSource` as the JMX auto-configuration was
attempting to inject a (too narrowed) `HikariDataSource`.
This commit rather injects a regular `DataSource` and attempt to unwrap
it as a `HikariDataSource`.
Closes gh-12271
Update `ApplicationContextRequestMatcher` and
`ApplicationContextServerWebExchangeMatcher` to use a supplier for
the context, rather than the context itself.
This allow exceptions to be propagated to subclasses which may choose
to deal with them.
See gh-12238
This commit changes invocations to immediately return the expression
instead of assigning it to a temporary variable. The method name should
be sufficient for callers to know exactly what will be returned.
Closes gh-12211
This commit ensures that Tomcat is the first reactive server configured
if the Tomcat dependency is on classpath.
Spring Boot chose Reactor Netty as the default for the reactive web
starter, but the Reactor Netty dependency can be used also for its HTTP
client. In case developers are adding Tomcat, Undertow or Jetty on their
classpath, we must configure those and consider Reactor Netty for the
client only.
Fixes gh-12176
Update the configurable embedded web server factory interfaces to
extend `ConfigurableWebServerFactory` so that the can be used in a
`WebServerFactoryCustomizer`.
Extract server specific customization to their own auto-configuration
and align reactive/servlet server auto-configuration.
Closes gh-8573
Create a new `ApplicationConversionService` similar in design to the
DefaultFormattingConversionService from Spring Framework. The new
conversion service provides a central place for custom conversion logic
supported by Spring Boot.
Also replace the `BindingConversionService` with an internal
`BindConverter` class that now invokes the `SimpleTypeConverter`
directly. Binding for `@ConfigurationProperties` has been updated so
that any custom property editors registered with the BeanFactory can
be used.
Fixes gh-12095
Move `XADataSourceWrapper` to `jdb` and `XAConnectionFactoryWrapper` to
`jms` so that they are packaged in a similar way to the underlying XA
types.
Fixes gh-12061
The `server.display-name` configuration property is used to configure
the application display name for Servlet-based applications.
This commit moves that property to:
`server.servlet.application-display-name` and keeps the same defaults.
Closes gh-8624
This commit avoids printing the stacktrace for ResponseStatusException
in order to be consistent with WebFlux ResponseStatusExceptionHandler
and because this stacktrace is usually not very useful in Reactive
world and mainly pollutes the logs, only the message is logged in that
case.
It also logs a WARN message for Bad Request (400) HTTP responses in
order to have a feedback when an exception is thrown due to client error
(unable to deserialize request body for example).
See related SPR-15083 issue on Spring Framework side.
Remove custom `SpringIntegrationMetrics` and instead provide
auto-configuration to the direct Micrometer support added in Spring
Integration 5.0.2.
Closes gh-11985
This commit sets a mapping resources list only when there is at least an
element in it. This allows the default fallback of finding an "orm.xml"
file to kick in when no customization has been applied.
Closes gh-11964
This change updates SqlDialectLookup to delegate to jOOQ's JDBCUtils
rather than creating an additional mapping between
org.springframework.boot.jdbc.DatabaseDriver and org.jooq.SQLDialect.
This has the following advantages:
1. jOOQ's `SQLDialect` to URL mappings are already maintained by jOOQ,
so no additional changes will be necessary to Spring Boot in the
future.
2. Delegating to jOOQ means that the mapping also works for the
commercial jOOQ distributions, e.g. when working with DB2, Oracle,
SQL Server, etc., as the JDBCUtils of the commercial distribution
also contains the relevant logic to map to e.g. `SQLDialect.DB2`,
`SQLDialect.ORACLE`, `SQLDialect.SQLSERVER` (which are not
available from the open source distribution linked by Spring Boot
by default).
Closes gh-11466
The fix in Spring Data Redis for sentinel configuration means that
two Jedis sentinel tests now attempt to connect to a Sentinel. As a
result the tests fail. Running a Redis Sentinel in a Docker container
appears to be non-trivial. As an alternative, this commit updates the
tests to capture the JedisConnectionFactory prior to its
initialization (which is the failure trigger) and then assert that its
configuration is as expected.
See gh-11884
Closes gh-11855
Move `ApplicationHome`, `ApplicationPid` and `ApplicationTemp` to the
`system` package. Since `system` package is now much lower level, the
existing `FileWriter` implementations also needed to move to prevent
package tangles.
Fixes gh-8614
While Spring Mobile support has been removed from Spring Boot, the
auto-configuration has been relocated to a separate module that uses
the same keys.
Flagging those keys as deprecated means that the IDE will be confused
when the extra jar is present on the classpath as it advertizes, as
it should, support fo them.
Closes gh-11844