On spring boot 1.2.3.RELEASE with fasterxml what is the correct way of serializing and de-serializing a LocalDate field to iso date formatted string?
I've tried:
spring.jackson.serialization.write-dates-as-timestamps:false in application.properties file,
including jackson-datatype-jsr310 in project and then using
@JsonFormat(shape = JsonFormat.Shape.STRING, pattern = "yyyy-MM-dd") annotation
and @DateTimeFormat(iso=ISO.DATE) annotation,
adding Jsr310DateTimeFormatAnnotationFormatterFactory as formatter with:
@Override public void addFormatters(FormatterRegistry registry) { registry.addFormatterForFieldAnnotation(new Jsr310DateTimeFormatAnnotationFormatterFactory()); }
None of the above helped.