Sunday, 15 September 2013

How to format the json Date format using spring boot and spring hateoas -


I am working on Spring Boot and Spring Hate to create a relaxing API.
I need to format the date format "Yyyy-MM-dd".

I do not want to use @JesenFormat, because this annotation should be used everywhere, where we use a date

< P>

text ">

If you are using Jackson, You can set the date format globally by setting the following values ​​in your application: Properties / Applications. IML:

  Spring Jackson.date-format = # date format string (like y Yyy-MM-dd HH: mm: ss), or a fully-qualified date format class name (such as com.fasterxml.jackson.databind.util.ISO8601DateFormat)  

No comments:

Post a Comment