Fix outdated reference to DurationUnit

Closes gh-12708
This commit is contained in:
Stephane Nicoll
2018-04-02 16:06:03 +02:00
parent 821af30277
commit c90806477c

View File

@@ -1202,7 +1202,7 @@ Spring Boot has dedicated support for expressing durations. If you expose a
available:
* A regular `long` representation (using milliseconds as the default unit unless a
`@DefaultUnit` has been specified)
`@DurationUnit` has been specified)
* The standard ISO-8601 format
{java-javadoc}/java/time/Duration.html#parse-java.lang.CharSequence-[used by
`java.util.Duration`]
@@ -1229,11 +1229,11 @@ You can also use any of the supported unit. These are:
* `h` for hours
* `d` for days
The default unit is milliseconds and can be overridden using `@DefaultUnit` as illustrated
The default unit is milliseconds and can be overridden using `@DurationUnit` as illustrated
in the sample above.
TIP: If you are upgrading from a previous version that is simply using `Long` to express
the duration, make sure to define the unit (using `@DefaultUnit`) if it isn't
the duration, make sure to define the unit (using `@DurationUnit`) if it isn't
milliseconds alongside the switch to `Duration`. Doing so gives a transparent upgrade path
while supporting a much richer format.