-
Notifications
You must be signed in to change notification settings - Fork 0
Spring Boot 1.3.0 Full Release Notes
Classes, methods and properties that were deprecated in Spring Boot 1.2 have been removed in this release. Please ensure that you aren’t calling deprecated methods before upgrading.
Spring Boot 1.2 registered any Jackson Module beans with every ObjectMapper in the application context. This made it impossible to take complete control of an ObjectMapper bean’s modules. Spring Boot 1.3 will only register Jackson Module beans with ObjectMappers that are created or configured with the auto-configured Jackson2ObjectMapperBuilder. This brings the behaviour of module configuration into line with Boot’s other Jackson configuration.
In order to prevent double initialization Spring specific log configuration files can now be used. It’s recommended (although not required) that you rename any default log configuration files to use a -spring suffix. For example logback.xml would change to logback-spring.xml.
In Spring Boot 1.2, if you specified a custom logging configuration file using logging.config and the file did not exist, it would silently fallback to using the default configuration. Spring Boot 1.3 fails due to the missing file. Similarly, if you provided a custom Logback configuration file which was malformed, Spring Boot 1.2 would fall back to its default configuration. Spring Boot 1.3 fails and reports the problems with the configuration to System.err.
The spring.hateoas.apply-to-primary-object-mapper property has been removed as the Spring HATEOAS auto-configuration has been reworked such that it no longer affects the context’s primary ObjectMapper. It has been replaced with a property named spring.hateoas.use-hal-as-default-json-media-type which controls whether or not
the Spring HATEOAS HTTP message converter will handle requests for application/json in addition to requests for
application/hal+json.
The security settings for what information is visible on the actuator /health endpoint have been tweaked a little to provide better consistency. See the HTTP health endpoint access restrictions section in the reference guide for complete details.
Spring Boot 1.2 supported native response compression for Tomcat users, or compression using Jetty’s GZipFilter for users of Jetty, Tomcat, and Undertow. Motivated by the Jetty team’s deprecation of their gzip filter, Spring Boot 1.3 replaces this with support for native response compression in all three embedded containers. As a result the server.tomcat.compression. and spring.http.gzip. properties are no longer supported. The new server.compression.* properties should be used instead.
By default tomcat no longer saves session data in /tmp. If you want to use persistent sessions with Tomcat set the server.session.persistent property to true. The server.session.store-dir can be used to save files in a specific location.
The spring-boot-starter-jetty "Starter POM" no longer includes org.eclipse.jetty:jetty-jsp. If you are using Jetty with JSPs you will now need to directly add this dependency yourself.
Stacktrace information is now never included when Spring MVC renders an error response. If you want Spring Boot 1.2 behavior set error.include-stacktrace to on-trace-param.
Due to the upgrade to Spring Security 4, Spring Boot 1.3 has also upgraded the dependency management and auto-configuration of Thymeleaf’s Spring Security support. The coordinates of the new artifact are org.thymeleaf.extras:thymeleaf-extras-springsecurity4. Please update your pom.xml or build.gradle accordingly.
Spring Boot applications no longer fail to start when a /templates folder cannot be found. If you are using a supported templating technology, and you forget to add /templates, a warning is now logged instead.
The GroovyTemplateProperties class now extends AbstractTemplateViewResolverProperties and provides additional configuration options. If you currently define a prefix.spring.groovy.template.prefix property to define a custom resource location you should rename it to prefix.spring.groovy.resource-loader-location.
Spring Boot’s gradle plugin has been updated in this release to use the dependency management plugin. Most users should be unaffected by this change, however those who were using the versionManagement configuration to apply their own blessed versions will have to update their build scripts.
Rather than requiring a properties file to configure version management, the new plugin allows you to use a Maven bom. For example:
dependencyManagement {
imports {
mavenBom 'com.example:example-bom:1.0'
}
}The Spring Boot Gradle plugin will no longer apply Gradle’s application plugin by default. If you wish to make use of the application plugin you will have to apply it in your build.gradle.
If you do not need the functionality provided by the application plugin, but were using its mainClassName or applicationDefaultJvmArgs properties then you will need to make some minor updates to your build.gradle.
The main class should now be configured using the mainClass property on the springBoot extension, for example:
springBoot {
mainClass = 'com.example.YourApplication'
}
applicationDefaultJvmArgs should now be configured in your project’s ext block,
for example:
ext {
applicationDefaultJvmArgs = [ '-Dcom.example.property=true' ]
}
If you were configuring your project’s main class using the main property of the application plugin’s run task, you should move this configuration to the bootRun task instead:
bootRun {
main = com.example.YourApplication
}
The Spring Boot Maven plugin no longer adds src/main/resources directly to the classpath when using spring-boot:run. If you want live, in-place editing we recommend using Devtools. The addResources property can be set in your pom.xml if you want to restore Spring Boot 1.2. behavior.
Spring Boot 1.3 now supports the use of Maven boms to configure its dependency management in place of the properties file-based metadata. @DependencyManagementBom should be used in place of @GrabMetadata to provide the coordinates of a bom, for example @DependencyManagementBom("io.spring.platform:platform-bom:1.1.2.RELEASE").
The following application.properties keys have been renamed to improve consistency:
-
spring.view.tospring.mvc.view. -
spring.pidfiletospring.pid.file -
error.pathtoserver.error.path -
server.session-timeouttoserver.session.timeout -
servet.tomcat.accessLogEnabledtoserver.tomcat.accesslog.enabled -
servet.tomcat.accessLogPatterntoserver.tomcat.accesslog.pattern -
servet.undertow.accessLogDirtoserver.undertow.accesslog.dir -
servet.undertow.accessLogEnabledtoserver.undertow.accesslog.enabled -
servet.undertow.accessLogPatterntoserver.undertow.accesslog.pattern -
spring.oauth2.tosecurity.oauth2.
Spring Boot 1.3 requires Spring Framework 4.2 or later and is not compatible with earlier versions.
Spring Boot 1.3 uses Spring Security 4.0. See the Spring Security documentation for information on migrating from 3.2.