In spring boot mvc project with pure java configuration how to configure Jackson to omit lazy load Attributes
With recent versions of Spring Boot this is much easier.
Any beans of type com.fasterxml.jackson.databind.Module will be automatically registered with the auto-configured Jackson2ObjectMapperBuilder and applied to any ObjectMapper instances that it creates. This provides a global mechanism for contributing custom modules when you add new features to your application.
74.3 Customize the Jackson ObjectMapper
First ensure you have the required Jackson dependency:
com.fasterxml.jackson.datatype
jackson-datatype-hibernate4
You can then just include the module as a @Bean in the application context.
@Bean
public Module hibernate4Module()
{
return new Hibernate4Module();
}