-
Notifications
You must be signed in to change notification settings - Fork 40.7k
Spring Boot 2.6.0 M1 Release Notes
To use embedded mongo, the spring.mongodb.embedded.version
property must now be set.
This helps to ensure that the MongoDB version that is used by the embedded support matches the MongoDB version that your application will use in production.
Dependency management for com.nimbusds:oauth2-oidc-sdk
and com.nimbusds:nimbus-jose-jwt
has been removed.
If you are using Spring Security you should rely on the versions that it will pull in as transitive dependencies.
If you are not using Spring Security you should define your own dependency management that meets your application’s needs.
Dependency management for org.webjars:hal-browser
has been removed.
If you are using org.webjars:hal-browser
you should define your own dependency management that meets your application’s needs.
The Maven plugin’s build info support now uses the value of the project.build.outputTimestamp
property as the default build time.
If the property is not set, the the build session’s start time is used as it was previously.
As before, the time can be disabled entirely by setting it to off
.
The property to control the version of Prometheus has changed from prometheus-pushgateway.version
to prometheus-client.version
. This is to reflect the fact that the property manages the version of every module in Prometheus’s client, not just the pushgateway.
Classes, methods and properties that were deprecated in Spring Boot 2.4 have been removed in this release. Please ensure that you aren’t calling deprecated methods before upgrading.
Tip
|
Check the configuration changelog for a complete overview of the changes in configuration. |
Auto-configuration for Spring Data Envers is now provided.
To use it, add a dependency on org.springframework.data:spring-data-envers
and update your JPA repositories to extend from RevisionRepository
.
Support for exporting metrics to the Dynatrace v2 API has been added.
With a local OneAgent running on the host, a dependency on io.micrometer:micrometer-registry-dynatrace
is all that is required.
Without a local OneAgent, the management.metrics.export.dynatrace.uri
and management.metrics.export.dynatrace.api-token
properties must be configured.
Other settings that are specific to the v2 API can be configured using the management.metrics.export.dynatrace.v2
properties.
Please refer to the updated reference documentation for further details.
Micrometer’s ExecutorServiceMetrics
are now auto-configured for all ThreadPoolTaskExecutor
and ThreadPoolTaskScheduler
beans, as long as the underlying ThreadPoolExecutor
is available.
Metrics are tagged with the name of the executor derived from its bean name.
Micrometer’s DiskSpaceMetrics
are now auto-configured.
disk.free
and disk.total
metrics are provided for the partition identified by the current working directory.
To change the path that is used, define your own DiskSpaceMetrics
bean.
Micrometer’s JettyConnectionMetrics
are now auto-configured.
Additionally, when server.ssl.enabled
is set to true
, Micrometer’s JettySslHandshakeMetrics
are also auto-configured.
Redis (both Jedis and Lettuce) will now automatically enable pooling when commons-pool2
is on the classpath.
Set spring.redis.jedis.pool.enabled
or spring.redis.lettuce.pool.enabled
to false
to disable pooling if required.
The Maven Plugin’s start
goal has been made more configurable from the command line.
Its wait
and maxAttempts
properties can be specified using spring-boot.start.wait
and spring-boot.start.maxAttempts
respectively.
A new annotation, @WebServiceServerTest
, that can be used to test Web Service @Endpoint
beans has been introduced.
The annotation creates a test slice containing @Endpoint
beans and auto-configures a MockWebServiceClient
bean that can be used to test your web service endpoints.
Spring Boot 2.6 moves to new versions of several Spring projects:
Numerous third-party dependencies have also been updated, some of the more noteworthy of which are the following:
-
Micrometer 1.8.0-M1
-
QueryDSL 5.0.0.M1
-
SnakeYAML 1.29
-
Cassandra Driver 4.12.0
-
Kafka 2.8.0
Apart from the changes listed above, there have also been lots of minor tweaks and improvements including:
-
The failure analysis for a
NoSuchMethodError
now includes information about the location from which the calling class was loaded. -
A
ClientResourcesBuilderCustomizer
bean can now be defined to customize Lettuce’sClientResources
will retaining the default auto-configuration. -
Configuration properties for Flyway’s
detectEncoding
,failOnMissingLocations
, andignoreMigrationPatterns
configuration settings have been added. -
A custom
ResourceLoader
to be used by the application can be provided when creating aSpringApplicationBulder
. -
A
WebSessionIdResolver
can now be defined to customize the resolver that will be used by the auto-configuredWebSessionManager
. -
Any
RSocketConnectorConfigurer
beans are now automatically applied to the auto-configuredRSocketRequester.Builder
. -
spring-boot-configuration-processor
can now generate metadata for classes annotated with Lombok’s@Value
. -
A new
server.tomcat.reject-illegal-header
configuration property can be set to true to configure Tomcat to accept illegal headers. -
When using Stackdriver, labels can now be configured on the monitor resource by setting
management.metrics.export.stackdriver.resource-labels.*
configuration properties. -
@EntityScan
now supports comma-separated values in itsbasePackages
attribute. -
A new configuration property,
server.netty.idle-timeout
, that can be used to control Reactor Netty’s idle timeout has been added. -
The location from which Devtools loads its global settings can now be configured using the
spring.devtools.home
system property or theSPRING_DEVTOOLS_HOME
environment variable. -
The setter methods on
RabbitTemplateConfigurer
are nowpublic
-
AbstractDataSourceInitializer
has been deprecated in favor ofDataSourceScriptDatabaseInitializer
. Similarly, subclasses ofAbstractDataSourceInitializer
have been deprecated in favour of newDataSourceScriptDatabaseInitializer
-based equivalents. -
SpringPhysicalNamingStrategy
has been deprecated in favor of Hibernate 5.5’sCamelCaseToUnderscoresNamingStrategy