:docs: https://docs.spring.io/spring-boot/docs/current-SNAPSHOT/reference/htmlsingle/

= Spring Boot 1.3.0 M3 Release Notes

For changes in earlier milestones, please refer to:

 - link:Spring-Boot-1.3.0-M1-Release-Notes[v1.3.0 M1]
 - link:Spring-Boot-1.3.0-M2-Release-Notes[v1.3.0 M2]

== Upgrading from Spring Boot 1.3.0 M2
See instructions in the link:Spring-Boot-1.3.0-M2-Release-Notes[1.3.0.M2 release notes] for upgrading from 1.3.0 M2

=== Property renames
The following `application.properties` keys have been renamed to improve consistency:

* `servet.tomcat.accessLogEnabled` to `server.tomcat.accesslog.enabled`
* `servet.tomcat.accessLogPattern` to `server.tomcat.accesslog.pattern`
* `servet.undertow.accessLogDir` to `server.undertow.accesslog.dir`
* `servet.undertow.accessLogEnabled` to `server.undertow.accesslog.enabled`
* `servet.undertow.accessLogPattern` to `server.undertow.accesslog.pattern`

=== Gradle

The Spring Boot Gradle plugin will no longer apply Gradle's https://docs.gradle.org/current/userguide/application_plugin.html[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:

[indent=0,subs="attributes"]
----
    springBoot {
        mainClass = 'com.example.YourApplication'
    }
----

`applicationDefaultJvmArgs` should now be configured in your project's `ext` block,
for example:

[indent=0,subs="attributes"]
----
    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:

[indent=0,subs="attributes"]
----
    bootRun {
        main = com.example.YourApplication
    }
----


== New and Noteworthy

TIP: Check link:Spring-Boot-1.3.0-M3-Configuration-Changelog[the configuration changelog] for a complete overview of the changes in configuration.

=== Persistent sessions

Update Tomcat, Jetty and Undertow to serialize session data when the application is stopped and load it again when the application restarts. Persistent session are opt-in; either by setting `persistentSession`
on the `ConfigurableEmbeddedServletContainer` or by using the property `server.session.persistent=true` (Persistent sessions are enabled by default with Devtools).

=== Devtools

Devtools now allow allow additional paths that trigger a reload/restart to be configured via the `spring.devtools.restart.additional-paths` property. When a change occurs in one of those paths a restart or reload will be triggered, depending on the full restart exclude patterns configured via the existing `spring.devtools.restart.exclude` property.

Devtools also enables the `server.session.persistent` flag so that you keep your session information when the application is reloaded.

=== Spring Boot CLI

The CLI will now use the repositories configured in Maven's `settings.xml` during dependency resolution. For a repository to be used, the profile in which it is declared must be active.

=== Embedded MongoDB

Auto-configuration for https://github.com/flapdoodle-oss/de.flapdoodle.embed.mongo[Embedded MongoDB] has been added. A dependency on `de.flapdoodle.embed:de.flapdoodle.embed.mongo` is all that's necessary to get started.
Configuration, such as the version of Mongo to use, can be controlled via `application.properties`. Please see the
{docs}#boot-features-mongo-embedded[documentation] for further information.

=== H2 Web Console

Auto-configuration for https://www.h2database.com/html/quickstart.html#h2_console[H2's web console] has been added.
When you are using Spring Boot's developer tools, adding a dependency on `com.h2database:h2` to your web application is all that is necessary to get started. Please see the {docs}#boot-features-sql-h2-console[documentation] for further information.

=== Logging

The console and file logging patterns can now be specified as regular properties (that is `logging.pattern.console` and `logging.pattern.file` respectively).

Tomcat access logs have better customizations: the directory and file prefix/suffix can now be customized via configuration.

If you are using logback or log4j2, we now include information about the location from which each class in a stack trace was loaded (this can be customized via `logging.exception-conversion-word`). We also changed the default logback configuration so that it https://logback.qos.ch/manual/layouts.html#rootException[logs the root cause first].

Finally, we have improved Log4J 2's default output to be similar to the output produced by Logback.

=== Auto-configuration

The auto-configuration report has now an additional section called "Unconditional classes". It lists any auto-configuration classes that do not have any class-level conditions, i.e. the class will be
always be part of the application's configuration.

It is now possible to _also_ exclude auto-configuration classes via the `spring.autoconfigure.excludes` property. Similarly, a new `@ImportAutoConfiguration` annotation can be used by tests that wish to selectively import certain auto-configuration classes.

=== Configuration properties

If you are using `@ConfigurationProperties` on beans, you no longer *need* to add `@EnableConfigurationProperties` to your configuration as Spring Boot autoconfigures it now. As before you can ask Spring to create a bean for your `@ConfigurationProperties` class using the value attribute of `@EnableConfigurationProperties` or with a regular `@Bean` definition.

=== Messaging

Both JMS and Rabbit endpoints can be easily disabled via configuration. The default container factory that is created if none exists can also be customized via configuration. Check the link:Spring-Boot-1.3.0-M2-Release-Notes[new properties] for `spring.jms` and `spring.rabbitmq` for more details.

=== Configuration Properties Meta-data

The `META-INF/spring-configuration-metadata.json` file format has been updated to support a new `deprecation` attribute per property element that defines the reason for the deprecation and a replacement key, if any. Such information can be provided by adding `@DeprecatedConfigurationProperty` on the getter of the property.

We've also improved the detection of default value: if a property is initialized via a method call having a single argument, we consider said argument to be the default value (i.e. `Charset.forName("UTF-8")` would detect `UTF-8` as the default value).

A new `spring-boot-configuration-metadata` module is now available for any tool developers wishing to use the configuration meta-data in their own tools and apps: it offers an API to read the meta-data and build a repository out of it.

=== Health indicators

It is now possible to easily disable all the default health indicators via the `management.health.defaults.enabled` property.
