spring boot - Apply further configuration to Jackson2ObjectMapperBuilder before it is used -
springboot comes own pre-configured jackson2objectmapperbuilder
used through framework configure various objectmapper
.
the builder doesn't expose facets of objectmapper
, wondering how apply additional configuration builder before used?
i can provide own jackson2objectmapperbuilder
instance loose default initialisation provided springboot...
is there way?
create beans extend com.fasterxml.jackson.databind.module.simplemodule, there configure example own seriealizers , deserializers.
in newer spring versions (dont know since when @ least since spring 4 ) these beans picked automatically.
in older versions of spring may need add modules manually objectmapper, tricky, because spring creates many beans of type objetmapper , not easy find right one.
Comments
Post a Comment