joffrey-bion / livedoc

A not-so-annotation-based documentation generator for REST and websocket services
MIT License
4 stars 2 forks source link

ObjectMapper custom configuration is ignored by Livedoc #43

Closed joffrey-bion closed 7 years ago

joffrey-bion commented 7 years ago

Livedoc currently recreates an ObjectMapper object instead of reading Spring's actual ObjectMapper instance used for Jackson HTTP messages conversion.

One consequence of it is https://github.com/joffrey-bion/livedoc/issues/42

ST-DDT commented 7 years ago

Please keep in mind that there is no ObjectMapper Spring Bean that will be used by all HttpMessageConverters. Instead each converter will contain its own instance with its own configuration.

joffrey-bion commented 7 years ago

Yes, I'm aware of this. That's why I used the one from the Jackson converter instead of relying on the bean. That being said, in Spring Boot, I read that you may create you own ObjectMapper bean, and it would be used by spring for the converters. I haven't confirmed that myself though.