1

I have set following in spring boot yaml file. But not working. I checked the question Set DEFAULT_VIEW_INCLUSION in YAML file. But there they have given answer for new custom objectmapper object, but not using the spring convertor object.

spring: jackson: mapper: DEFAULT_VIEW_INCLUSION: true

A MJ
  • 115
  • 1
  • 9

1 Answers1

-1

Please try the following config:

spring:
    jackson:
        default-property-inclusion: DEFAULT_VIEW_INCLUSION
Ryan Dake
  • 84
  • 6
  • It will give following error in yaml file: Expecting a 'com.fasterxml.jackson.annotation.JsonInclude$Include[ALWAYS, NON_NULL, NON_ABSENT, NON_EMPTY, ...]' but got 'DEFAULT_VIEW_INCLUSION' – A MJ Apr 11 '19 at 14:55
  • Both different properties and purpose – A MJ Apr 11 '19 at 14:56